CABLE site runs with ACCESS forcing

There is potential value in being able to run CABLE standalone for one or more locations (sites) using forcing taken from ACCESS model simulations. This may be an easier option for investigating different behaviour between online and offline simulations as a step towards running global simulations.

This topic captures notes associated with this task.

Getting met forcing from ACCESS-ESM1.5

Timeseries output from grid-cells is needed. The list of grid-cells is supplied through the domain field defined in the STASHC file for an ACCESS-ESM1.5 run. Examples are DGTS_PT (21 locations, probably mostly flux towers), DCO2TS (locations of atmospheric CO2 monitoring sites), DCO2TSL (similar to DCO2TS but for variables defined on model levels rather than just at the surface).

The required time field in STASHC is TALLTS.

The variables to be output are listed in the STASHC file by section and number. This is what I have currently used to match up with what CABLE requires

Section Number StashMaster CABLE
0 409 SURFACE PRESSURE AFTER TIMESTEP Psurf
1 235 TOTAL DOWNWARD SURFACE SW FLUX SWdown
2 207 DOWNWARD LW RAD FLUX: SURFACE LWdown
3 230 10 METRE WIND SPEED ON C GRID Wind
3 236 TEMPERATURE AT 1.5M Tair
3 237 SPECIFIC HUMIDITY AT 1.5M Qair
5 216 TOTAL PRECIPITATION RATE KG/M2/S Rainf

In an ESM1.5 set-up, the output is requested in the STASHC file using syntax like this:

&STREQ IMOD= 1, ISEC=0, ITEM=409, IDOM=33, ITIM=19, IUSE=12 /

In this case the DGTS_PT domain is the 33rd in the file, and the TALLTS time field is the 19th in the file. IUSE determines which output file the data is written to. In this case it goes to *.pg files.

If adding output requests to the STASHC file, remember to increase the number (NUM_REQ) at the top of the file

&STASHNUM NUM_REQ= 280, NUM_DOM=37, NUM_TIM=20, NUM_USE=12 /

Note that the radiation output will be at the 3 hourly radiation timestep. Other output will be half-hourly.

Update June 2024
CABLE standalone needs to be run with the temperature and specific humidity from the lowest ACCESS model level not the 1.5 m values. These stash outputs were used.

Section Number StashMaster CABLE
16 4 TEMPERATURE ON THETA LEVELS Tair
0 10 SPECIFIC HUMIDITY AFTER TIMESTEP Qair

Note that since these are multi-level fields, a new output domain is required to specify the level. This has been set up for the pft-focussed 13-site set of grid-cells described in a later post.

Do we want to add the atmospheric CO2 concentration to that list? Is it possible to output it in that way?

Hi @clairecarouge , yes - at some point we will probably want to add CO2. At this stage I was just trying to document what I’d done so far.

1 Like

Re-formatting ACCESS output for CABLE standalone site input

This documents the steps I used to convert ACCESS output to a file that CABLE standalone could use. Not all steps may be required and there will, no doubt, be better and more efficient ways to do this. The ACCESS output was for the DGTS_PT domain which is 21 grid-cells. The 9th in the list matches the approximate location of the Tumbarumba flux tower site.

  • Converted *.pg (monthly) files to netcdf and combine across the 3 years that I’d run ACCESS. Did this separately for the radiation fields (3-hourly) and the other fields (half-hourly). Used a convsh script, conv2nc.tcl (e.g. /g/data/p66/rml599/scripts/conv2nc.tcl). fieldlist defines which variables in the *.pg files are converted (counting from 0 and consistent with the listing if viewing a file using xconv).
  • Interpolated radiation data to half-hourly using cdo intntime,6 ifile ofile. [Gave 5 less timesteps than half-hourly data as no extrapolation beyond last radiation output.]
  • Changed variable names using cdo chname,oldname,newname ifile ofile
  • Selected one site (Tumbarumba) from netcdf files using cdo selgridcell,9 ifile ofile. This command coped with the input netcdf file not being on a lon-lat grid. It also looked possible to select more than one site by providing a list of ‘grid-cell’ numbers.
  • Merged radiation timeseries with other timeseries using cdo merge ifile1 ifile2 ofile. [Last 5 timesteps discarded so that the length of the timeseries matched.]
  • Convert time units using cdo settunits,seconds ifile ofile
  • After this I started hacking the netcdf file directly by converting backwards and forwards from ascii to binary. Things I learnt along the way:
    a. the time units need to be in the form YYYY-MM-DD, ACCESS had given 101-1-1, crashing CABLE.
    b. CABLE standalone single site assumes timeseries is in local time, so need to add in time:coordinate = “GMT”
    c. convsh does not give sensible attributes for the wind speed variable. Need to at least add in the units.
    d. cdo selgridcell had reduced the dimensions of the variables to just time. CABLE looks for an x dimension (also others?)
    e. Added in latitude, longitude, elevation and height arrays to match what was in TumbaFluxnet.1.3_met.nc

After all this, CABLE ran and appeared to give plausible results. Now we just need a cleaner way of doing this.

1 Like

The time variable needs more work. I note that the documentation says it should be double precision. In my reformatting I don’t seem to have enough precision - the timestep calculation was OK in my first run but when trying to restart and run for an extra year, it wasn’t OK, 1808s instead of 1800s.

Also from the restarted run, the log file tells me that the run goes from 2004 to 2005 but the output netcdf file has time running from 2001.

Set of grid-cells to focus on each pft

Chose a set of grid-cells for testing to represent each pft. If possible, used a grid-cell with tile fraction = 1.0 and land fraction = 1.0. If not, found a grid-cell with as large a fraction as possible and retaining a land fraction = 1.0.

For ESM1.5, these grid-cells were chosen. Domains for stash output are DTS_PFT for single level variables and DTS_PFTL1 for variables on atmospheric levels.

PFT E-W index N-S index Longitude Latitude Fraction
Evergreen needleleaf 30 123 54.375 62.5 1
Evergreen broadleaf 155 68 -71.25 -6.25 1
Deciduous needleleaf 64 124 118.125 63.75 1
Deciduous broadleaf 160 57 -61.9 -20 0.9173
Shrub 80 50 148.1 -28.8 0.7123
C3 grass 140 111 -99.375 47.5 1
C4 grass 19 78 33.8 6.2 0.9818
Tundra 43 127 78.75 67.5 1
Crop 41 99 75 32.5 1
Wetlands 42 124 76.875 63.75 0.6975
Bareground 6 93 9.375 25 1
Lakes 27 108 48.75 43.75 1
Ice 73 9 135 -80 1

Made a CABLE met file with all 13 grid-cells i.e. no longer required the cdo,selgridcell step above.

Running CABLE standalone for multiple sites identified a bug. See Defined ncid_mask for met data files with multiple sites. Fixes #306.

Creating an ACCESS ‘gridinfo’ file

CABLE standalone runs use ‘gridinfo_CSIRO_1x1.nc’ for some initial data or parameters/ancillary data if it is not available in met or restart files. For site runs, data is taken from the nearest 1 degree by 1 degree grid-cell. To ensure ACCESS values were used in the CABLE standalone tests, a new gridinfo file has been created at ACCESS resolution.

Most of the fields required for the gridinfo file are available from an ACCESS restart. For these tests, the ‘restart’ created for the start of the simulations was used (PI-PFT-01c.astart-01010101). Used /g/data/p66/rml599/Site-tests/conv2nc.tcl to convert this list of fields from the restart to netcdf

set fieldlist "3 11 13 27 28 29 30 31 32 33 90 95 98 142 143 144 230 231 232 233 234 235"

Output is /g/data/p66/rml599/Site-tests/access.astart101.nc

This table matches the variable in the gridinfo file with the field number from the restart and the variable name in access.astart101.nc

Gridinfo Field no. access-file Notes
area Used cmorised areacella_fx
iveg 95 field1391 On tiles, pick dominant
patchfrac
isoil Set to 2 for all veg types except 17 when set to 9
SoilMoist 3 sm Convert from kg/m2 to m3/m3. Divide by soil layer thickness and rho_water (1000)
SoilTemp 11 soiltemp
SnowDepth Still to be added. Currently set to 0.
Albedo Dummy value, 0.2 - not used but checked so needs to be sensible
LAI 235 temp_5 On tiles so selected LAI for dominant veg type
SoilOrder 230 temp Convert to integer
Ndep 231 temp_1 Need to multiply by 365.
Nfix 232 temp_2
Pwea 234 temp_4
Pdust 233 temp_3
clay 142 field1630
silt 143 field1631
sand 144 field1632
swilt 27 field329
sfc 28 field330
ssat 29 field332
bch 90 field1381
hyds 30 field333 Need to divide by 1000.
sucs 33 field342
rhosoil Set according to isoil, 1600. for isoil=2, 910. for isoil=9
cnsd 32 field336
css Set according to isoil, 850. for isoil=2, 2100. for isoil=9
albedo2 98 field1395

Gridinfo_CSIRO_1x1.nc has monthly values for SoilMoist, SoilTemp and SnowDepth. Currently January values have been copied into all months since the other months are not being used.

Very ugly code to write an ACCESS gridinfo file is /g/data/p66/rml599/Site-tests/writegridinfo.F90. Output is /g/data/p66/rml599/Site-tests/gridinfo.access101.nc