Commit 1c9c5de3 authored by Uwe Schulzweida's avatar Uwe Schulzweida
Browse files

cmor: added draft docu.

parent 3d9dbad2
......@@ -555,6 +555,10 @@ Operator catalog:
Magplot grfill Shaded gridfill plot
Magvector vector Vector arrows plot
Maggraph graph Line graph plot
Climate indices
......@@ -142,6 +142,7 @@ Hurr Miscellaneous
Magplot Magics
Magvector Magics
Maggraph Magics
EcaCdd Climate indices
EcaCfd Climate indices
EcaCsu Climate indices
\bibitem[CDI]{CDI} \ \\
{Climate Data Interface},
from the
{Max Planck Institute for Meteorologie}
\bibitem[CDO]{CDO} \ \\
{Climate Data Operators},
from the
{Max Planck Institute for Meteorologie}
\bibitem[CMOR]{CMOR} \ \\
{Climate Model Output Rewriter},
from the
{ Program For Climate Model Diagnosis and Intercomparison (PCMDI)}
\documentclass[DIV16,BCOR1cm,10pt,a4paper,fleqn,twoside]{scrreprt} % for pdf output
%\documentclass[DIV16,BCOR1cm,10pt,a4paper,fleqn]{scrreprt} % for pdf output
%\documentclass[DIV16,BCOR1cm,11pt,a4paper,fleqn]{report} % for pdf output
% To allow automatic selection of the right graphics type ...
% preset \pdfoutput for older latex installation, it is allways definted for
% news ones
% latex is called for dvi output
% pdflatex is called for pdf output
%\newcommand{\CDO}{{\bfseries\sffamily CDO\ }}
\newcommand{\CDO}{{\bfseries\sffamily CDO}}
% To define headers and footers
% Headers and footers personalization using the `fancyhdr' package
\fancyhf{} % Clear all fields
\fancyhead[LO,RE]{\slshape \leftmark}
\fancyhead[LE,RO]{\slshape \rightmark}
\fancyhead{} % get rid of headers
\usepackage{array,colortbl} % color table
\definecolor{pcolor1}{rgb}{0.992, 0.980, 0.875} % rgb: 253/250/223
\definecolor{pcolor2}{rgb}{1.000, 0.925, 0.700} % rgb: 255/236/278
\definecolor{pcolor3}{rgb}{0.968, 0.756, 0.623} % rgb: 247/193/159
%\usepackage{ae} % fuer die "almost european" computer modern fonts
%\usepackage{url} % Standard-Paket fuer WWW-Adressen
%\typearea{10} % Einen sinnvollen Satzspiegel aktivieren
%pdflatex cdo.tex
%pdflatex cdo.tex
%cat > << 'EOF'
%delim_0 "{\\idxdotfill} "
%headings_flag 1
%heading_prefix "{\\centerline {\\Large \\bf "
%heading_suffix "}}"
%makeindex -s cdo.idx
%pdflatex cdo
%thumbpdf cdo
%pdflatex cdo
%\usepackage[a4paper, colorlinks=true, pdfstartview=FitV, bookmarks=true, linkcolor=blue,
% citecolor=blue, urlcolor=blue, latex2html=true]{hyperref}
% pdffitwindow=true,
pdfauthor={Uwe Schulzweida},
pdftitle={CDO Climate Data Operators},
pdfcreator={pdflatex + hyperref},
% pdfpagemode=FullScreen,
\setlength{\parskip}{1.5ex plus0.5ex minus0.5ex}
%\newcommand{\ii}[1]{\textit{#1}} \newcommand{\nn}[1]{#1n}
%\renewcommand{\dotfill}{\leaders\hbox to 5p1{\hss.\hss}\hfill}
\newcommand{\idxdotfill}{\ \dotfill \ }
%\def\idxdotfill{\leaders\hbox to.6em{\hss .\hss}\hskip 0pt plus 1fill}
\renewcommand{\indexname}{Operator index}
{\settowidth{\labelwidth}{#1\ \ }
{\settowidth{\labelwidth}{#1\ \ }
{\Huge{\bf CMOR support in \CDO}}
\large\bf{CMORizing of climate model data \\ October 2016}
\Large{\bf Karl--Hermann Wieners, Uwe Schulzweida}
\Large{\sl Max Planck Institute for Meteorology}
\Large{\bf Mathis Rosenhauer}
\Large{\sl Deutsches Klimarechenzentrum (DKRZ)}
The Climate Data Operators ({\CDO}) software is a collection of operators
for standard processing of climate and forecast model data.
This document describes the additional {\CDO} operator cmor. This
operator is an interface to the CMOR library version 3 from PCMDI.
The CMOR support is available with {\CDO} release 1.8.0 or later.
The CMOR (Climate Model Output Rewriter) library comprises a set of
functions, that can be used to produce CF-compliant NetCDF files that
fulfill the requirements of many of the climate community's standard
model experiments. These experiments are collectively referred to as
MIP's and include, for example, AMIP, CMIP, CFMIP, PMIP, APE, and IPCC
scenario runs. The output resulting from CMOR is "self-describing" and
facilitates analysis of results across models.
Much of the metadata written to the output files is defined in
MIP-specific tables, typically made available from each MIP's web
site. CMOR relies on these tables to provide much of the metadata
that is needed in the MIP context, thereby reducing the programming
effort required of the individual MIP contributors.
The CDO operator cmor reads the data with the internal IO library CDI
and writes the NetCDF result directly with the CMOR library.
\chapter{Building CDO with CMOR}
This section describes how to build and install {\CDO} with CMOR
support on a UNIX system.
CMOR version 3 needs to be installed before building {\CDO}.
CMOR depends on the following external libraries:
netCDF-4.0 , HDF5, UDUNITS-2, zlib and uuid.
Make sure that you use exactly the same libraries for the {\CDO}
installation, otherwise the operator cmor will possibly not working correctly.
First go to the {\CDO} \href{}{\tt download} page
({\tt}) to get the latest distribution,
if you do not have it yet.
Compilation is done by performing the following steps:
\item Unpack the archive, if you haven't done that yet:
gunzip cdo-$VERSION.tar.gz # uncompress the archive
tar xf cdo-$VERSION.tar # unpack it
cd cdo-$VERSION
\item Configure {\CDO} with CMOR support:
The configuration depends on the location of the external libraries. Here is one example:
./configure --with-cmor=<CMOR root directory> --with-netcdf=<NetCDFroot directory> \
--with-uuid --with-udunits2 LIBS=-lossp-uuid \
CPPFLAGS="-I<CMOR root dir>/include/cdTime -I<CMOR root dir>/include/json-c"
For an overview of other configuration options use
./configure --help
\item Compile the program by running make:
The program should compile without problems and the binary ({\tt cdo})
should be available in the {\tt src} directory of the distribution.
After the compilation of the source code do a {\tt make install},
possibly as root if the destination permissions require that.
make install
The binary is installed into the directory {\tt $<$prefix$>$/bin}.
{\tt $<$prefix$>$} defaults to {\tt /usr/local} but can be changed with
the {\tt --prefix} option of the configure script.
\chapter{\label{refman}CMOR operator reference manual}
This section gives a description of all {\CDO} operators to generate plots.
Related operators are grouped to modules.
For easier description all single input files are named {\tt ifile} or {\tt ifile1}, {\tt ifile2}, etc.,
and an arbitrary number of input files are named {\tt ifiles}.
All output files are named {\tt ofile} or {\tt ofile1}, {\tt ofile2}, etc.
......@@ -264,14 +264,14 @@ while (<MOFILE>) {
print TRLIST "Here is a short overview of all operators in this section:\\\\\n";
print TRLIST "\n";
if ( $shortname ne "climat" && $shortname ne "magics" ) {
if ( $shortname ne "climat" && $shortname ne "magics" && $shortname ne "cmor" ) {
print TROVER "\\newpage\n";
print TROVER "\\section{$chap}\n";
print TROVER "\\input{ref_intro_${shortname}}\n";
print TROVER "\\input{ref_list_${shortname}}\n";
print TROVER "\\input{ref_man_${shortname}}\n\n";
if ( $shortname eq "climat" || $shortname eq "magics" ) {
if ( $shortname eq "climat" || $shortname eq "magics" || $shortname eq "cmor" ) {
# print "find eca!";
$refskip = 1;
pdflatex cdo_cmor.tex
pdflatex cdo_cmor.tex
cat > << 'EOF'
delim_0 "{\\idxdotfill} "
headings_flag 1
heading_prefix "{\\centerline {\\Large \\bf "
%heading_prefix "{\\centerline {\\bfseries "
heading_suffix "}}"
makeindex -s cdo_cmor.idx
pdflatex cdo_cmor
#thumbpdf cdo
pdflatex cdo_cmor
......@@ -2,7 +2,7 @@
@Name = CMOR
@Title = CMOR
@Section = Miscellaneous
@Section = CMOR
@Arguments = ifile
@Operators = cmor
......@@ -578,7 +578,7 @@ static modules_t Modules[] =
{ Change, ChangeHelp, ChangeOperators, 1, CDI_REAL, 1, 1 },
{ Change_e5slm, NULL, Change_e5slmOperators, 0, CDI_REAL, 1, 1 },
{ Cloudlayer, NULL, CloudlayerOperators, 1, CDI_REAL, 1, 1 },
{ CMOR, NULL, CMOROperators, 1, CDI_REAL, 1, 0 },
{ CMOR, CMORHelp, CMOROperators, 1, CDI_REAL, 1, 0 },
{ Collgrid, CollgridHelp, CollgridOperators, 1, CDI_REAL, -1, 1 },
{ Command, NULL, CommandOperators, 0, CDI_REAL, 1, 0 },
{ Comp, CompHelp, CompOperators, 1, CDI_REAL, 2, 1 },
......@@ -5130,6 +5130,25 @@ static const char *MaggraphHelp[] = {
static const char *CMORHelp[] = {
" cmor - CMOR",
" cmor,tab[,options] ifile",
" Options is a comma separated list of \"key=value\" pairs with optional parameters.",
" tab STRING Name of the CMOR table as specified from PCMDI",
" var STRING Comma separated list of variables",
" expinfo STRING Experiment specific parameter file",
" modinfo STRING Model specific parameter file",
" userinfo STRING User/institute specific parameter file",
static const char *EcaCddHelp[] = {
" eca_cdd - Consecutive dry days index per time period",
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment