Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] HTML wont display #33

Open
LaurenBK opened this issue Nov 10, 2021 · 6 comments
Open

[Bug] HTML wont display #33

LaurenBK opened this issue Nov 10, 2021 · 6 comments
Labels
bug Something isn't working databricks enhancement New feature or request

Comments

@LaurenBK
Copy link

Hi, thank's for this package - it looks like exactly what I was looking for.
I am struggling to find a way to use this in Databricks though which is where I want to use this. The package runs fine but instead of seeing the output as an image, I see
<IPython.core.display.HTML object> twice
when I try ipyplot.plot_images or ipyplot.plot_class_tabs
Is there a way to add a flag to return the html directly from the function call so I can use the built in function to display html? Because the html is hidden, I can't click the link that would display the html

@karolzak
Copy link
Owner

Hi @LaurenBK,
Yeah, it should be possible, it would return HTML as string though - would that work for you?

@karolzak karolzak added bug Something isn't working databricks labels Nov 10, 2021
@LaurenBK
Copy link
Author

Hi, yes please that would be great. Databricks has a method to display html but the command is slightly different to jupyter which is why the current html helper is not displaying it correctly. I should be able to get around this with the string

@karolzak
Copy link
Owner

Hi, yes please that would be great. Databricks has a method to display html but the command is slightly different to jupyter which is why the current html helper is not displaying it correctly. I should be able to get around this with the string

Now that I think about it, maybe it would make sense to add an internal check for environment and if it's Databricks then use different display function?

@LaurenBK
Copy link
Author

That would be much simpler for a user. Would checking for a Databricks environment be simple though? It looks like you might do it by checking for environment variables but would these always be set up the same way? It might end up being more work down the line.

@karolzak
Copy link
Owner

I'll think about implementing both options. Returning html as a string is simpler and it would be a good "quick and dirty" workaround but in longer perspective I'll think about adding automatic platform detection to better address running IPyPlot in different environments

@karolzak karolzak changed the title HTML wont display [Bug] HTML wont display Mar 14, 2022
@karolzak karolzak added this to To do in Continuous improvements via automation Sep 20, 2022
@karolzak karolzak added the enhancement New feature or request label Sep 20, 2022
@utkuarslan5
Copy link

Experiencing same issue here. How can I return the HTML as string with ipyplot.plot_images ? Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working databricks enhancement New feature or request
Development

No branches or pull requests

3 participants