Diag CM5A2

1 minute read

Introduction

This script plots several diagnostics from CM5A2 outputs. Depending on the options enabled:

  • Figures format can be set (png, pdf…)
  • PDF file gathering the generated figures can be created
  • Animated gif can be created for some variables
  • Manual value limits for plots colormap can be activated instead of the automatic scaling for convenient comparison between several simulations
  • In the case where 2 experiments are chosen, there is the ability to compute the difference between them

Preliminary steps

The folder containing the script and all the packages required are located on IRENE here: /ccc/work/cont003/gen2212/gen2212/util_CM5A2/Diag_CM5A2/.

Connect to IRENE and move to the folder location containing the code.

ssh [username]@irene-fr.ccc.cea.fr

cd /ccc/work/cont003/gen2212/gen2212/utils_CM5A2/Diag_CM5A2

At this step you can either choose to run ccc_mprun -s -m work,store -Q test -p rome -T 600 or not before following the rest of the documentation. This will run the code on an interactive computing node (might be faster ?)

Load environment

. load_env.sh
Make sure to use . load_env.sh and not ./load_env.sh so the script is sourced into your current shell and you will be able to use python3 hereafter.

Launch the script

  • Run the python script Diag_CM5A2.py
    python3 Diag_CM5A2.py
    
  • Enter your [ProfileName] as requested:
    • if [ProfileName] is not known: a file [ProfileName]_profile.py will be created here user_input_/[ProfileName]/ and the program will stop. At this point, you will need to edit the [ProfileName]_profile.py file according to your needs and relaunch the program. An example can be found in user_input/EXAMPLE/EXAMPLE_profile.py.
    • if [ProfileName] is known: program will run following the settings of the user_input/[ProfileName]/[ProfileName]_profile.py file.

    Note that the variables in [ProfileName]_profile.py file:

    • sentence_to_use
    • dataDirOutput
    • filePrefix
    • dataDirMask
    • maskFile
    • dataDirBathy
    • bathyFile
    • subBasinFile

    are in list format and can contain as many elements as you want (elements being the different properties of the experiments: file names, paths…).

    In the specific case where you choose 2 experiments, a new prompt will appear letting you choose the ability to compute differences between experiments 1 & 2.

Note: In order to run, this script will need the util/ and Toolz/ folders containing all the necessary functions and templates.

Updated: