AudioCommons / timbral_models

Python scripts for modelling timbral attributes
Apache License 2.0
75 stars 26 forks source link

Fix imports/print for Py3 compat #7

Closed ffont closed 6 years ago

ffont commented 6 years ago

Some fixes for compatibility with Python3. Also removed unneeded imports of pyfilterbank and matplotlib.

Comparison of analysis results with Python2/3 and two test files:

File 1

Descriptor Value py2 Value py3
hardness 73.5924908968 73.5924908968
brightness 83.6140806608 83.6140806608
depth 7.12198777305 7.12198777305
roughness 4.93429311128 4.93429311128
sharpness 3.24552206178 3.24552206178
warmth -11.5366549746 -11.5366549746
booming 0.470598664524 0.470598664524

File 2

Descriptor Value py2 Value py3
hardness 76.9671257334 76.9671257334
brightness 62.1083976964 62.1083976964
depth 24.0898714745 24.0898714745
roughness 10.5333541031 10.5333541031
sharpness 1.5856964301 1.5856964301
warmth 22.8231207834 22.8231207834
booming 1.51895268303 1.51895268303