51ace7a3322c10b68fa1509a674115a28c5c82ea,mir_eval/melody.py,,hz2cents,#,91

Before Change


    """
    freq_cent = np.zeros(freq_hz.shape[0])
    freq_nonz_ind = np.flatnonzero(freq_hz)
    freq_cent[freq_nonz_ind] = 1200*np.log2(np.abs(freq_hz[freq_nonz_ind])/base_frequency)

    return freq_cent

After Change


    freq_cent = np.zeros(freq_hz.shape[0])
    freq_nonz_ind = np.flatnonzero(freq_hz)
    normalized_frequency = np.abs(freq_hz[freq_nonz_ind])/base_frequency
    freq_cent[freq_nonz_ind] = 1200*np.log2(normalized_frequency)

    return freq_cent

Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: craffel/mir_eval
Commit Name: 51ace7a3322c10b68fa1509a674115a28c5c82ea
Time: 2014-07-04
Author: craffel@gmail.com
File Name: mir_eval/melody.py
Class Name:
Method Name: hz2cents


Project Name: librosa/librosa
Commit Name: 48a579ae1638f5c60e62d8f5c3bad35e0dcef249
Time: 2013-03-23
Author: brm2132@columbia.edu
File Name: librosa/beat.py
Class Name:
Method Name: onset_estimate_bpm


Project Name: librosa/librosa
Commit Name: 1cdfcfa8a884ffb5f670812ee4b528a76f367be9
Time: 2016-05-07
Author: brian.mcfee@nyu.edu
File Name: librosa/core/constantq.py
Class Name:
Method Name: __fft_filters