Cell In[1], line 4139 # Process the reshaped file
40 for audio_file in random.sample(files_adjust,number_of_previz):
---> 41 spectrogram.process_file(audio_file, adjust=True)
43 # Save the spectrogram metadata
44 spectrogram.save_spectro_metadata(True)
File /mnt/Data/Tools/anaconda3/envs/mmermaid-env/lib/python3.10/site-packages/OSmOSE/Spectrogram.py:1200, in Spectrogram.process_file(self, audio_file, adjust, save_matrix, save_for_LTAS, overwrite, clean_adjust_folder)
1197 data = signal.sosfilt(bpcoef, data)
1199 print(f"Generating spectrograms for {output_file.name}")
-> 1200 self.gen_tiles(data=data, sample_rate=sample_rate, output_file=output_file, adjust=adjust)
Context:
Using OSmOSE installed from .whl file version 0.2.0.
Build and initialize methods worked fine on my dataset.
After calling .process_all_files() method I get this error:
This comes from matplotlib version ==> pip install --force-reinstall matplotlib==3.7.0 fixed the problem.
They changed colormap attributes.
Version 3.7.0 -the one osekit is currently using-: https://matplotlib.org/3.7.0/api/_as_gen/matplotlib.pyplot.get_cmap.html
Current version 3.9.0 (stable): https://matplotlib.org/stable/api/cm_api.html
I think the
is deprecated.
and we should use:
in pyproject.toml I see this:
matplotlib = "^3.7.0"
With this description, it installed 3.9.0 by default in our environment.
Can we update code to work with matplotlib 3.9.0 ? otherwise we can freeze the version with
matplotlib==3.7.0.
in pyproject.toml