From 4945182fa449f8de58f2fc6d380918075eec5bcf Mon Sep 17 00:00:00 2001 From: allegroai <> Date: Mon, 3 Oct 2022 20:22:24 +0300 Subject: [PATCH] Fix Pyplot/Matplotlib binding reports incorrect line labels and colors (#791) --- clearml/binding/matplotlib_bind.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/clearml/binding/matplotlib_bind.py b/clearml/binding/matplotlib_bind.py index 49b32ea9..e5248349 100644 --- a/clearml/binding/matplotlib_bind.py +++ b/clearml/binding/matplotlib_bind.py @@ -498,7 +498,7 @@ class PatchedMatplotlib: lines_ = plotly_renderer.plotly_fig['data'] half_mark = len(lines_)//2 if len(lines_) % 2 == 0 and \ - all(ln for ln in lines_[half_mark:] if not ln.get('x') and not ln.get('y')): + all(not ln.get('x') and not ln.get('y') for ln in lines_[half_mark:]): for i, line in enumerate(lines_[:half_mark]): line['name'] = lines_[i+half_mark].get('name') except Exception: