Ignore:
Timestamp:
Aug 12, 2015, 7:21:38 PM (9 years ago)
Author:
Paul Brossier <piem@piem.org>
Branches:
feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
Children:
60fc05b
Parents:
3a1a5d6 (diff), 7b2d740 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge branch 'develop' into notes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • python/demos/demo_pitch.py

    r3a1a5d6 rb257b60  
    2323
    2424pitch_o = pitch("yin", win_s, hop_s, samplerate)
    25 pitch_o.set_unit("freq")
     25pitch_o.set_unit("midi")
    2626pitch_o.set_tolerance(tolerance)
    2727
     
    3737    confidence = pitch_o.get_confidence()
    3838    #if confidence < 0.8: pitch = 0.
    39     print "%f %f %f" % (total_frames / float(samplerate), pitch, confidence)
     39    #print "%f %f %f" % (total_frames / float(samplerate), pitch, confidence)
    4040    pitches += [pitch]
    4141    confidences += [confidence]
     
    8181    ax2.axis( ymin = 0.9 * true_freqs.min(), ymax = 1.1 * true_freqs.max() )
    8282# plot raw pitches
    83 ax2.plot(times, pitches, '--g')
     83ax2.plot(times, pitches, '.g')
    8484# plot cleaned up pitches
    8585cleaned_pitches = pitches
     
    9191#ax2.axis( ymin = 55, ymax = 70 )
    9292plt.setp(ax2.get_xticklabels(), visible = False)
    93 ax2.set_ylabel('f0 (Hz)')
     93ax2.set_ylabel('f0 (midi)')
    9494
    9595# plot confidence
Note: See TracChangeset for help on using the changeset viewer.