-
Notifications
You must be signed in to change notification settings - Fork 3.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AttributeError: 'FigureCanvasAgg' object has no attribute 'tostring_rgb' #2411
Comments
same here |
+1 |
i think this might be only related to tensorboard logs in def summarize(
writer,
global_step,
scalars={},
histograms={},
images={},
audios={},
audio_sampling_rate=22050,
):
try:
for k, v in scalars.items():
writer.add_scalar(k, v, global_step)
for k, v in histograms.items():
writer.add_histogram(k, v, global_step)
for k, v in images.items():
writer.add_image(k, v, global_step, dataformats="HWC")
for k, v in audios.items():
writer.add_audio(k, v, global_step, audio_sampling_rate)
except Exception as e:
print(f"Exception when summarizing {e}. Skip, we don't care!") |
+1. Looking for solution |
pip install matplotlib==3.7.0, |
I also faced this error in the terminal window once training started. The workaround is downgrading matplotlib to 3.9 with: |
same, downgrading to |
I agree with you |
I think this might be related? (matplotlib/matplotlib#25484), I am not using this repos software, but i am using matplotlib version 3.10 and getting this error from trying to show plots in the jetbrains IDE PyCharm 2024.1.3 (Professional Edition, Runtime version: 17.0.11+1-b1207.24 x86_64, macOS 12.7.6) viewer: trace: ...
lib/python3.12/site-packages/matplotlib/pyplot.py", line 614, in show
return _get_backend_mod().show(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Applications/PyCharm.app/Contents/plugins/python/helpers/pycharm_matplotlib_backend/backend_interagg.py", line 41, in __call__
manager.show(**kwargs)
File "/Applications/PyCharm.app/Contents/plugins/python/helpers/pycharm_matplotlib_backend/backend_interagg.py", line 144, in show
self.canvas.show()
File "/Applications/PyCharm.app/Contents/plugins/python/helpers/pycharm_matplotlib_backend/backend_interagg.py", line 85, in show
buffer = self.tostring_rgb()
^^^^^^^^^^^^^^^^^
AttributeError: 'FigureCanvasInterAgg' object has no attribute 'tostring_rgb'. Did you mean: 'tostring_argb'?
Process finished with exit code 1
... Workaround is using matplotlib version 3.9.4 and below i think... (at least i tested with 3.9.4 and that solved my issue |
I got failure Preprocessing and Feature Extraction "AttributeError: 'NoneType' object has no attribute 'loader'" |
I am pretty sure the update of the matplotlib break its support with seaborn |
someone should report this to matplotlib. I got this error while plotting generic data. |
I had the same problem and the following helps me: matplotlib.use('TkAgg')` |
Whenever I press "train model" it goes up to 5.3 seconds and then says error on the progress bar. The command window shows this error in the last line. I have no idea what's wrong
The text was updated successfully, but these errors were encountered: