Changeset 84838c3 for python/demos


Ignore:
Timestamp:
May 10, 2016, 11:45:41 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:
2871e2b
Parents:
f15b8cf
Message:

python/demos/demo_reading_speed.py: avoid unused variable, use globals to get function name

File:
1 edited

Legend:

Unmodified
Added
Removed
  • python/demos/demo_reading_speed.py

    rf15b8cf r84838c3  
    110110def test_speed(function, filename):
    111111    times = []
    112     for i in range(10):
     112    for _ in range(10):
    113113        start = time.time()
    114114        try:
     
    135135
    136136    for f in test_functions:
    137         test_speed(eval(f), filename)
     137        # get actual function from globals
     138        test_function = globals()[f]
     139        test_speed(test_function, filename)
Note: See TracChangeset for help on using the changeset viewer.