CESM

De Wikicima
(Diferencias entre revisiones)
Saltar a: navegación, buscar
(Machine)
 
(No se muestran 4 ediciones intermedias realizadas por un usuario)
Línea 1: Línea 1:
   
 
= Model description =
 
= Model description =
 
'''*** IMPORTANTE: PAGINA EN CONSTRUCCION***''
 
   
 
The Community Earth System Model ([http://www.cesm.ucar.edu/models/cesm2/ CESM]) is a fully-coupled, community, global climate model that provides state-of-the-art computer simulations of the Earth's past, present, and future climate states. The CESM project is supported primarily by the National Science Foundation (NSF). Administration of the CESM is maintained by the Climate and Global Dynamics Laboratory (CGD) at the National Center for Atmospheric Research (NCAR).
 
The Community Earth System Model ([http://www.cesm.ucar.edu/models/cesm2/ CESM]) is a fully-coupled, community, global climate model that provides state-of-the-art computer simulations of the Earth's past, present, and future climate states. The CESM project is supported primarily by the National Science Foundation (NSF). Administration of the CESM is maintained by the Climate and Global Dynamics Laboratory (CGD) at the National Center for Atmospheric Research (NCAR).
Línea 8: Línea 6:
 
For the latest CESM release and CESM2 components see [http://www.cesm.ucar.edu/models/cesm2/whatsnew.html CESM2 documentation].
 
For the latest CESM release and CESM2 components see [http://www.cesm.ucar.edu/models/cesm2/whatsnew.html CESM2 documentation].
   
= Downloading CESM2 =
+
= Installation =
+
Follow to this [[CESMInstall WIKI CESM - hydra]] to see how the installation in CIMA's hydra was done.
Following [https://escomp.github.io/cesm/release-cesm2.2/downloading_cesm.html CESM2 Quick Start Guide] and [https://github.com/ESCOMP/cesm#committing-your-change-to-externals-cfg CESM2 github instructions].
 
 
== Clone the repository ==
 
<pre>
 
git clone -b release-cesm2.2.2 git@github.com:ESCOMP/CESM.git my_cesm_sandbox
 
</pre>
 
<!-- git clone https://github.com/escomp/cesm.git my_cesm_sandbox -->
 
This will create a directory my_cesm_sandbox/ in your current working directory.
 
 
We got the following
 
<pre style="shell">
 
$ cd my_cesm_sandbox/
 
$ ls
 
ChangeLog CODE_OF_CONDUCT.md Externals.cfg manage_externals
 
ChangeLog_template describe_version Externals_cime.cfg README.rst
 
cime_config doc LICENSE.txt
 
</pre>
 
 
Verifying that installation was fine:
 
<pre style="shell">
 
$ ./manage_externals/checkout_externals
 
$ ls
 
ChangeLog CODE_OF_CONDUCT.md Externals.cfg README.rst
 
ChangeLog_template components Externals_cime.cfg
 
cime describe_version LICENSE.txt
 
cime_config doc manage_externals
 
</pre>
 
 
<!--
 
== Checkout the CESM tag ==
 
 
* Go into the newly created CESM repository
 
<pre>
 
mkdir -p /home/lluis.fita/CESM/intel
 
cd my_cesm_sandbox
 
</pre>
 
* Determine what version of CESM you want. To see what versions of CESM2 are available,
 
<pre>
 
git tag --list 'release-cesm2*'
 
</pre>
 
* Checkout a specific CESM release tag type, for example CESM2.1.0:
 
<pre>
 
git checkout release-cesm2.1.0
 
</pre>
 
'''NOTE:''' the latest release might not be available yet for public use and this might cause issues in the next step, forcing you to need to start over. See the note in the next step for more information.
 
 
== Run checkout_externals ==
 
 
To checkout all the individual model components, run the script ''./manage_externals/checkout_externals''.
 
* This script requires Python 2.7.x (installed in HYDRA ''/share/anaconda2/bin/'') to run, so we need to change the Python interpreter in the header of ''checkout_externals''. To do so:
 
<pre>
 
sed -i -e 's!/usr/bin/env python!/share/anaconda2/bin/python!' ./manage_externals/checkout_externals
 
</pre>
 
* Now run the script from ''/path/to/my_cesm_sandbox'':
 
<pre>
 
./manage_externals/checkout_externals
 
</pre>
 
'''NOTE:''' If you experience problems such as ''checkout_externals'' hanging it is likely that is because you asked the checkout of the latest version which is not yet available for public usage, as suggested in this [https://bb.cgd.ucar.edu/password-download CESM forum discussion]:
 
<pre>
 
[gabriela.raggio@hydra my_cesm_sandbox]$ ./manage_externals/checkout_externals
 
Processing externals description file : Externals.cfg
 
Processing externals description file : Externals_CLM.cfg
 
Checking status of externals: clm, fates, ptclm, mosart, ww3, cime,
 
cice, pop, cism, rtm, cam,
 
Checking out externals: clm, mosart, ww3, Password for 'gabriela.raggio':
 
 
 
Command 'svn checkout --quiet
 
https://svn-ccsm-models.cgd.ucar.edu/ww3/trunk_tags/ww3_190402
 
/home/gabriela.raggio/my_cesm_sandbox/components/ww3'
 
from directory /home/gabriela.raggio/my_cesm_sandbox
 
has taken 300 seconds. It may be hanging.
 
 
The command will continue to run, but you may want to abort
 
manage_externals with ^C and investigate. A possible cause of hangs is
 
when svn or git require authentication to access a private
 
repository. On some systems, svn and git requests for authentication
 
information will not be displayed to the user. In this case, the program
 
will appear to hang. Ensure you can run svn and git manually and access
 
all repositories without entering your authentication information.
 
</pre>
 
In my case, I was trying to checkout release-cesm2.1.1. I solved this by starting over. I deleted the previous git clone and made a new git clone (named ''CESM210''). In the new git clone I made a checkout of a previous release (release-cesm2.1.0). After doing so, I had no issues running the ''checkout_externals'' as explained here.
 
* To confirm a successful download of all components:
 
<pre>
 
./manage_externals/checkout_externals -S
 
</pre>
 
This should show a clean status for all externals, with no characters in the first two columns of output, as in this example
 
<pre>
 
[gabriela.raggio@hydra CESM210]$ ./manage_externals/checkout_externals -S
 
Processing externals description file : Externals.cfg
 
Processing externals description file : Externals_CLM.cfg
 
Processing externals description file : Externals_POP.cfg
 
Processing externals description file : Externals_CISM.cfg
 
Checking status of externals: clm, fates, ptclm, mosart, ww3, cime, cice, pop, cvmix, marbl, cism, source_cism, rtm, cam,
 
./cime
 
./components/cam
 
./components/cice
 
./components/cism
 
./components/cism/source_cism
 
./components/clm
 
./components/clm/src/fates
 
./components/clm/tools/PTCLM
 
./components/mosart
 
./components/pop
 
./components/pop/externals/CVMix
 
./components/pop/externals/MARBL
 
./components/rtm
 
./components/ww3
 
</pre>
 
 
If this is the case, at this point you have a working version of CESM.
 
-->
 
 
= Defining the compilation / installation =
 
 
== Machine ==
 
We need to create the configuration for ''hydra''. For that purpose we are going to use the exampled configuration for <CODE>"centos7-linux"</CODE> from file <PRE>cime/config/cesm/machines/config_machines.xml</PRE>. This is its content_
 
<PRE>
 
<machine MACH="centos7-linux">
 
<DESC>
 
Example port to centos7 linux system with gcc, netcdf, pnetcdf and mpich
 
using modules from http://www.admin-magazine.com/HPC/Articles/Environment-Modules
 
</DESC>
 
<NODENAME_REGEX>regex.expression.matching.your.machine</NODENAME_REGEX>
 
<OS>LINUX</OS>
 
<PROXY> https://howto.get.out </PROXY>
 
<COMPILERS>gnu</COMPILERS>
 
<MPILIBS>mpich</MPILIBS>
 
<PROJECT>none</PROJECT>
 
<SAVE_TIMING_DIR> </SAVE_TIMING_DIR>
 
<CIME_OUTPUT_ROOT>$ENV{HOME}/cesm/scratch</CIME_OUTPUT_ROOT>
 
<DIN_LOC_ROOT>$ENV{HOME}/cesm/inputdata</DIN_LOC_ROOT>
 
<DIN_LOC_ROOT_CLMFORC>$ENV{HOME}/cesm/inputdata/lmwg</DIN_LOC_ROOT_CLMFORC>
 
<DOUT_S_ROOT>$ENV{HOME}/cesm/archive/$CASE</DOUT_S_ROOT>
 
<BASELINE_ROOT>$ENV{HOME}/cesm/cesm_baselines</BASELINE_ROOT>
 
<CCSM_CPRNC>$ENV{HOME}/cesm/tools/cime/tools/cprnc/cprnc</CCSM_CPRNC>
 
<GMAKE>make</GMAKE>
 
<GMAKE_J>8</GMAKE_J>
 
<BATCH_SYSTEM>none</BATCH_SYSTEM>
 
<SUPPORTED_BY>me@my.address</SUPPORTED_BY>
 
<MAX_TASKS_PER_NODE>8</MAX_TASKS_PER_NODE>
 
<MAX_MPITASKS_PER_NODE>8</MAX_MPITASKS_PER_NODE>
 
<PROJECT_REQUIRED>FALSE</PROJECT_REQUIRED>
 
<mpirun mpilib="default">
 
<executable>mpiexec</executable>
 
<arguments>
 
<arg name="ntasks"> -np {{ total_tasks }} </arg>
 
</arguments>
 
</mpirun>
 
<module_system type="module" allow_error="true">
 
<init_path lang="perl">/usr/share/Modules/init/perl.pm</init_path>
 
<init_path lang="python">/usr/share/Modules/init/python.py</init_path>
 
<init_path lang="csh">/usr/share/Modules/init/csh</init_path>
 
<init_path lang="sh">/usr/share/Modules/init/sh</init_path>
 
<cmd_path lang="perl">/usr/bin/modulecmd perl</cmd_path>
 
<cmd_path lang="python">/usr/bin/modulecmd python</cmd_path>
 
<cmd_path lang="sh">module</cmd_path>
 
<cmd_path lang="csh">module</cmd_path>
 
<modules>
 
<command name="purge"/>
 
</modules>
 
<modules compiler="gnu">
 
<command name="load">compiler/gnu/8.2.0</command>
 
<command name="load">mpi/3.3/gcc-8.2.0</command>
 
<command name="load">tool/netcdf/4.6.1/gcc-8.1.0</command>
 
<command name="load">tool/parallel-netcdf/1.12.1/mpich</command>
 
</modules>
 
</module_system>
 
<environment_variables>
 
<env name="OMP_STACKSIZE">256M</env>
 
</environment_variables>
 
<resource_limits>
 
<resource name="RLIMIT_STACK">-1</resource>
 
</resource_limits>
 
</machine>
 
</PRE>
 
 
== Work-flow ==
 
configuration of the work-flow is done via the file <PRE>config_batch.xml</PRE>
 
 
 
http://esmci.github.io/cime/versions/master/html/users_guide/machine.html
 
 
= Porting and validating CIME on a new platform =
 
 
http://esmci.github.io/cime/versions/master/html/users_guide/porting-cime.html
 
 
 
= Downloading the Input data =
 
 
Input datasets are needed to run the model. CESM input data are available through a separate Subversion input data repository.
 
   
* Change ''check_input_data'' header so it runs with Python 2.7.x version:
+
= Use =
<pre>
+
Follow to this [[CESMuse WIKI CESM - hydra]] to see how to use CESM in CIMA's hydra.
sed -i -e 's!/usr/bin/env python!/share/anaconda2/bin/python!' ./cime/scripts/Tools/check_input_data
 
</pre>
 

Última revisión de 11:26 13 mayo 2024

[editar] Model description

The Community Earth System Model (CESM) is a fully-coupled, community, global climate model that provides state-of-the-art computer simulations of the Earth's past, present, and future climate states. The CESM project is supported primarily by the National Science Foundation (NSF). Administration of the CESM is maintained by the Climate and Global Dynamics Laboratory (CGD) at the National Center for Atmospheric Research (NCAR).

For the latest CESM release and CESM2 components see CESM2 documentation.

[editar] Installation

Follow to this CESMInstall WIKI CESM - hydra to see how the installation in CIMA's hydra was done.

[editar] Use

Follow to this CESMuse WIKI CESM - hydra to see how to use CESM in CIMA's hydra.

Herramientas personales