ThickDove42 sorry, it took some time 🙂import json from trains.backend_api.session.client import APIClient client = APIClient() events = client.events.get_task_plots(task='task_id_here') table = json.loads(events.plots[0]['plot_str']) print('column order', table['data'][0]['cells']['values'])
Not the most comfortable way, but at least it is there
Yeah, I know how to do it manually from the web GUI using the button, that's just not scalable. What I need is the Python SDK code. It doesn't have to be a single liner.
I understand. Thing is I already have a bunch of tasks where I logged the tables and did not upload an artifact. If I can get them using the SDK, as something that I can possibly extract the values from as JSON (as in the web GUI) that would be great. Currently I'm just manually downloading the json one by one as I need them.
ThickDove42 If you need the name itself :events.plots[0]['metric'] events.plots[0]['variant']
You should have a download button when you hover over the table, I guess that would be the easiest.
If needed I can send an SDK code but unfortunately there is no single call for that
AgitatedDove14 Looks goo, thanks! I see that I can also find the plot index based on the 'metric' key, so I can write something that would choose the plot by name rather than ordinal position.
Hi ThickDove42 ,
Yes, but by the time you will be able to access it, it will be in a display form (plotly), not very convient.
If this is something you need to re-use, I would argue that it is an artifact and should be stored as artifact (then accessing it is transparent) , obviously you can both report as table and upload as artifact, no harm in that.
what do you think?