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

plotter: HeatMap with Rasterized smooths the heatmap #633

Open
kortschak opened this issue Aug 7, 2020 · 1 comment
Open

plotter: HeatMap with Rasterized smooths the heatmap #633

kortschak opened this issue Aug 7, 2020 · 1 comment

Comments

@kortschak
Copy link
Member

kortschak commented Aug 7, 2020

The addition of the rasterized option for the plotter.HeatMap was added to remove the lines between heat map cells resulting from vector drawing artifacts. The approach take was to make a heatmap where each heat map cell is a single pixel; the rasterisation. This small image is then rescaled to the size of the plot. This has the consequence that the image is rescaled with interpolation due to the use of plotter.Image which has this effect. In some cases, for example when you are plotting a continuous field you are likely to want this, but in cases where there is a discrete cell for each value, this is not correct. What the Rasterized option actually is a Smoothed option.

The original issue was raised to remove the artifactual lines, which is orthogonal. One solution is to have an unexported image rescaling function that does not interpolate. However, this loses the nice property of smooth scalar fields when they are wanted unless additional API knobs are added.

@sbinet
Copy link
Member

sbinet commented Aug 7, 2020

we could thus expose that rescaling function and provide a few other implementations (or examples).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants