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.

transparent option for rasterize?

See original GitHub issue

When I use datashade I get the transparent background that lets me see the WMTS tiles

2018-03-27_7-57-13

but when I use rasterize, I get grey instead of transparent 2018-03-27_7-57-58

and I can’t figure out how to fix it.

I did try to figure this out by googling and looking in docs and code, but failed… 😞

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:2
  • Comments:25 (21 by maintainers)

github_iconTop GitHub Comments

3reactions
philippjfrcommented, Mar 27, 2018

A transparent background is actually the default when using GeoViews, i.e. if you were to switch to gv.TriMesh on the input to rasterize it would return a gv.Image (as long as you are using master of hv and gv), which uses a transparent color for NaN values. This was a deliberate choice because when plotting non-geographic data you often do want to see the nan values, but I’d be happy to have this discussion again.

To override the default NaN color to be transparent you can set clipping_colors={'NaN': (0, 0, 0, 0)} as a plot option. This will be covered properly in the new “Styling Plots” user guide being added in https://github.com/ioam/holoviews/pull/2483.

2reactions
jbednarcommented, Mar 27, 2018

Personally, I don’t care about shorter in this case, I care about clearer, and transparent is vastly clearer than (0,0,0,0) and slightly clearer than clear (no pun intended).

Read more comments on GitHub >

github_iconTop Results From Across the Web

Solved: Rasterize/Flatten layer transparency quickly - 11369217
For the "Opacity" layer setting to go from X% (eg. 85%) to 100%, and for the transparency to be permanently applied to the...
Read more >
Bug: Transparent or rasterizing layers that are part of a group ...
Data frames are processed as raster if they contain visible group layers that have individual layers that are not visible, and are symbolized...
Read more >
transparent option for rasterize? · Issue #2487 - GitHub
A transparent background is actually the default when using GeoViews, i.e. if you were to switch to gv.TriMesh on the input to rasterize...
Read more >
Flattening Settings - GMG Color
In the process of rasterizing, vector/text objects are rasterized according to the resolution defined under Line Art and Text Resolution. Other transparent ......
Read more >
When to flatten transparency and when to rasterize? - Reddit
General rule for packaging - don't ever use transparency or blend modes directly in Illustrator (except Darken as a substitute for Overprint).
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