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

Sea ice metrics beta #1024

Merged
merged 78 commits into from
Jan 26, 2024
Merged
Changes from 1 commit
Commits
Show all changes
78 commits
Select commit Hold shift + click to select a range
c3a6cf1
initial commit
lee1043 Nov 7, 2023
5c7b40c
style fix (pre-commit)
lee1043 Nov 7, 2023
7e7cc6f
python 2 style to python 3 style, pre-commit fix
lee1043 Nov 7, 2023
7d3e823
explicit import for functions
lee1043 Nov 7, 2023
62de671
pre-commit fix: do not use bare except
lee1043 Nov 7, 2023
ef09d8f
clean up
lee1043 Nov 7, 2023
dae3443
clean up
lee1043 Nov 7, 2023
985fcee
Merge branch 'main' into 405_sic_ljw
lee1043 Nov 9, 2023
d3114fe
Merge branch 'main' of https://github.com/PCMDI/pcmdi_metrics into main
Nov 9, 2023
f5dd791
Merge branch '405_sic_ljw' of https://github.com/PCMDI/pcmdi_metrics …
Nov 10, 2023
46b955c
add file names
Nov 28, 2023
9b3a27a
update regions
Nov 30, 2023
752d343
add changes
Dec 8, 2023
6aac671
first draft
Dec 8, 2023
809882f
changes
Dec 18, 2023
1d4b654
more updates
Dec 21, 2023
8c5ccce
Merge branch 'bug/1009_lee1043_landmask' of https://github.com/PCMDI/…
Dec 21, 2023
ecd5e5a
changes
Dec 22, 2023
c475586
add parameter file
Dec 22, 2023
123313a
changes
Dec 22, 2023
8186e15
more fixes
Jan 4, 2024
d0f9a0b
new cases
Jan 4, 2024
724fe34
add file
Jan 4, 2024
502948c
Merge branch 'main' of https://github.com/PCMDI/pcmdi_metrics into 40…
Jan 4, 2024
3177b35
add readme
Jan 4, 2024
c97bc29
fix formatting
Jan 4, 2024
36e9366
Merge branch 'feature/1012_lee1043_stats' of https://github.com/PCMDI…
Jan 4, 2024
c9ef21e
fix coord issues
Jan 10, 2024
50085d4
update for symlinks
Jan 10, 2024
50da0c3
fix formatting
Jan 10, 2024
6a1a2cc
rework regions
Jan 12, 2024
814cee5
update links
Jan 12, 2024
145c942
add notebook draft
Jan 12, 2024
b04d9b7
add realizations
Jan 17, 2024
bf8977e
add figure script
Jan 19, 2024
47f7f7e
add script for demo plots
Jan 19, 2024
07ed06c
rerun
Jan 19, 2024
6cddae1
generalize obs
Jan 19, 2024
c215ad9
add obs
Jan 19, 2024
78ac004
update figures
Jan 20, 2024
25e2fda
update obs
Jan 20, 2024
b8396b6
add obs
Jan 20, 2024
bf7b83f
rerun with changes
Jan 20, 2024
c0a278a
rerun with markers
Jan 23, 2024
c751f4a
add scatter
Jan 23, 2024
cf49fbd
clean up comments
Jan 24, 2024
e9c6bc7
rerun, add text
Jan 24, 2024
29300c3
update labels
Jan 24, 2024
9208552
label updates
Jan 24, 2024
0e9c7e9
rerun
Jan 24, 2024
b9ec28c
add obs
Jan 25, 2024
f7b8c40
rerun
Jan 25, 2024
a50452d
move file
Jan 25, 2024
8b089c2
move nb
Jan 25, 2024
42401ee
add sea ice
Jan 25, 2024
68be632
make lib folder
Jan 25, 2024
d7193d4
remove import
Jan 25, 2024
15875ad
add shebang
Jan 25, 2024
ebafc2c
clean up
Jan 25, 2024
60c0e41
clean up
Jan 25, 2024
b6fd08c
edit command
Jan 25, 2024
65c6020
move files
Jan 25, 2024
2576403
add param again
Jan 25, 2024
b37e165
update nb
Jan 25, 2024
61a788f
update names
Jan 25, 2024
7b0457d
fix param
Jan 25, 2024
cfa990c
move file
Jan 25, 2024
803a362
add param
Jan 25, 2024
429815e
update README
Jan 25, 2024
fd28409
run pc
Jan 25, 2024
cb58450
Merge branch 'main' of https://github.com/PCMDI/pcmdi_metrics into 40…
Jan 25, 2024
b1f50d6
add init
Jan 25, 2024
05e3216
comments
Jan 25, 2024
23cdcfa
Merge branch 'main' into 405_sic_ao
lee1043 Jan 26, 2024
bf9af85
add parameters
Jan 26, 2024
d93211b
Merge branch '405_sic_ao' of https://github.com/PCMDI/pcmdi_metrics i…
Jan 26, 2024
2aae7c3
add nc-time-axis that is needed for plot in sea-ice notebook
lee1043 Jan 26, 2024
8311c81
minor update: add time
lee1043 Jan 26, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add parameters
  • Loading branch information
