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

Add default CIA args #780

Merged
merged 5 commits into from
Oct 21, 2021
Merged

Add default CIA args #780

merged 5 commits into from
Oct 21, 2021

Conversation

acordonez
Copy link
Collaborator

The CIA default args JSON is incorporated into the PMP shared files to assist the migration to conda-forge.

Files:
share/setup_default_args.py: Copy of writejson.py from CIA. Edit arguments here, then run the script to generate share/DefArgsCIA.json
share/DefArgsCIA.json: The JSON containing the default arguments. This is now included in the PMP installation.
setup.py: Added share/DefArgsCIA.json to data_files. Added commands to regenerate DefArgsCIA.json when setup.py is run.
pcmdi_metrics/driver/pmp_parser.py: Get DefaArgsCIA.json file from PMP installation, not from separate CIA package install.

Testing:
To test this, you should create a new environment without the CIA (so don't use the CDAT nightly install). Then try running the mean climate driver.

conda create -n test1
conda activate test1
conda install -c conda-forge  python=3.6 cdms2 genutil cdutil cdp matplotlib numpy proj4 jupyterlab nb_conda nb_conda_kernels
python setup.py install
conda list (verify no cia)

@acordonez
Copy link
Collaborator Author

@lee1043 @gleckler1 I found a potential solution for the CIA args issue, where we install the DefArgsCIA.json file with the other PMP data files like obs_info_dictionary.json. Let me know what you think.

@gleckler1
Copy link
Contributor

@acordonez @lee1043 AO, this looks like a simple and elegant solution. I have not had a chance to test it yet but if it works, great! Looks like your plan is to 1) get this into master and 2) work with that in your experimentation with conda-forge, rather than do it one PR. Makes good sense, get the CIA issue out of the way. JL can review and merge when CI done. Great solution!

@lee1043
Copy link
Contributor

lee1043 commented Oct 20, 2021

@acordonez thanks for providing the guidance for testing the update. I've followed it and verified cia not included in the conda list, and confirmed demo notebook for MJO (that use PMP parser) works fine.

@acordonez
Copy link
Collaborator Author

@lee1043 Thanks for the testing and the flake8 fixes!

@lee1043 lee1043 merged commit 8993d51 into master Oct 21, 2021
@lee1043 lee1043 deleted the ao_add_args branch October 21, 2021 04:08
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.

None yet

3 participants