` import plotly.express as px
from clearml import Task
import pandas as pd
df = pd.DataFrame({'a': ['val1', 'val1', 'val1', 'val1', 'val1', 'val1', 'val1', 'val1', 'val1', 'val1', 'val2', 'val2', 'val2', 'val2', 'val2', 'val2'],
'b':['group_a', 'group_a', 'group_a', 'group_a', 'group_b', 'group_b', 'group_b', 'group_b', 'group_b', 'group_b', 'group_a', 'group_a', 'group_a', 'group_a', 'group_b', 'group_b']})
task = Task.init(**{"project_name":"test",
"task_name":"test1",})
clearml_logger = task.get_logger()
fig=px.pie(df, names='a', facet_col='b')
clearml_logger.report_plotly('long plot name that goes over facet - pie chart test',
series=f"pie chart test 1 ",
iteration=0,
figure=fig)
task.close()
task = Task.init(**{"project_name":"test",
"task_name":"test2",})
clearml_logger = task.get_logger()
fig=px.pie(df, names='a', facet_col='b')
clearml_logger.report_plotly('long plot name that goes over facet - pie chart test',
series=f"pie chart test 2 ",
iteration=0,
figure=fig)
task.close()
task = Task.init(**{"project_name":"test",
"task_name":"test3",})
clearml_logger = task.get_logger()
fig=px.pie(df, names='a', facet_col='b')
clearml_logger.report_plotly('long plot name that goes over facet - pie chart test',
series=f"pie chart test 3 ",
iteration=0,
figure=fig)
task.close() `
second problem:fig = px.imshow([[1,2], [3,4]], labels=dict(x="Predicted value", y="Real value"), x=['a', 'b'], y=['a','b'], title="Predicted and real values" ) fig.update_xaxes(side="top") clearml_logger.report_plotly('table test 2', series=f"table test 2 ", iteration=0, figure=fig) task.close()
in this example you will see the plot title above the series title, without even comparing
Getting the following error when I try to run this code:
Traceback (most recent call last): File "plots-issue.py", line 9, in <module> fig=px.pie(df, names='a', facet_col='b') TypeError: pie() got an unexpected keyword argument 'facet_col'
Hi MoodySheep3 ,can you please add a standalone snippet that reproduces this? What version of clearml
are you using?
and when you compare with oter (same tasks) the clearml title goes over the axis labels
CostlyOstrich36 this code will show you the first issue of headline does over the chart facet col header