Examples: query, "exact match", wildcard*, wild?ard, wild*rd
Fuzzy search: cake~ (finds cakes, bake)
Term boost: "red velvet"^4, chocolate^2
Field grouping: tags:(+work -"fun-stuff")
Escaping: Escape characters +-&|!(){}[]^"~*?:\ with \, e.g. \+
Range search: properties.timestamp:[1587729413488 TO *] (inclusive), properties.title:{A TO Z}(excluding A and Z)
Combinations: chocolate AND vanilla, chocolate OR vanilla, (chocolate OR vanilla) NOT "vanilla pudding"
Field search: properties.title:"The Title" AND text
Answered
Hi, I Try To Write An Article On Medium About Clearml And Face Some A Problem With Plotly Figures. When Displaying The Figure Locally In A Browser Works Fine, But On The Cleaml Server (I Use The Free Tier Service) The Plot Is Empty And Has The Title 'Unkn

Hi,
I try to write an article on medium about ClearML and face some a problem with plotly figures.
When displaying the figure locally in a browser works fine, but on the CleaML server (I use the free tier service) the plot is empty and has the title 'Unknown data' 😞
This is how the figure is been created and reported. The difference to the https://github.com/allegroai/clearml/blob/master/examples/reporting/plotly_reporting.py is that I'm calling px.line(...) and not px.scatter(...)
fig = px.line(df, title=getattr(df, 'ticker')) task.get_logger().report_plotly(title='finance', series=args.symbol, iteration=0, figure=fig)Sources can be found on https://github.com/laiki/ClearML_playground
I ran the plotly_reporting.py example locally and the uploaded plot was ok.
Any idea why this happens when making use of line plots?
Regards
Wasili

  
  
Posted 3 years ago
Votes Newest

Answers 26


great , thanks a lot

  
  
Posted 3 years ago

image

  
  
Posted 3 years ago

👍

  
  
Posted 3 years ago

WickedGoat98 what's the clearml version you are using?

  
  
Posted 3 years ago

AgitatedDove14 I'm just before finalizing the article and have issues now in getting a clone processed by an agent:(
The problem is plotly and something called orca. First it was not installed, than it was not able to start a browser as I run the agent as different user in an su - ... shell
I will try to use the plotly option
auto_open=False

  
  
Posted 3 years ago

AgitatedDove14 the index astype(str) did the magic 🙂 thanks

  
  
Posted 3 years ago

AgitatedDove14 I fixed it. The index looked like a string but wasn't ...

  
  
Posted 3 years ago

AgitatedDove14 no, I mean the exemple worked locally and on the server, but m, plot is shown only locally

  
  
Posted 3 years ago

WickedGoat98 let me check...

  
  
Posted 3 years ago

WickedGoat98 this is awesome! Let me know how I could help 🙂
BTW: I checked regrading the plot comparison, this is a BE issue due to the size of the plot, I was told a fix will be deployed in a day or two.

  
  
Posted 3 years ago

AgitatedDove14 unfortunately I still have issues with the plot. After removing the first row I get a wierd empty remote plot where the axis is a counter instead of a date. Seems not to be clearml related and I need to get more in touch with plotly to analyze it.

  
  
Posted 3 years ago

Hey WickedGoat98
I found the bug, it is due to the fact the numpy (passed to plotly) contains both datetime and nan, and plotly.js does not like it. I'll make sure this is fixed, in the meantime you can just remove the first row (it contains the nan):
df = pd.concat([tickerDf.Close, tickerDf_Change.Close_pcent], axis=1) df = df[1:]

  
  
Posted 3 years ago

Thanks for checking

  
  
Posted 3 years ago

Sounds good :) I'm currently trying to run an orca instance ... but without success

  
  
Posted 3 years ago

WickedGoat98 give me a minute, I'm not sure it is not ClearML related

  
  
Posted 3 years ago

WickedGoat98 Nice!!!
BTW: The fix should solve both (i.e. no need to manually cast), I'll make sure the fix is on GitHub so you'll be able to verify 🙂

  
  
Posted 3 years ago

AgitatedDove14 the first plotly plot is fine and I added a second one which fails again 😞 I checked that the indes is of type str but the remote plot is again having integer as x-axis
The code is in github if you would like to check. I will proceed converting the index back and forth to find a way getting it running

  
  
Posted 3 years ago

WickedGoat98 until the next RC release (should not take long) this will solve it:
df = pd.concat([tickerDf.Close, tickerDf_Change.Close_pcent], axis=1) df = df[1:] df.index = df.index.astype(str) setattr(df, 'ticker', args.symbol)Basically removing the nan and converting the datetime to string representation (so plotly.js likes it)

  
  
Posted 3 years ago

AgitatedDove14 it seems a comparison of plots the orig. & cloned experiment is not possible. Is this a bug on the server?

  
  
Posted 3 years ago

with
if task.running_locally(): fig.show()it works 🙂
thanks you for the support

  
  
Posted 3 years ago

WickedGoat98 Same for me, let me ask the UI guys, I think this is a UI bug.
Also maybe before you post the article we could release a fix to both, what do you think?
EDIT:
Never mind 🙂 i just saw the medium link, very cool!!!

  
  
Posted 3 years ago

Thanks. I wanted to finalize it as it took me already much longer than I expected

  
  
Posted 3 years ago

Hi WickedGoat98

I try to write an article on medium about ClearML and face some a problem with plotly figures.

This is awesome !

I ran the plotly_reporting.py example locally and the uploaded plot was ok.

So are you saying the same example code from the repository worked okay on your server but showed nothing on the hosted server ?

  
  
Posted 3 years ago

AgitatedDove14 I would like to publish additional 2 articles handling the use with Docker and Kubernetes. Docker I managed, but my Kubernetes knowledge is quite low. I managed to set-up K3S cluster which might be also worth an article, but I still habe not realy the understanding to add workers with agents to it...
It might take some time till I will write the Kubernetes stuff. Once I'm doing I will let you know

  
  
Posted 3 years ago

Okay, I was able to reproduce it (this is odd) let me check ...

  
  
Posted 3 years ago

WickedGoat98 is this related to plotly opening a web page when you call show() method ?
You can do:
if not Task.running_locally() fig.show()

  
  
Posted 3 years ago
974 Views
26 Answers
3 years ago
7 months ago
Tags