1fac747306ceadbf1a01faa82ba2decfe0de059d,pyannote/audio/features/utils.py,,read_audio,#Any#Any#Any#,94

Before Change


    if current_file["audio"][-4:] == ".sph":
        from sphfile import SPHFile
        sph = SPHFile(current_file["audio"])
        y = sph.content
        sample_rate_ = sph.format["sample_rate"]
        if sample_rate is not None and sample_rate_ != sample_rate:
            y = librosa.resample(y, sample_rate_, sample_rate)
        else:
            sample_rate = sample_rate_

    else:

After Change


        sph = SPHFile(current_file["audio"])
        with tempfile.NamedTemporaryFile() as f:
            sph.write_wav(f.name)
            y, sample_rate = librosa.load(f.name, sr=sample_rate, mono=False)

    // all other files
    else:
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: pyannote/pyannote-audio
Commit Name: 1fac747306ceadbf1a01faa82ba2decfe0de059d
Time: 2018-06-29
Author: bredin@limsi.fr
File Name: pyannote/audio/features/utils.py
Class Name:
Method Name: read_audio


Project Name: f90/Wave-U-Net
Commit Name: e55ccbb2ed0faca637a7d9b239ef6ee02b5d289d
Time: 2019-01-29
Author: matangover@gmail.com
File Name: Utils.py
Class Name:
Method Name: load


Project Name: nipy/dipy
Commit Name: 9541a61fc86840802e79e4310e9b064f2dd6be40
Time: 2013-06-19
Author: garyfallidis@gmail.com
File Name: doc/examples/reconst_csd.py
Class Name:
Method Name: