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

Image doesn't show anything if only one value exists #3350

Closed
ahuang11 opened this issue Dec 26, 2018 · 3 comments
Closed

Image doesn't show anything if only one value exists #3350

ahuang11 opened this issue Dec 26, 2018 · 3 comments

Comments

@ahuang11
Copy link
Collaborator

ahuang11 commented Dec 26, 2018

Nothing shows, but data is there:

import holoviews as hv
hv.Image(np.array([[np.nan, np.nan, np.nan], [1, 1, 1], [np.nan, np.nan, np.nan]]))

See some black

hv.Image(np.array([[np.nan, np.nan, np.nan], [1, 2, 1], [np.nan, np.nan, np.nan]])).options(tools=['hover'])

Workaround:

hv.Image(np.array([[np.nan, np.nan, np.nan], [1, 1, 1], [np.nan, np.nan, np.nan]])).options(tools=['hover'], cmap=['black'])

I think it's because the first color is white, and nan is also white?

image

@philippjfr
Copy link
Member

@jbednar This is one problem with the fire colormap as the default.

@jbednar
Copy link
Member

jbednar commented Dec 27, 2018

Right. There are lots of other issues with that, including that fire assumes a black background and the default for most situations is a white page, and that fire has the same issue on a black background (as it includes full black). I think we already have an issue discussing all those problems, but I don't think we ever came to an agreement about any better approach.

Copy link

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 24, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants