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

CI: bump answers for numpy 1.21 #3373

Merged
merged 2 commits into from
Jun 23, 2021

Conversation

neutrinoceros
Copy link
Member

@neutrinoceros neutrinoceros commented Jun 23, 2021

PR Summary

With the release of numpy 1.21, the following answer tests finale images changed slightly
yt/visualization/tests/test_plotwindow.py:test_attributes_wt

here's the existing reference
tmpokwzf291
and here's the new result
tmp7j8gqehr

Here's a minimal script to reproduce this (thanks @Xarthisius for posting this on Slack)

import yt
from yt.utilities.answer_testing.framework import data_dir_load
WT = "WindTunnel/windtunnel_4lev_hdf5_plt_cnt_0030"
plot_field = ("gas", "density")
ds = data_dir_load(WT)
ax = "z" 
slc = yt.SlicePlot(ds, ax, plot_field)
slc.set_zlim(plot_field, 1e-25, 1e-23)
slc.save()

The actual range in the data is [0.05956075, 6.61460495] (g/cm^3), so the resulting image is kinda irrelevant in both cases and the new one is actually consistent with what can be obtained with a very simple, pure mpl + numpy example script:

import matplotlib.pyplot as plt
from matplotlib.colors import LogNorm
import numpy as np
data = np.ones((10, 10))
fig, ax = plt.subplots()
im = ax.imshow(data, norm=LogNorm(vmin=1e-25, vmax=1e-23))
ax.set(title=f"numpy v{np.__version__}")
fig.colorbar(im)
fig.savefig(f"/tmp/v{np.__version__}.png")

v1 21 0

My conclusion is that there is nothing to fix on our side so we can simply bump our answers and call it a day.

update: as discussed on Slack with @Xarthisius and @jzuhone , I've updated the PR to simply drop the problematic test.

@neutrinoceros neutrinoceros changed the title bump answers for numpy 1.21 CI: bump answers for numpy 1.21 Jun 23, 2021
@neutrinoceros neutrinoceros added infrastructure Related to CI, versioning, websites, organizational issues, etc blocker Highest priority level bug labels Jun 23, 2021
@jzuhone
Copy link
Contributor

jzuhone commented Jun 23, 2021

LGTM

@Xarthisius Xarthisius merged commit 96b95e7 into yt-project:main Jun 23, 2021
@neutrinoceros neutrinoceros deleted the bump_anwsers_numpy1.21 branch June 23, 2021 19:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocker Highest priority level bug infrastructure Related to CI, versioning, websites, organizational issues, etc
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants