c8280cd73ec4782188ab1d8d4d7f4ce349a07f6a,tests/test_effects.py,,test_trim,#,144

Before Change


    // construct 5 seconds of stereo silence
    // Stick a sine wave in the middle three seconds
    sr = float(22050)
    y = np.zeros((2, int(5 * sr)))
    y[0, sr:4*sr] = np.sin(2 * np.pi * 440 * np.arange(0, 3 * sr) / sr)

    for top_db in [60, 40, 20]:
        for index in [False, True]:

After Change


    trim_duration = 3.0
    y = np.sin(2 * np.pi * 440. * np.arange(0, trim_duration * sr) / sr)
    y = librosa.util.pad_center(y, 5 * sr)
    y = np.vstack([y, np.zeros_like(y)])

    for top_db in [60, 40, 20]:
        for ref_power in [1, np.max]:
            // Test stereo
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: librosa/librosa
Commit Name: c8280cd73ec4782188ab1d8d4d7f4ce349a07f6a
Time: 2016-11-02
Author: brian.mcfee@nyu.edu
File Name: tests/test_effects.py
Class Name:
Method Name: test_trim


Project Name: librosa/librosa
Commit Name: c7811e399b636c2514d6bc0b6013291541f1a3ed
Time: 2014-12-31
Author: brian.mcfee@nyu.edu
File Name: librosa/feature.py
Class Name:
Method Name: spectral_contrast


Project Name: scikit-learn/scikit-learn
Commit Name: 1801c4b27479d82a95a49a17a06edeb1c15fff39
Time: 2020-02-12
Author: 34657725+jeremiedbb@users.noreply.github.com
File Name: sklearn/decomposition/_nmf.py
Class Name:
Method Name: _initialize_nmf