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

Further plot updates and fix observed contour lines #185

Merged
merged 14 commits into from
Feb 25, 2025

Conversation

dabail10
Copy link
Collaborator

@dabail10 dabail10 commented Feb 4, 2025

Description of changes:

  • Please add an explanation of what your changes do and why you'd like us to include them.
  • Fix the observed contour lines in the spatial plots.
  • add back in import of nc_time_axis
  • Add the "maximum" ice concentration for contour plots and Labrador Sea plots

All PRs Checklist:

New notebook PR Additional Checklist (if these do not apply, feel free to remove this section):

  • Have you hidden the code cells (#8 in Adding Notebooks Guide) in your notebook?
  • Have you removed any unused parameters from your cell tagged with parameters? These can cause confusing warnings that show up as DAG build with warnings.
  • Have you moved any observational data that you are using to /glade/campaign/cesm/development/cross-wg/diagnostic_framework/CUPiD_obs_data and ensured that it follows this format within that directory: COMPONENT/analysis_datasets/RESOLUTION/PROCESSED_FIELD_TYPE?

Copy link
Collaborator

@TeaganKing TeaganKing left a comment

Choose a reason for hiding this comment

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

Let me know if you still want to make additional changes or if this is ready?

Copy link
Collaborator

@mnlevy1981 mnlevy1981 left a comment

Choose a reason for hiding this comment

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

Besides the comment about the directory structure of the obs datasets, I'm a little confused about how path_nsidc is defined inside plot_diff.py. Can this be an argument passed in from the notebook, so this function works on computers that don't have access to campaign store? A couple of related questions:

  1. is path_nsidc the right variable name? (Is this still NSIDC data? Isn't HadOIBl coming from UKMO?)
  2. Should we have something like obs_data_root that is set to /glade/campaign/cesm/development/cross-wg/diagnostic_framework/CUPiD_obs_data/ice/analysis_datasets in config.yml and then we build up all the other path_ variables from that? path_nsidc = os.path.join(obs_data_root, 'hemispheric_data', 'NSIDC_SeaIce_extent'), path_hadoibl = os.path.join(obs_data_root, '1x1', 'HadOIBl'), etc?

This might require a little clean up in the other ice notebooks and .py files, but it will set a good precedent for later updates

@TeaganKing TeaganKing linked an issue Feb 11, 2025 that may be closed by this pull request
@dabail10
Copy link
Collaborator Author

Ok. I have merged Alice's changes and I think this is ready for review.

@TeaganKing
Copy link
Collaborator

Hi @dabail10 , thanks for making the parameter change. I actually already did that in #191 , and we'll still need the first part of the parameters (eg, parameter = "" #comment instead of #parameter=""). Do you mind removing the change you just made?

@dabail10
Copy link
Collaborator Author

Whoops. I missed that. I think we might have some conflicts. Can you remove these from your PR to keep it separated?

@TeaganKing
Copy link
Collaborator

We'll still need the first part of the parameters (eg, parameter = "" #comment instead of #parameter="")-- thus, I think your changes listed here will not actually work with the parameters cell. Also, this is really more related to the observational repository changes than to this PR, so I'd prefer to leave it in #191. I'll remove the changes here though.

@mnlevy1981
Copy link
Collaborator

I think merging the latest main (including #191) into this branch should raise a conflict that we can resolve by keeping the version that currently appears on main

@TeaganKing
Copy link
Collaborator

I think merging the latest main (including #191) into this branch should raise a conflict that we can resolve by keeping the version that currently appears on main

That's exactly what I just did :)

@dabail10
Copy link
Collaborator Author

I think this is ready. I have fixed the parameter boxes and now use obs_data_dir.

Copy link
Collaborator

@mnlevy1981 mnlevy1981 left a comment

Choose a reason for hiding this comment

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

I focused on the Hemis_seaice_visual_compare_obs_lens.ipynb notebook, because that's what gets run in key_metrics, and didn't look closely at Hemis_seaice_visual_compare_contour.ipynb. I have a few minor comments about the obs_lens notebook:

  1. path_model is in config.yml but not in the default parameter cell
  2. obs_data_dir is used in the definition of path_nsidc but also appears in calls like os.path.join(obs_data_dir, path_nsidc, "N_01_extent_v3.0.csv"); I think you just want path_nsidc = os.path.join("ice", "analysis_datasets", "hemispheric_data", "NSIDC_SeaIce_extent") (formatted however pre-commit decides it should be formatted)

Also, I'll fix this in a separate PR but currently these notebooks don't support CESM_output_dir and base_case_output_dir being different

Copy link
Collaborator

@mnlevy1981 mnlevy1981 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 making these changes, this looks like it is ready to merge!

@mnlevy1981 mnlevy1981 merged commit 9f80f7e into NCAR:main Feb 25, 2025
2 checks passed
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.

Sea ice contour plots
3 participants