Scheduled Downtime
On Tuesday 24 October 2023 @ 5pm MT the forums will be in read only mode in preparation for the downtime. On Wednesday 25 October 2023 @ 5am MT, this website will be down for maintenance and expected to return online later in the morning.
Normal Operations
The forums are back online with normal operations. If you notice any issues or errors related to the forums, please reach out to help@ucar.edu

How select a special region to run the CLM from the global model in CLM?

jteymoori

Javad Teymoori
Member
Do I have to change all these NetCDFs for all the files in the Solar, Precip, and TPHWL folders, each of which starts from 1901 and goes up to 2014, on a monthly basis, and then run the model with the regridded data just for a month?
 

oleson

Keith Oleson
CSEG and Liaisons
Staff member
I should clarify my previous statement that the grid doesn't have to be in degrees. You can run a 4km grid but you'll still have to specify the grid that corresponds to 4km in degrees latitude/longitude in your mesh or domain file (depending on which version of the model you are using) and your surface dataset.
For your second question, I'm not sure why you want to regrid the 0.5deg atmospheric forcing dataset to 50km. 0.5deg near the equator is roughly 50 km anyway. If you are intending to run a ~50km grid on the land, the datm will interpolate the 0.5deg data to your 50km grid. You could also run a 0.5deg land grid forced by the 0.5deg atmosphere data.
 

jteymoori

Javad Teymoori
Member
Thank you for your very helpful reply.
As I said before, I ran the model by default using Atmospheric Forcing Data. In this stage, I want to run the model with a 50km resolution just for one month. For example, in August 2012, I need to first regrid the resolution from 0.5 degrees to 50 km and then run the model just for that month.
But I don't know how can I do it?
 

jteymoori

Javad Teymoori
Member
As I said I want to firstly change the resolution to 50x50 km2 grid for one month (for example Aug 2012), secondly run the model just for that month.
can I create a new case and run it with new information:

Pervious case:
./create_newcase --case ~/Dec19 --mach cheyenne --res CLM_USRDAT --compset COMPSET=2000_DATM%GSWP3v1_CLM50%FATES_SICE_SOCN_RTM_SGLC_SWAV --run-unsupported --project UCNN0040

New case:
./create_newcase --case ~/Feb13 --mach cheyenne --res 50x50 km2 --compset COMPSET=2012-08_DATM%GSWP3v1_CLM50%FATES_SICE_SOCN_RTM_SGLC_SWAV --run-unsupported --project UCNN0040

is it true?
 

wwieder

Will Wieder
New Member
It's important that you look at documentation provided by CESM. Have you tried to check the CESM-Tutorial resources on github that are searchable?

For example, your can search for resolution to find out more information about the resolutions are supported for CESM. A half degree run is roughly 50x50 km. You can do the same to look for supported compsets. Finally, to define the start date and run length for a simulation you need to make xlm changes to modify settings for your case.
 

jteymoori

Javad Teymoori
Member
Yes, I read that documentations(search for resolution and CESM-Tutorial resources )but I could not completely learn how can I first change the resolution from 0.5x0.5 degree to 50x50 km(I know they are very close to each other but I want to use the 50x50 km).
I used to the below scripts for running the default :
cd /glade/work/jteymoori
mkdir march13
git clone GitHub - ESCOMP/CTSM: Community Terrestrial Systems Model (includes the Community Land Model of CESM)
cd CTSM
./manage_externals/checkout_externals
cd /CTSM/cime/scripts
module load python
./create_newcase --case ~/March13 --mach cheyenne --res CLM_USRDAT --compset COMPSET=2000_DATM%GSWP3v1_CLM50%FATES_SICE_SOCN_RTM_SGLC_SWAV --run-unsupported --project UCNN0040
Cd CTSM/tools/site_and_regional
pip install numpy
pip install xarray
./subset_data region --lat1 24.5 --lat2 49.4 --lon1 235 --lon2 294 --reg united_states --create-surface

ctsm/tools/site_and_regional/subset_data_regional:
module load nco

cp /glade/work/jteymoori/CTSM/tools/site_and_regional/subset_data_regional/surfdata_united_states_hist_16pfts_Irrig_CMIP6_simyr2000_c231214.nc landmask.nc
ncrename -v PFTDATA_MASK,landmask landmask.nc
ncks -A -v PFTDATA_MASK /glade/work/jteymoori/CTSM/tools/site_and_regional/subset_data_regional/surfdata_united_states_hist_16pfts_Irrig_CMIP6_simyr2000_c231214.nc landmask.nc
ncrename -v PFTDATA_MASK,mod_lnd_props landmask.nc
ncks --rgr infer --rgr scrip=scrip.nc landmask.nc foo.nc
/glade/u/apps/ch/opt/esmf-netcdf/8.0.0/intel/19.0.5/bin/bing/Linux.intel.64.mpiuni.default/ESMF_Scrip2Unstruct scrip.nc lnd_mesh.nc 0

cd March13
module load python
./xmlchange NTASKS=-4
./xmlchange NTASKS_PER_INST=144
./xmlchange JOB_WALLCLOCK_TIME=12:00:00
./xmlchange JOB_QUEUE=regular
./xmlchange PIO_TYPENAME=pnetcdf
./xmlchange STOP_OPTION=nyears
./xmlchange STOP_N=1
./xmlchange LND_NX=47
./xmlchange LND_NY=26
./xmlchange ATM_NX=47
./xmlchange ATM_NY=26
./case.setup

vi user_nl_clm

fsurdat = '/glade/work/jteymoori/CTSM/tools/site_and_regional/subset_data_regional/surfdata_united_states_hist_16pfts_Irrig_CMIP6_simyr2000_c231214.nc'
hist_mfilt=12
hist_nhtfrq=0
Esc
:wq

Update lines in env_run.xml:
./xmlchange LND_DOMAIN_MESH='/glade/work/jteymoori/CTSM/tools/site_and_regional/subset_data_regional/lnd_mesh.nc'
./xmlchange ATM_DOMAIN_MESH='/glade/work/jteymoori/CTSM/tools/site_and_regional/subset_data_regional/lnd_mesh.nc'
./xmlchange MASK_MESH='/glade/work/jteymoori/CTSM/tools/site_and_regional/subset_data_regional/lnd_mesh.nc'
./case.build
./case.submit

Now based on the mentioned documentation firstly for changing the resolution I should use the:

./create_newcase --case ~/March13 --mach cheyenne --res CLM_USRDAT --compset COMPSET=2000-08_DATM%GSWP3v1_CLM50%FATES_SICE_SOCN_RTM_SGLC_SWAV --run-unsupported --project UCNN0040

in the $CTSMROOT/bld/namelist_files/namelist_definition_ctsm.xml: ./xmlchange res=50x50 km

and secondly for run just for one month (for example 2012-08) use the:
/xmlchange STOP_OPTION=nmonths

is true?
 

wwieder

Will Wieder
New Member
The basics should be the same as a single point simulation, see these instructions.

./create_newcase --case ~/March13 --mach cheyenne --res CLM_USRDAT --compset SELECT_A_SUPPORTED_COMPSET --run-unsupported --project UCNN0040.

You can' change anyting in $CTSMROOT
Instead, you need to point to your surface dataset in user_nl_clm.

You'll also have to point to your mesh file as in your example, above

Finally dates you want to run over are defined using ./xmlchange command from your case directory
 

jteymoori

Javad Teymoori
Member
Based on @wwieder to run the model with 50 km resolution (not 0.5 degrees) I found I could do these steps:
firstly I should create a new case like the one below:
./create_newcase --case ~/March14 --mach derecho --res CLM_USRDAT --compset COMPSET=2000_DATM%GSWP3v1_CLM50%FATES_SICE_SOCN_RTM_SGLC_SWAV --run-unsupported --project UCNN0040

Secondly by changing the user_nl_clm with ner resolution as below:
vi user_nl_clm
res=50kmx50km

Esc
:wq

And finally, for running the model for just one month (for example 2012-08), I should write as below:

./xmlchange DATM_YR_ALIGN=2012-08
./xmlchange DATM_YR_START=2012-08
./xmlchange DATM_YR_END=2012-8
 

jteymoori

Javad Teymoori
Member
Dr. @slevis , based on the instructions introduced by you in the 1. CLM5.0 User’s Guide — ctsm release-clm5.0 documentation, in part 1.4.2. Adding Resolution Names, there is the various types of resolution that can be used for modeling are given as the below:


<entry id="res" type="char*30" category="default_settings"
group="default_settings"
valid_values=
"512x1024,360x720cru,128x256,64x128,48x96,32x64,8x16,94x192,0.23x0.31,0.9x1.25,1.9x2.5,2.5x3.33,
4x5,10x15,5x5_amazon,1x1_tropicAtl,1x1_camdenNJ,1x1_vacouverCAN,1x1_mexicocityMEX,1x1_asphaltjungleNJ,
1x1_brazil,1x1_urbanc_alpha,1x1_numaIA,1x1_smallvilleIA,0.1x0.1,0.5x0.5,3x3min,5x5min,10x10min,0.33x0.3,
ne4np4,ne16np4,ne30np4,ne60np4,ne120np4,ne240np4,wus12,us20,1km-merge-10min">
Horizontal resolutions
Note: 0.1x0.1, 0.5x0.5, 5x5min, 10x10min, 3x3min, 1km-merge-10min, and 0.33x0.33 are only used for CLM tools
</entry>

I want to run my model with 4km x 4km and the nearest resolution to that is 0.05x0.05 degree. for running this resolution I used the below scripts:

./create_newcase --case ~/March15 --mach derecho --res 0.5x0.5 --compset COMPSET=2000_DATM%GSWP3v1_CLM50%FATES_SICE_SOCN_RTM_SGLC_SWAV --run-unsupported --project UCNN0040

but I faced an error:

Did not find an alias or longname compset match for COMPSET=2000_DATM%GSWP3v1_CLM50%FATES_SICE_SOCN_RTM_SGLC_SWAV
Automatically adding SESP to compset
ERROR: no alias 0.5x0.5 defined

How can I solve this error?
 

jteymoori

Javad Teymoori
Member
It should be noted that I tried both 0.5x0.5 (for 50 km x 50 km) and 0.05x0.05( for 4 km x 4km) and got the same error for both.
 

slevis

Moderator
Dear @jteymoori

Based on the last 5 pages of messages between you and me and @oleson and @wwieder,
I have the following advice:
1) Please try to use the model according to the tutorials and documentation that we provide online.
2) If you have difficulty, please ask for help from more experienced members in your group, including your advisor.

Unfortunately this conversation has not helped you make much progress. We recognize that we probably misunderstand the sources of your confusion, but we have tried many times. We admit that we have failed.

Our instructions have helped numerous users in the past, so you may find that going back and following our suggestions to you or other users in the Forums may actually help. But I cannot guarantee the outcome, given where we stand right now.

Please understand that our decision to stop responding to your messages is not personal, but comes from a need to manage our time at work efficiently.
 

oleson

Keith Oleson
CSEG and Liaisons
Staff member
I think that was the command for cheyenne. For derecho, please try:

/glade/u/apps/derecho/23.09/spack/opt/spack/esmf/8.6.0/cray-mpich/8.1.27/oneapi/2023.2.1/7haa/bin/ESMF_Scrip2Unstruct scrip.nc lnd_mesh.nc 0
 

jteymoori

Javad Teymoori
Member
Dear all

I want to run CTSM in a case for monthly scale (Aug, 2012), I created it and for modifying the xml by using the below changes:

./xmlchange NTASKS=-4
./xmlchange NTASKS_PER_INST=144
./xmlchange JOB_WALLCLOCK_TIME=12:00:00
./xmlchange JOB_QUEUE=regular
./xmlchange PIO_TYPENAME=pnetcdf
./xmlchange STOP_OPTION=nmonths
./xmlchange STOP_N=1
./xmlchange LND_NX=47
./xmlchange LND_NY=26
./xmlchange ATM_NX=47
./xmlchange ATM_NY=26
./xmlchange DATM_YR_ALIGN=2012-08-01
./xmlchange DATM_YR_START=2012-08-01
./xmlchange DATM_YR_END=2012-08-31

./case.setup

but after running ./xmlchange JOB_QUEUE=regular , I faced this error:
ERROR: Unknown Job Queue specified use --force to set

what is means and how can it be solved?
 

slevis

Moderator
These are instructions for cheyenne, but I assume that you are on derecho now. I suggest changing "regular" to "main", and I hope that everything else will work...
 

jteymoori

Javad Teymoori
Member
Dear all
I want to run my model with 0.05x0.05 degree resolution and my compset is COMPSET=2000_DATM%GSWP3v1_CLM50%FATES_SICE_SOCN_RTM_SGLC_SWAV. based on 1.4. Adding New Resolutions :

Firstly I have done Adding New resolution Name in the namelist_definition_ctsm.xml, so the 0.05x0.05_test added to the end of the valid_values for the id="res" entry.

Now for second step, Adding or changing Default Filename, I confused. I think I must use this scripts:
<fsurdat hgrid="0.05x0.05" sim_year="2000" use_crop=".true." > lnd/clm2/surfdata_map/surfdata_0.05x0.05_test.nc </fsurdat>

but I don't know I must do it in the namelist_defaults_ctsm_tools.xml or namelist_defaults_ctsm.xml
which of them is true?
 

jteymoori

Javad Teymoori
Member
Dear all
Hi
I have run the regional CTSM-FATES at the regular 1-degree resolution defined by CLM_USRDAT. Now, I want to run the model with 0.05x0.05 degree resolution.

Based on the
Firstly, I have added a new resolution Name in the namelist_definition_ctsm.xml, so the 0.05x0.05_test was added to the end of the valid_values for the id="res" entry.

For the second step, Adding or changing the Default Filename, in the namelist_defaults_ctsm.xml, I added this script:
<fsurdat hgrid="0.05x0.05_test" sim_year="2000">
lnd/clm2/surfdata_map/release-clm5.0.30/surfdata_0.05x0.05_test_hist_78pfts_CMIP6_simyr2000_c200426.nc</fsurdat>

But when I want to create a new case with the 0.05x0.05 I faded with an error:
ERROR: no alias 0.05x0.05_test defined

Do I need to any other changes for run the model with 0.05x0.05 degree? What is my wrong?
 
Top