Ana Ordonez committed Jan 26, 2024
commit bf9af85e23edd3376bfd7564339367c6bf342048
62 changes: 58 additions & 4 deletions pcmdi_metrics/sea_ice/README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,61 @@
Sea ice metrics driver
# Sea Ice

Example command:
## Summary

## Demo

* Link to notebook

## Inputs

### Sectors

## Run

The PMP sea ice metrics can be controlled via an input parameter file, the command line, or both. With the command line only it is executed via:

```
sea_ice_driver.py -p parameter_file.py
```

or as a combination of an input parameter file and the command line, e.g.:

```
sea_ice_driver.py -p parameter_file.py --msyear 1991 --meyear 2020
```
sea_ice_driver.py -p param/parameter_file.py
```

## Outputs

The driver produces a JSON file containing mean square error metrics for all input models and realizations relative to the reference data set. It also produces a bar chart displaying these metrics.

## Parameters

* **case_id**: Save JSON and figure files into this subdirectory so that results from multiple tests can be readily organized.
* **test_data_set**: List of model names.
* **realization**: List of realizations.
* **test_data_path**: File path to directory containing model/test data.
* **filename_template**: File name template for test data, e.g., "CMIP5.historical.%(model_version).r1i1p1.mon.%(variable).19810-200512.AC.v2019022512.nc" where "model_version" and "variable" will be analyzed for each of the entries in test_data_set and vars.
* **var**: Name of model sea ice variable
* **msyear**: Start year for test data set.
* **meyear**: End year for test data set.
* **ModUnitsAdjust**: Factor to convert model sea ice data to fraction of 1. Uses format (flag (bool), operation (str), value (float)). Operation can be "add", "subtract", "multiply", or "divide". For example, use (True, 'multiply', 1e-2) to convert from percent concentration to decimal concentration.
* **area_template**: File path of model grid area data.
* **area_var**: Name of model area variable, e.g. "areacello"
* **AreaUnitsAdjust**: Factor to convert model area data to units of km2. Uses format (flag (bool), operation (str), value (float)). Operation can be "add", "subtract", "multiply", or "divide". For example, use (True, 'multiply', 1e6) to convert from m2 to km2.
* **metrics_output_path**: Directory path for metrics output in JSON files, e.g., '~/demo_data/PMP_metrics/'. The %(case_id) variable can be used here. If exists, should be empty before run.
* **reference_data_path_nh**: The reference data file path for the northern hemisphere. If data is global, provide same path for nh and sh.
* **reference_data_path_sh**: The reference data file path for the southern hemisphere. If data is global, provide same path for nh and sh.
* **ObsUnitsAdjust**: Factor to convert reference sea ice data to fraction of 1. Uses format (flag (bool), operation (str), value (float)). Operation can be "add", "subtract", "multiply", or "divide". For example, use (True, 'multiply', 1e-2) to convert from percent concentration to decimal concentration.
* **reference_data_set**: A short name describing the reference dataset, e.g. "OSI-SAF".
* **osyear**: Start year for reference data set.
* **oeyear**: End year for reference data set.
* **obs_var**: Name of reference sea ice variable.
* **ObsAreaUnitsAdjust**: Factor to convert model area data to units of km2. Uses format (flag (bool), operation (str), value (float)). Operation can be "add", "subtract", "multiply", or "divide". For example, use (True, 'multiply', 1e6) to convert from m2 to km2.
* **obs_area_template**: File path of grid area data. If unavailalbe, skip and use "obs_cell_area".
* **obs_area_var**: Name of reference area variable, if available. If unavailable, skip and use "obs_cell_area".
* **obs_cell_area**: For equal area grids, the area of a single grid cell in units of km2.


## Reference

Ivanova, D. P., P. J. Gleckler, K. E. Taylor, P. J. Durack, and K. D. Marvel, 2016: Moving beyond the Total Sea Ice Extent in Gauging Model Biases. J. Climate, 29, 8965–8987, https://doi.org/10.1175/JCLI-D-16-0026.1.