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

plot W2W results #78

Merged
merged 7 commits into from
Jul 22, 2022
Merged

plot W2W results #78

merged 7 commits into from
Jul 22, 2022

Conversation

dargueso
Copy link
Collaborator

Added script and image to visualize before and after w2w.
Added information to README on outputs and this figure.

Added script and image to visualize before and after w2w.
Added information to README on outputs and this figure
Copy link
Collaborator

@jkittner jkittner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for having a look at this!

The image as a png does not work well with dark mode:
grafik
we can either create two plots (one for light, the other for dark mode) or just make it a jpg, leaving out the transparent background.
See also: https://github.blog/changelog/2021-11-24-specify-theme-context-for-images-in-markdown/

For the plot script I am wondering if we can do this in a loop, to save on copy pasta code. I'll have a look at that and maybe come up with a suggestion.

README.md Outdated Show resolved Hide resolved
README.md Outdated Show resolved Hide resolved
README.md Show resolved Hide resolved
@jkittner
Copy link
Collaborator

I tried merging the options that are applied to each plot a bit. Unfortunately I wasn't able to run the code, because I can't install cartopy. They require Proj>=8.0.0, but my focal only comes with 7.2.1. They don't provide any wheels on PyPi either, so I tried building a wheel in a docker container in ubuntu jammy, where you can get a newer version of libproj-dev. This worked, but the shared object file of libproj.so is obviously not included in the wheel (like for instance ecmwflibs does), copying it over also doesn't work, because libproj.so (statically) links to other shared objects, that are not on focal.
Only option I can see would be building libproj from source...

Maybe you can have one last look and check if the notebook runs, then I can clean up the commits a little and it's good to go. Thanks for your great work on this 👍

@dargueso
Copy link
Collaborator Author

I tried merging the options that are applied to each plot a bit. Unfortunately I wasn't able to run the code, because I can't install cartopy. They require Proj>=8.0.0, but my focal only comes with 7.2.1. They don't provide any wheels on PyPi either, so I tried building a wheel in a docker container in ubuntu jammy, where you can get a newer version of libproj-dev. This worked, but the shared object file of libproj.so is obviously not included in the wheel (like for instance ecmwflibs does), copying it over also doesn't work, because libproj.so (statically) links to other shared objects, that are not on focal. Only option I can see would be building libproj from source...

Maybe you can have one last look and check if the notebook runs, then I can clean up the commits a little and it's good to go. Thanks for your great work on this 👍

I tried to run it but I get the following error:

AttributeError: 'LineCollection' object has no property 'right_labels'

when saving the figure. For some reason gridlines doesn't like receiving that option through: ax1.gridlines(**ax_options).

If I try gl1.right_labels=False. It works fine. The same for top_labels.

@jkittner
Copy link
Collaborator

huh, that's annoying - I changed it back and was also able to get things up and running using docker. So this should all work now!

I'll have one last look myself, please also do so. Then I think it's ready and I can squash and merge it.

@dargueso
Copy link
Collaborator Author

huh, that's annoying - I changed it back and was also able to get things up and running using docker. So this should all work now!

I'll have one last look myself, please also do so. Then I think it's ready and I can squash and merge it.

Tested. Good to go! 🟢

Copy link
Collaborator

@jkittner jkittner left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jkittner jkittner merged commit 8297c85 into main Jul 22, 2022
@jkittner jkittner deleted the beforeafter_plot branch July 22, 2022 09:44
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

Successfully merging this pull request may close these issues.

2 participants