question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

PNG export / unwanted rotation of y label

See original GitHub issue

I think there is a bug in the PNG export option of bokeh While the inline plot is showing the name of the axis nicely:

import numpy as np
import holoviews as hv
hv.extension('bokeh')

test_array = np.random.rand(100,100)
hv.Image(test_array).redim.label(y='AXIS')

the png export of the plot does very weird things to the label:

%%output filename="view_plot.png" fig="png"
hv.Image(test_array).redim.label(y='AXIS')

So far I didnt find any plot option to solve this.

view_plot png

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

2reactions
mattpapcommented, Nov 16, 2017

There are known issues with fonts in phantomjs, and the behavior is platform dependent. I can’t reproduce this locally, but I recall seeing this on travis ci. The short term solution is to do a google search for “phantomjs fonts linux” (or “debian” or something similar) and follow one of the tutorials that are supposed to help with this (I don’t know if they actually do; use at your own risk). Alternatively you can modify bokeh(.min).css to use a different font from the default Helvetica, and if this doesn’t work, provide a font on your own (using CSS’ @font-face syntax). In the long term we will switch from phantomjs to chrome headless to resolve this and many more issues we have with phantomjs.

0reactions
philippjfrcommented, Oct 10, 2018

Since this is an upstream issue and there is nothing we can do about it at the holoviews level I’m going to close.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Labels rotation doesn't work with exporting and useHTML #5393
Hi, It looks like chart labels are not rotated with exported charts. The charts are exported correctly only to svg file.
Read more >
x axis label cropped on saved image - python - Stack Overflow
You can play around with the rcParams size settings and the plt.subplots_adjust settings until you get your desired image.
Read more >
Why it Lost text when export graphics?
I want to export graphics which has a text object, but it will lose the text when given a special rotate angle.
Read more >
changing a parts orientation and exporting as a new part ...
I've managed to do it using your instructions, however i used "Actions > Part Transformation>Add Manipulation" to rotate the model while keeping the...
Read more >
Adjust rotation and canvas size in Photoshop - Adobe Support
This document outlines the different methods you can use to adjust your image's cropping, rotation, and canvas size.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found