basic-pitch icon indicating copy to clipboard operation
basic-pitch copied to clipboard

Why are the running results of my python script and the online demo different?

Open MrQinYQ opened this issue 1 year ago • 5 comments

i upload a canon mp3,python script return a bad result. KIM20240521-509471 KIM20240521-607905 ` from basic_pitch.inference import predict_and_save from basic_pitch import ICASSP_2022_MODEL_PATH

predict_and_save( ['./canon.mp3', './test1.mp3'], 'output', True, True, True, True, model_or_model_path=ICASSP_2022_MODEL_PATH, # onset_threshold=0.5, # frame_threshold=0.5, # minimum_frequency=100, # maximum_frequency=3000, ) `

MrQinYQ avatar May 21 '24 02:05 MrQinYQ

A couple of questions:

  • What OS are you on? If you're doing inference on non-TF, results may change slightly
  • Can you check that the parameters used for the model in the website match what's used in basic-pitch? Thanks

drubinstein avatar May 21 '24 02:05 drubinstein

@drubinstein MacOS M2 arm64. That's non-TF. It seems to be using coremltools. parameters is match for in the website

MrQinYQ avatar May 21 '24 03:05 MrQinYQ

Can you try to install tensorflow macos (basic-pitch[tf]) and see how much different it is? Are the overall results bad with CoreML?

drubinstein avatar May 21 '24 03:05 drubinstein

I need remove coremltools? overall results bad with CoreML

MrQinYQ avatar May 21 '24 03:05 MrQinYQ

Can you try to install tensorflow macos (basic-pitch[tf]) and see how much different it is? Are the overall results bad with CoreML?

pip install basic-pitch[tf]. Midi files look much more normal now. Thanks.

MrQinYQ avatar May 21 '24 03:05 MrQinYQ