From f22278b2335a449ced4793fb628eff7767248a5c Mon Sep 17 00:00:00 2001 From: allegroai <> Date: Wed, 7 Aug 2019 00:38:58 +0300 Subject: [PATCH] Fix matplotlib support --- trains/binding/matplotlib_bind.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/trains/binding/matplotlib_bind.py b/trains/binding/matplotlib_bind.py index 219d82be..a6658479 100644 --- a/trains/binding/matplotlib_bind.py +++ b/trains/binding/matplotlib_bind.py @@ -183,7 +183,10 @@ class PatchedMatplotlib: plotly_fig = None image_format = 'jpeg' fig_dpi = 300 - if not force_save_as_image: + if force_save_as_image: + # if this is an image, store as is. + fig_dpi = None + else: image_format = 'svg' # noinspection PyBroadException try: