You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently, we don't have enough tests including the norm=Normalize(...) argument. It should work for matplotlib and also datshader (after #309), but I think we need some more tests and maybe also a bit more documentation.
Also, I noted that both seem to give the same result, not sure if that's a bug
Thanks for reporting. The instance_id column has values in [0, 1, ..., 9]. With clip=True one would expect the values [0, 1, 2, 3, 4] to have the same color, and the values [7, 8, 9] to have the same color. So it seems like that there is a bug.
Did you notice this only for matplotlib or also for datashader?
After looking into this a bit more, I would say the behavior is not a bug: according to the matplotlib documentation (https://matplotlib.org/stable/api/_as_gen/matplotlib.colors.Normalize.html), with clip=False, values outside of [vmin, vmax] are mapped to values outside [0, 1] (and not exactly to 0 or 1 as would happen with clip=True). Then, the respective colormap can "can mark these under and over values with specific colors".
In the examples above, we use the default colormap viridis, which uses its minimal value for under values and its maximal value for over values (see below).
So, if you would set over and under differently, the result looks like this for clip=False (the clip=True plot looks like above)
Currently, we don't have enough tests including the
norm=Normalize(...)
argument. It should work for matplotlib and also datshader (after #309), but I think we need some more tests and maybe also a bit more documentation.Also, I noted that both seem to give the same result, not sure if that's a bug
The text was updated successfully, but these errors were encountered: