Skip to content

PCHEM Species file

Weiyuan Jiang edited this page Sep 9, 2024 · 9 revisions

Species File

The pchem component in GEOS requires the so called species file. This is some sort of temporally varying zonal average of some data it needs. Now when they setup an experiment via gcm_run.j it will use a species file by default that only has data through mid 2017 so if you are doing a run through that time period and it crashes like this:

 Error reading upper bracket month          -40
 Error reading upper bracket month          -40
 NetCDF: Index exceeds dimension bound

you probably hit the species file problem. The problem is that by default gcm_setup tells gcm_run.j (or if the model version if v11.6.0 or greater this will be in your linkbcs file) to use this species file, if you look in gcm_run.j (or linkbcs in v11.6.0 or greater) you will see these lines:

# DAS or REPLAY Mode (AGCM.rc:  pchem_clim_years = 1-Year Climatology)
# --------------------------------------------------------------------
#/bin/ln -sf $BCSDIR/PCHEM/pchem.species.Clim_Prod_Loss.z_721x72.nc4 species.data

# CMIP-5 Ozone Data (AGCM.rc:  pchem_clim_years = 228-Years)
# ----------------------------------------------------------
#/bin/ln -sf $BCSDIR/PCHEM/pchem.species.CMIP-5.1870-2097.z_91x72.nc4 species.data

# S2S pre-industrial with prod/loss of stratospheric water vapor
# (AGCM.rc:  pchem_clim_years = 3-Years,  and  H2O_ProdLoss: 1 )
# --------------------------------------------------------------
#/bin/ln -sf $BCSDIR/PCHEM/pchem.species.CMIP-6.wH2OandPL.1850s.z_91x72.nc4 species.data

# MERRA-2 Ozone Data (AGCM.rc:  pchem_clim_years = 39-Years)
# ----------------------------------------------------------
/bin/ln -sf $BCSDIR/PCHEM/pchem.species.CMIP-5.MERRA2OX.197902-201706.z_91x72.nc4 species.data

In the example above note that line that is uncommented. This tells it to use a species file that as the name says, is valid from 1979 to 2017. If you go beyond that you will crash. If you need to run past mid 2017 you have several choices, you need to to tell it to link in one of the other species file make sure only one is uncommented. Probably you want to use the one that says 1-year climatology or the 228 year one. So uncomment one of them.

There is one other wrinkle, you have to add something in the AGCM.rc to tell it how many years are in the file for some reason... In your AGCM.rc look for this, the merra2 one that is used by default has 39 years, hence the 39 you might see:

       pchem_clim: species.data
       pchem_clim_years: 39

you need to change the pchem_clim_years: entry, if you use the species file that says "DAS or REPLAY" sent this to 1. If you use CMIP-5 set it to 228

Which one you use, up to you, this is just to address the problem at hand.

Once again, in model versions greater than or equal to v11.6.0 the symlink you need to modify will be in the linkbcs file!