-
-
Notifications
You must be signed in to change notification settings - Fork 358
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
[BUG] Uneven pixel spacing with heatmap in GR backend #4833
Comments
Might be related to #4158 |
I identified the Lines 1339 to 1354 in 10ee593
Another problem is, that the recipe overrides the heatmap series type to image if it is available by the backend and manually defines the x and y coordinates, circumventing the adjustment of the x and y coordinates for centered pixel bins, which is applied only to the heatmap series type in the gr backend by the function heatmap_edges .
I will look into updating the recipes for color matrices and open a PR. |
The underlying issue is fixed in gr now sciapp/gr@b9eafa6 Until the fix is released in GR.jl and Plots uses the updated GR version the workaround is to explicitly set |
Details
When plotting a matrix of RGB colors as a heatmap for certain matrix sizes the pixel spacing of the heatmap are uneven. The severity of the unevenness depends on the size of the matrix that I am plotting. However, I could not recognize any pattern, of when the unevenness is worse.
Below is a MWE of an extreme case (the axis limits are there to see it better, they do not change the unevenness):
produces:
Changing the matrix size to 100x100 looks uniform. This error also does not appear when a normal Float value is used instead of a RGB value.
In the plotly backend the RGB heatmap also looks fine:
Backends
This bug occurs on ( insert
x
below )Versions
Plots.jl version: v1.39.0
Backend version: GR v0.72.7
Output of
versioninfo()
:The text was updated successfully, but these errors were encountered: