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 to make the mode use downloaded CO2 data

Ambition_hhh

Ambition_hhh
New Member
./create_newcase --case HistClm50BgcCrop --res f09_g16 --compset IHistClm50BgcCrop --mach myintel --compiler intel --run-unsupported

I created this case, I want the model to use my own file download of co2 (cmip6 download rcp2.6 data)
/home/hlh/cesm/inputdata/atm/datm7/CO2/fgco2_Oyr_CanESM5_rcp26 - cmip5_r1i1p1f1_gn_2006 - 2100.nc

1. I changed it in the run_run.xml file:
<entry id="DATM_CO2_TSERIES" value="none">
<type>char</type>
<valid_values>none,20tr,20tr.latbnd,rcp2.6,rcp4.5,rcp6.0,rcp8.5</valid_values>
<desc>DATM CO2 time series</desc>
</entry>

2. I changed it in the run_run.xml file:
<entry id="DATM_CLMNCEP_YR_START" value="2006">
<type>integer</type>
<desc>starting year to loop data over</desc>
</entry>
<entry id="DATM_CLMNCEP_YR_END" value="2100">
<type>integer</type>
<desc>ending year to loop data over</desc>
</entry>

3. I changed it in the run_run.xml file:
<entry id="CLM_CO2_TYPE" value="diagnostic">
<type>char</type>
<valid_values>constant,diagnostic,prognostic</valid_values>

4. I added to the user_nl_datm file:
co2_type = 'diagnostic'
fgco2_file = '/home/hlh/cesm/inputdata/atm/datm7/CO2/fgco2_Oyr_CanESM5_rcp26-cmip6_r1i1p1f1_gn_2006-2100.nc'
/

But an error is reported:
hlh@hlh-desktop:~/clm5.0/cime/scripts/my_custom_co2_case$ ./case.build --skip-provenance-check
Building case in directory /home/hlh/clm5.0/cime/scripts/my_custom_co2_case
sharedlib_only is False
model_only is False
Setting resource.RLIMIT_STACK to -1 from (-1, -1)
Generating component namelists as part of build
Creating component namelists
Calling /home/hlh/clm5.0/cime/src/components/data_comps/datm/cime_config/buildnml
ERROR: Variable 'fgco2_file' from file '/home/hlh/clm5.0/cime/scripts/my_custom_co2_case/Buildconf/datmconf/namelist_infile' is not in the namelist definition.


I found that errors occurred when I added contents in the user_nl_datm file and the user_nl_clm file

How do I get the model to use my CO2 data

Thanks for your answer
 

slevis

Moderator
Staff member
For what you are trying to do, I recommend the following troubleshooting steps:
1) Confirm that your version of the model runs without any changes to the files or the code.
2) Confirm that the modified co2 file that you wish to use has the same format as the default one.
3) Now try replacing the default co2 file with yours, and hope that it works correctly.
 
Vote Upvote 0 Downvote

slevis

Moderator
Staff member
...but possibly before all that, the error message says that fgco2_file is not a valid namelist variable. You need to find out what it should be.
 
Vote Upvote 0 Downvote

Ambition_hhh

Ambition_hhh
New Member
你好

您使用的是哪个版本的 CESM?看起来您使用的是相当旧的版本。我建议您更新到较新的版本 - 社区地球系统模型 2 (CESM2) |社区地球系统模型

柯特妮
我的版本是 cesm2.2.0

可能是我刚开始,不知道怎么调试,能帮我解答一下吗?
...但可能在这一切之前,错误消息说 fgco2_file 不是有效的 namelist 变量。你需要找出它应该是什么。
I've tried a lot of names, but I don't understand what a namelist variable is.
 
Vote Upvote 0 Downvote

oleson

Keith Oleson
CSEG and Liaisons
Staff member
Namelist variables are explained in the CESM tutorial:


I think your specific problem is related to the fact that you are using the namelist variable fgco2_file in your user_nl_datm file. That variable doesn't exist. For the historical case you've created, there should be a datm streams file in your CaseDocs directory called:

datm.streams.txt.co2tseries.20tr

Copy that to your case directory and prepend "user_" to the file name, e.g.,

cp CaseDocs/datm.streams.txt.co2tseries.20tr ./user_datm.streams.txt.co2tseries.20tr

and then change the file name as needed in user_datm.streams.txt.co2tseries.20tr.
Then run preview_namelists to see if you are pointing to your file.
 
Vote Upvote 0 Downvote

Ambition_hhh

Ambition_hhh
New Member
Namelist variables are explained in the CESM tutorial:


I think your specific problem is related to the fact that you are using the namelist variable fgco2_file in your user_nl_datm file. That variable doesn't exist. For the historical case you've created, there should be a datm streams file in your CaseDocs directory called:

datm.streams.txt.co2tseries.20tr

Copy that to your case directory and prepend "user_" to the file name, e.g.,

cp CaseDocs/datm.streams.txt.co2tseries.20tr ./user_datm.streams.txt.co2tseries.20tr

and then change the file name as needed in user_datm.streams.txt.co2tseries.20tr.
Then run preview_namelists to see if you are pointing to your file.
Was everything I did before this operation correct? I still report the same mistake
 
Vote Upvote 0 Downvote

Ambition_hhh

Ambition_hhh
New Member
After the create_newcase step, I would go directly to @oleson's instructions:
i'm sorry, I still report the same mistake
 
Vote Upvote 0 Downvote

oleson

Keith Oleson
CSEG and Liaisons
Staff member
Are you still referring to this error:

ERROR: Variable 'fgco2_file' from file '/home/hlh/clm5.0/cime/scripts/my_custom_co2_case/Buildconf/datmconf/namelist_infile' is not in the namelist definition.

Please attach your user_datm.streams.txt.co2tseries.20tr
 
Vote Upvote 0 Downvote

xiaoxiaokuishu

Ru Xu
Member
Are you still referring to this error:

ERROR: Variable 'fgco2_file' from file '/home/hlh/clm5.0/cime/scripts/my_custom_co2_case/Buildconf/datmconf/namelist_infile' is not in the namelist definition.

Please attach your user_datm.streams.txt.co2tseries.20tr
Hi, Oleson,
I have a question of how to set co2 in anomaly forcing method, I use SSP126 (with CLM5).
Follow your previous reply, I thought I should set DATM_CO2_TSERIES as SSP1-2.6,
but when i check the avaliable DATM_CO2_TSERIES values, there is no SSP1-2.6 avaliable...

<entry id="DATM_CO2_TSERIES" value="none">
<type>char</type>
<valid_values>none,20tr,20tr.latbnd,rcp2.6,rcp4.5,rcp6.0,rcp8.5</valid_values>

there is only datm.streams.txt.presaero.clim_2000 under CaseDocs folder...
Besides, my user_datm_in is

anomaly_forcing = 'Anomaly.Forcing.Precip','Anomaly.Forcing.Temperature','Anomaly.Forcing.Pressure','Anomaly.Forcing.Humidity','Anomaly.Forcing.Uwind','Anomaly.Forcing.Vwind','Anomaly.Forcing.Shortwave','Anomaly.Forcing.Longwave'
streams = "datm.streams.txt.CLMGSWP3v1.Solar 2015 2001 2013",
"datm.streams.txt.CLMGSWP3v1.Precip 2015 2001 2013",
"datm.streams.txt.CLMGSWP3v1.TPQW 2015 2001 2013",
"datm.streams.txt.presaero.SSP1-2.6 2015 2015 2101",
"datm.streams.txt.topo.observed 1 1 1",
"datm.streams.txt.co2tseries.SSP1-2.6 2015 2015 2500",
"datm.streams.txt.Anomaly.Forcing.Precip 2015 2015 2100",
"datm.streams.txt.Anomaly.Forcing.Temperature 2015 2015 2100",
"datm.streams.txt.Anomaly.Forcing.Pressure 2015 2015 2100",
"datm.streams.txt.Anomaly.Forcing.Humidity 2015 2015 2100",
"datm.streams.txt.Anomaly.Forcing.Uwind 2015 2015 2100",
"datm.streams.txt.Anomaly.Forcing.Vwind 2015 2015 2100",
"datm.streams.txt.Anomaly.Forcing.Shortwave 2015 2015 2100",
"datm.streams.txt.Anomaly.Forcing.Longwave 2015 2015 2100"

Best
Ru
 
Vote Upvote 0 Downvote

oleson

Keith Oleson
CSEG and Liaisons
Staff member
The supported release version of cesm/clm (release-cesm2.1.5) has SSP126, i.e.,

<valid_values>none,20tr,20tr.latbnd,omip,SSP1-1.9,SSP1-2.6,SSP2-4.5,SSP3-7.0,SSP4-3.4,SSP4-6.0,SSP5-3.4,SSP5-8.5,SSP1-1.9.latbnd,SSP1-2.6.latbnd,SSP2-4.5.latbnd,SSP3-7.0.latbnd,SSP4-3.4.latbnd,SSP4-6.0.latbnd,SSP5-3.4.latbnd,SSP5-8.5.latbnd</valid_values>
 
Vote Upvote 0 Downvote

xiaoxiaokuishu

Ru Xu
Member
The supported release version of cesm/clm (release-cesm2.1.5) has SSP126, i.e.,

<valid_values>none,20tr,20tr.latbnd,omip,SSP1-1.9,SSP1-2.6,SSP2-4.5,SSP3-7.0,SSP4-3.4,SSP4-6.0,SSP5-3.4,SSP5-8.5,SSP1-1.9.latbnd,SSP1-2.6.latbnd,SSP2-4.5.latbnd,SSP3-7.0.latbnd,SSP4-3.4.latbnd,SSP4-6.0.latbnd,SSP5-3.4.latbnd,SSP5-8.5.latbnd</valid_values>
Hi, Oleson,


My version is ctsm1.0.dev040, but I would like to use the SSP126, do you have any suggestions of how to do it.

If not, do you have how to make future ssp simulation use ctsm1.0.dev040. I know how to it well with CLM5, but not
ctsm1.0.dev040...

Best
Ru
 
Vote Upvote 0 Downvote

oleson

Keith Oleson
CSEG and Liaisons
Staff member
Looking at the ChangeLog, it looks like the ISSP compsets were brought into the development version of the model in ctsm1.0.dev093. So it seems as if you'd have to update to at least that version. But ctsm1.0.dev093 is still very old (2020). If you want to use the development version of the model, I'd recommend you update to the latest. Otherwise, I'd use the supported release version.
 
Vote Upvote 0 Downvote

xiaoxiaokuishu

Ru Xu
Member
Looking at the ChangeLog, it looks like the ISSP compsets were brought into the development version of the model in ctsm1.0.dev093. So it seems as if you'd have to update to at least that version. But ctsm1.0.dev093 is still very old (2020). If you want to use the development version of the model, I'd recommend you update to the latest. Otherwise, I'd use the supported release version.
Hi,Oleson.

I update my model version to ctsm1.0.dev093, why i use this old version is because we modified the source code based on
ctsm1.0.dev040, so use the verison close to it is much more easier for use to debug..

When I change it to ctsm1.0.dev093, I can see the SSP! Thanks for your support!
Additional question, is the SSP simulation also works for regional case?, I am working on region case now, not global

Best
Ru
 
Vote Upvote 0 Downvote
Top