source: flex_extract.git/Documentation/html/Documentation/Input/run.html @ 6931f61

ctbtodev
Last change on this file since 6931f61 was 6931f61, checked in by anphi <anne.philipp@…>, 4 years ago

Update Onlinedocumentation after review of language editing

  • Property mode set to 100644
File size: 36.0 KB
Line 
1
2
3<!DOCTYPE html>
4<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
5<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
6<head>
7  <meta charset="utf-8">
8 
9  <meta name="viewport" content="width=device-width, initial-scale=1.0">
10 
11  <title>The executable script - run.sh &mdash; flex_extract 7.1.2 documentation</title>
12 
13
14 
15 
16 
17 
18
19 
20  <script type="text/javascript" src="../../_static/js/modernizr.min.js"></script>
21 
22   
23      <script type="text/javascript" id="documentation_options" data-url_root="../../" src="../../_static/documentation_options.js"></script>
24        <script src="../../_static/jquery.js"></script>
25        <script src="../../_static/underscore.js"></script>
26        <script src="../../_static/doctools.js"></script>
27        <script src="../../_static/language_data.js"></script>
28        <script async="async" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/latest.js?config=TeX-AMS-MML_HTMLorMML"></script>
29   
30    <script type="text/javascript" src="../../_static/js/theme.js"></script>
31
32   
33
34 
35  <link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" />
36  <link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
37  <link rel="stylesheet" href="../../_static/css/custom.css" type="text/css" />
38  <link rel="stylesheet" href="../../_static/css/theme_overrides.css" type="text/css" />
39    <link rel="index" title="Index" href="../../genindex.html" />
40    <link rel="search" title="Search" href="../../search.html" />
41    <link rel="next" title="The job script job.ksh" href="jobscript.html" />
42    <link rel="prev" title="The Fortran makefile for calc_etadot" href="fortran_makefile.html" /> 
43</head>
44
45<body class="wy-body-for-nav">
46
47   
48  <div class="wy-grid-for-nav">
49   
50    <nav data-toggle="wy-nav-shift" class="wy-nav-side">
51      <div class="wy-side-scroll">
52        <div class="wy-side-nav-search" >
53         
54
55         
56            <a href="../../index.html" class="icon icon-home"> flex_extract
57         
58
59         
60          </a>
61
62         
63           
64           
65              <div class="version">
66                7.1.2
67              </div>
68           
69         
70
71         
72<div role="search">
73  <form id="rtd-search-form" class="wy-form" action="../../search.html" method="get">
74    <input type="text" name="q" placeholder="Search docs" />
75    <input type="hidden" name="check_keywords" value="yes" />
76    <input type="hidden" name="area" value="default" />
77  </form>
78</div>
79
80         
81        </div>
82
83        <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
84         
85           
86           
87             
88           
89           
90              <p class="caption"><span class="caption-text">Table of Contents:</span></p>
91<ul class="current">
92<li class="toctree-l1"><a class="reference internal" href="../../ecmwf_data.html">ECMWF Data</a></li>
93<li class="toctree-l1"><a class="reference internal" href="../../installation.html">Installation</a></li>
94<li class="toctree-l1"><a class="reference internal" href="../../quick_start.html">Usage</a></li>
95<li class="toctree-l1 current"><a class="reference internal" href="../../documentation.html">Code-Level Documentation</a><ul class="current">
96<li class="toctree-l2"><a class="reference internal" href="../overview.html">Overview</a></li>
97<li class="toctree-l2 current"><a class="reference internal" href="../input.html">Control &amp; input data</a><ul class="current">
98<li class="toctree-l3"><a class="reference internal" href="setup.html">The installation script - <code class="docutils literal notranslate"><span class="pre">setup.sh</span></code></a></li>
99<li class="toctree-l3"><a class="reference internal" href="compilejob.html">The compilation job script <code class="docutils literal notranslate"><span class="pre">compilejob.ksh</span></code></a></li>
100<li class="toctree-l3"><a class="reference internal" href="fortran_makefile.html">The Fortran makefile for <code class="docutils literal notranslate"><span class="pre">calc_etadot</span></code></a></li>
101<li class="toctree-l3 current"><a class="current reference internal" href="#">The executable script - <code class="docutils literal notranslate"><span class="pre">run.sh</span></code></a><ul>
102<li class="toctree-l4"><a class="reference internal" href="#submission-parameters">Submission parameters</a></li>
103<li class="toctree-l4"><a class="reference internal" href="#content-of-run-sh">Content of <code class="docutils literal notranslate"><span class="pre">run.sh</span></code></a></li>
104<li class="toctree-l4"><a class="reference internal" href="#usage-of-submit-py-optional">Usage of <code class="docutils literal notranslate"><span class="pre">submit.py</span></code> (optional)</a></li>
105</ul>
106</li>
107<li class="toctree-l3"><a class="reference internal" href="jobscript.html">The job script <code class="docutils literal notranslate"><span class="pre">job.ksh</span></code></a></li>
108<li class="toctree-l3"><a class="reference internal" href="control.html">The CONTROL file</a></li>
109<li class="toctree-l3"><a class="reference internal" href="control_params.html">The CONTROL parameters</a></li>
110<li class="toctree-l3"><a class="reference internal" href="examples.html">CONTROL file examples</a></li>
111<li class="toctree-l3"><a class="reference internal" href="changes.html">CONTROL file changes</a></li>
112<li class="toctree-l3"><a class="reference internal" href="ecmwf_env.html">ECMWF user credential file <code class="docutils literal notranslate"><span class="pre">ECMWF_ENV</span></code></a></li>
113<li class="toctree-l3"><a class="reference internal" href="templates.html">Templates</a></li>
114</ul>
115</li>
116<li class="toctree-l2"><a class="reference internal" href="../output.html">Output data</a></li>
117<li class="toctree-l2"><a class="reference internal" href="../disagg.html">Disaggregation of flux data</a></li>
118<li class="toctree-l2"><a class="reference internal" href="../vertco.html">Vertical wind</a></li>
119<li class="toctree-l2"><a class="reference internal" href="../api.html">Auto-generated documentation</a></li>
120</ul>
121</li>
122<li class="toctree-l1"><a class="reference internal" href="../../evaluation.html">Evaluation</a></li>
123<li class="toctree-l1"><a class="reference internal" href="../../dev_guide.html">Developer Guide</a></li>
124<li class="toctree-l1"><a class="reference internal" href="../../changelog.html">Changelog</a></li>
125<li class="toctree-l1"><a class="reference internal" href="../../support.html">Support</a></li>
126<li class="toctree-l1"><a class="reference internal" href="../../Support/faq.html">FAQ - Frequently asked questions</a></li>
127<li class="toctree-l1"><a class="reference internal" href="../../authors.html">Developer Team</a></li>
128</ul>
129
130           
131         
132        </div>
133      </div>
134    </nav>
135
136    <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
137
138     
139      <nav class="wy-nav-top" aria-label="top navigation">
140       
141          <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
142          <a href="../../index.html">flex_extract</a>
143       
144      </nav>
145
146
147      <div class="wy-nav-content">
148       
149        <div class="rst-content">
150       
151         
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167<div role="navigation" aria-label="breadcrumbs navigation">
168
169  <ul class="wy-breadcrumbs">
170   
171      <li><a href="../../index.html">Docs</a> &raquo;</li>
172       
173          <li><a href="../../documentation.html">Code-Level Documentation</a> &raquo;</li>
174       
175          <li><a href="../input.html">Control &amp; input data</a> &raquo;</li>
176       
177      <li>The executable script - <code class="docutils literal notranslate"><span class="pre">run.sh</span></code></li>
178   
179   
180      <li class="wy-breadcrumbs-aside">
181       
182           
183            <a href="../../_sources/Documentation/Input/run.rst.txt" rel="nofollow"> View page source</a>
184         
185       
186      </li>
187   
188  </ul>
189
190 
191  <hr/>
192</div>
193          <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
194           <div itemprop="articleBody">
195           
196  <div class="section" id="the-executable-script-run-sh">
197<h1>The executable script - <code class="docutils literal notranslate"><span class="pre">run.sh</span></code><a class="headerlink" href="#the-executable-script-run-sh" title="Permalink to this headline"></a></h1>
198<p>The execution of <code class="docutils literal notranslate"><span class="pre">flex_extract</span></code> is done by the <code class="docutils literal notranslate"><span class="pre">run.sh</span></code> shell script, which is a wrapper script for the top-level Python script <code class="docutils literal notranslate"><span class="pre">submit.py</span></code>.
199The Python script constitutes the entry point to ECMWF data retrievals with <code class="docutils literal notranslate"><span class="pre">flex_extract</span></code> and controls the program flow.</p>
200<p><code class="docutils literal notranslate"><span class="pre">submit.py</span></code> has two (or three) sources for input parameters with information about program flow and ECMWF data selection, the so-called <code class="docutils literal notranslate"><span class="pre">CONTROL</span></code> file,
201the command line parameters, and the so-called <code class="docutils literal notranslate"><span class="pre">ECMWF_ENV</span></code> file. Command line parameters will override parameters specified in the <code class="docutils literal notranslate"><span class="pre">CONTROL</span></code> file.</p>
202<p>Based on this input information, <code class="docutils literal notranslate"><span class="pre">flex_extract</span></code> applies one of the application modes to either retrieve the ECMWF data via a web API on a local maschine, or submit a job script to an ECMWF server and retrieve the data there, and at the end sends the files to the local system.</p>
203<div class="section" id="submission-parameters">
204<h2>Submission parameters<a class="headerlink" href="#submission-parameters" title="Permalink to this headline"></a></h2>
205<table class="docutils align-default" id="id1">
206<caption><span class="caption-text">Parameters for submission</span><a class="headerlink" href="#id1" title="Permalink to this table"></a></caption>
207<colgroup>
208<col style="width: 13%" />
209<col style="width: 13%" />
210<col style="width: 8%" />
211<col style="width: 8%" />
212<col style="width: 26%" />
213<col style="width: 32%" />
214</colgroup>
215<thead>
216<tr class="row-odd"><th class="head"><p>PARAMETER</p></th>
217<th class="head"><p>Format</p></th>
218<th class="head"><p>Possible values</p></th>
219<th class="head"><p>Default</p></th>
220<th class="head"><p>Description</p></th>
221<th class="head"><p>Specifics / Conditions</p></th>
222</tr>
223</thead>
224<tbody>
225<tr class="row-even"><td><p>START_DATE</p></td>
226<td><p>String (YYYYMMDD)</p></td>
227<td><p>depends on dataset</p></td>
228<td><p>None</p></td>
229<td><p>The first day of the retrieval period.</p></td>
230<td><p>If END_DATE is set, START_DATE must be earlier or equal than END_DATE.</p></td>
231</tr>
232<tr class="row-odd"><td><p>END_DATE</p></td>
233<td><p>String (YYYYMMDD)</p></td>
234<td><p>depends on dataset</p></td>
235<td><p>None</p></td>
236<td><p>The last day of the retrieval period. For a one day retrieval it has to be the same date as START_DATE. If not set, it is automatically equal to START_DATE. </p></td>
237<td><p>Doesn’t have to be set. If set, it has to be greater or equal than START_DATE.</p></td>
238</tr>
239<tr class="row-even"><td><p>DATE_CHUNK</p></td>
240<td><p>Integer</p></td>
241<td><p>depends on resolution</p></td>
242<td><p>3</p></td>
243<td><p>Maximum number of days retrieved within one MARS request. </p></td>
244<td><p>This number is limited due to maximum allowed memory and time limit for one MARS request. Be careful in changing this number.  It can be  larger for reanalysis data but may be too large for very high resolution retrievals.</p></td>
245</tr>
246<tr class="row-odd"><td><p>JOB_CHUNK</p></td>
247<td><p>Integer</p></td>
248<td><p>depends on resolution</p></td>
249<td><p>None</p></td>
250<td><p># of days to be retrieved within a single job</p></td>
251<td><p>Can be selected to start the submit script once and let it automatically divide the time period in smaller job chunks. Might be very useful for example if one would like to retrieve one month with 0.1° space resolution and 1h time resolution. Then only 1 day per job is possible.</p></td>
252</tr>
253<tr class="row-even"><td><p>CONTROLFILE</p></td>
254<td><p>String</p></td>
255<td><p>any CONTROL file</p></td>
256<td><p>CONTROL_EA5</p></td>
257<td><p>The file with all CONTROL parameters.</p></td>
258<td><p></p></td>
259</tr>
260<tr class="row-odd"><td><p>BASETIME</p></td>
261<td><p>Integer</p></td>
262<td><p>0; 12</p></td>
263<td><p>None</p></td>
264<td><p>This parameter is intended for half-day retrievals. Only half a day will be retrieved starting from BASETIME going back 12 hours. E.g. 20180510 with a BASETIME = 00 would lead to a data retrieval of 20180509 12h until 20180510 00h.</p></td>
265<td><p>Can be set to 00 or 12 only.</p></td>
266</tr>
267<tr class="row-even"><td><p>STEP</p></td>
268<td><p>blank seperated list of Integers (ii ii … ii) or as String (start/to/end)</p></td>
269<td><p>00 - max available STEP in data set</p></td>
270<td><p>None</p></td>
271<td><p>This is the forecast time step in hours for each corresponding field type (TYPE). Counting of the steps starts from the forecast times.  E.g. In Era-Interim, for forecasts at 3, 6, 9 UTC the STEPS 3,6 and 9 are used and the forecast TIME 00 UTC. </p></td>
272<td><p>Has to have the same amount of values as in TYPE and TIME! For analysis (AN) fields the STEP has to be 00 always! It is more easily set in the CONTROL file. For pure forecast modes it might be set here as e.g. 0/to/36</p></td>
273</tr>
274<tr class="row-odd"><td><p>LEVELIST</p></td>
275<td><p>String (start/to/end)</p></td>
276<td><p>1/to/137; depends on dataset</p></td>
277<td><p>None</p></td>
278<td><p>List of vertical levels for MARS request. It can be a subset of levels but it has to include the maximum level (end).</p></td>
279<td><p>If full list of levels is needed and parameter LEVEL is set, the LEVELIST parameter is not needed. “end” has to be the maximum number of possible levels and has to be the same as in LEVEL, if specified.</p></td>
280</tr>
281<tr class="row-even"><td><p>AREA</p></td>
282<td><p>Double (f/f/f/f)</p></td>
283<td><p>any float within lat and lon boundaries</p></td>
284<td><p>None</p></td>
285<td><p>Area defined as north/west/south/east</p></td>
286<td><p></p></td>
287</tr>
288<tr class="row-odd"><td><p>DEBUG</p></td>
289<td><p>Integer</p></td>
290<td><p>0;1</p></td>
291<td><p>0</p></td>
292<td><p>Debug mode - leave temporary files intact</p></td>
293<td><p>Usually only the final FLEXPART inputfiles are saved.</p></td>
294</tr>
295<tr class="row-even"><td><p>OPER</p></td>
296<td><p>Integer</p></td>
297<td><p>0;1</p></td>
298<td><p>0</p></td>
299<td><p>Operational mode - prepares dates with            environment variables</p></td>
300<td><p></p></td>
301</tr>
302<tr class="row-odd"><td><p>REQUEST</p></td>
303<td><p>Integer</p></td>
304<td><p>0;1;2</p></td>
305<td><p>0</p></td>
306<td><p>List all mars requests with its specifc values in file mars_requests.dat
3070 – no file
3081 – only mars_requests.csv
3092 – file and extraction</p></td>
310<td><p>Very useful for documentation or debugging reasons.</p></td>
311</tr>
312<tr class="row-even"><td><p>PUBLIC</p></td>
313<td><p>Integer</p></td>
314<td><p>0;1</p></td>
315<td><p>0</p></td>
316<td><p>Public mode - retrieves the public datasets</p></td>
317<td><p>IMPORTANT: This is necessary to select for each PUBLIC user!</p></td>
318</tr>
319<tr class="row-odd"><td><p>RRINT</p></td>
320<td><p>Integer</p></td>
321<td><p>0;1</p></td>
322<td><p>0</p></td>
323<td><p>Selection of old or new precipitation interpolation ;
324                        0 - old method;
325                        1 - new method                                                         (additional subgrid points)</p></td>
326<td><p>IMPORTANT: If this new method is used, each single GRIB file will contain 3 fields for the large scale and 3 fields for the convective precipitation. They can be distinguished by the “stepRange” keyword in the GribMessages. StepRange = 0 : original time step; stepRange = 1 : first subgrid point; stepRange = 2 : second subgrid point </p></td>
327</tr>
328<tr class="row-even"><td><p>INPUTDIR</p></td>
329<td><p>String</p></td>
330<td><p>any path</p></td>
331<td><p>None</p></td>
332<td><p>Path to the temporary directory for the retrieval grib files and other processing files.</p></td>
333<td><p>The temporary directory will be created if it does not already exist.</p></td>
334</tr>
335<tr class="row-odd"><td><p>OUTPUTDIR</p></td>
336<td><p>String</p></td>
337<td><p>any path</p></td>
338<td><p>None</p></td>
339<td><p>Path to the final directory where the final FLEXPART ready input files are stored.</p></td>
340<td><p>The final output directory will be created if it does not already exist.</p></td>
341</tr>
342<tr class="row-even"><td><p>PPID</p></td>
343<td><p>Integer</p></td>
344<td><p></p></td>
345<td><p>None</p></td>
346<td><p>This is the specify parent process id of a single flex_extract run to identify the files. It is the second number in the GRIB files.</p></td>
347<td><p>This is usually only necessary if the GRIB data were retrieved and a rerun of prepare_flexpart has to be done. Then ppid is used to select the files. </p></td>
348</tr>
349<tr class="row-odd"><td><p>JOB_TEMPLATE</p></td>
350<td><p>String</p></td>
351<td><p>jobscript.template</p></td>
352<td><p>jobscript.template</p></td>
353<td><p>The job template file which are adapted to be submitted to the batch system on ECMWF server.</p></td>
354<td><p></p></td>
355</tr>
356<tr class="row-even"><td><p>QUEUE</p></td>
357<td><p>String</p></td>
358<td><p>ecgate, cca, ccb</p></td>
359<td><p>None</p></td>
360<td><p>The ECMWF server name for submission of the job script to the batch system.</p></td>
361<td><p></p></td>
362</tr>
363</tbody>
364</table>
365</div>
366<div class="section" id="content-of-run-sh">
367<h2>Content of <code class="docutils literal notranslate"><span class="pre">run.sh</span></code><a class="headerlink" href="#content-of-run-sh" title="Permalink to this headline"></a></h2>
368<div class="literal-block-wrapper docutils container" id="id2">
369<div class="code-block-caption"><span class="caption-text">run.sh</span><a class="headerlink" href="#id2" title="Permalink to this code"></a></div>
370<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span><span class="ch">#!/bin/bash</span>
371<span class="c1">#</span>
372<span class="c1"># @Author: Anne Philipp</span>
373<span class="c1">#</span>
374<span class="c1"># @Date: October, 4 2018</span>
375<span class="c1">#</span>
376<span class="c1"># @Description: </span>
377<span class="c1">#    This script defines the available command-line parameters</span>
378<span class="c1">#    for running flex_extract and combines them for the execution  </span>
379<span class="c1">#    of the Python program. It also does some checks to </span>
380<span class="c1">#    guarantee necessary parameters were set and consistent.</span>
381<span class="c1">#</span>
382<span class="c1"># @Licence:</span>
383<span class="c1">#    (C) Copyright 2014-2019.</span>
384<span class="c1">#</span>
385<span class="c1">#    SPDX-License-Identifier: CC-BY-4.0</span>
386<span class="c1">#</span>
387<span class="c1">#    This work is licensed under the Creative Commons Attribution 4.0</span>
388<span class="c1">#    International License. To view a copy of this license, visit</span>
389<span class="c1">#    http://creativecommons.org/licenses/by/4.0/ or send a letter to</span>
390<span class="c1">#    Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.</span>
391<span class="c1">#</span>
392<span class="c1"># -----------------------------------------------------------------</span>
393<span class="c1"># AVAILABLE COMMANDLINE ARGUMENTS TO SET</span>
394<span class="c1"># </span>
395<span class="c1"># THE USER HAS TO SPECIFY THESE PARAMETERS:</span>
396
397<span class="nv">QUEUE</span><span class="o">=</span><span class="s1">&#39;ecgate&#39;</span>
398<span class="nv">START_DATE</span><span class="o">=</span>None
399<span class="nv">END_DATE</span><span class="o">=</span>None
400<span class="nv">DATE_CHUNK</span><span class="o">=</span>None
401<span class="nv">JOB_CHUNK</span><span class="o">=</span><span class="m">3</span>
402<span class="nv">BASETIME</span><span class="o">=</span>None
403<span class="nv">STEP</span><span class="o">=</span>None
404<span class="nv">LEVELIST</span><span class="o">=</span>None
405<span class="nv">AREA</span><span class="o">=</span>None
406<span class="nv">INPUTDIR</span><span class="o">=</span>None
407<span class="nv">OUTPUTDIR</span><span class="o">=</span>None
408<span class="nv">PP_ID</span><span class="o">=</span>None
409<span class="nv">JOB_TEMPLATE</span><span class="o">=</span><span class="s1">&#39;job.temp&#39;</span> 
410<span class="nv">CONTROLFILE</span><span class="o">=</span><span class="s1">&#39;CONTROL_EA5&#39;</span> 
411<span class="nv">DEBUG</span><span class="o">=</span><span class="m">0</span>
412<span class="nv">REQUEST</span><span class="o">=</span><span class="m">2</span>
413<span class="nv">PUBLIC</span><span class="o">=</span><span class="m">0</span>
414
415<span class="c1"># -----------------------------------------------------------------</span>
416<span class="c1">#</span>
417<span class="c1"># AFTER THIS LINE THE USER DOES NOT HAVE TO CHANGE ANYTHING !!!</span>
418<span class="c1">#</span>
419<span class="c1"># -----------------------------------------------------------------</span>
420
421<span class="c1"># PATH TO SUBMISSION SCRIPT</span>
422<span class="nv">pyscript</span><span class="o">=</span>../Source/Python/submit.py
423
424<span class="c1"># INITIALIZE EMPTY PARAMETERLIST</span>
425<span class="nv">parameterlist</span><span class="o">=</span><span class="s2">&quot;&quot;</span>
426
427<span class="c1"># CHECK FOR MORE PARAMETER </span>
428<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$START_DATE</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
429  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --start_date=</span><span class="nv">$START_DATE</span><span class="s2">&quot;</span>
430<span class="k">fi</span>
431<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$END_DATE</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
432  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --end_date=</span><span class="nv">$END_DATE</span><span class="s2">&quot;</span>
433<span class="k">fi</span>
434<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$DATE_CHUNK</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
435  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --date_chunk=</span><span class="nv">$DATE_CHUNK</span><span class="s2">&quot;</span>
436<span class="k">fi</span>
437<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$JOB_CHUNK</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
438  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --job_chunk=</span><span class="nv">$JOB_CHUNK</span><span class="s2">&quot;</span>
439<span class="k">fi</span>
440<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$BASETIME</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
441  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --basetime=</span><span class="nv">$BASETIME</span><span class="s2">&quot;</span>
442<span class="k">fi</span>
443<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$STEP</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
444  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --step=</span><span class="nv">$STEP</span><span class="s2">&quot;</span>
445<span class="k">fi</span>
446<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$LEVELIST</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
447  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --levelist=</span><span class="nv">$LEVELIST</span><span class="s2">&quot;</span>
448<span class="k">fi</span>
449<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$AREA</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
450  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --area=</span><span class="nv">$AREA</span><span class="s2">&quot;</span>
451<span class="k">fi</span>
452<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$INPUTDIR</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
453  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --inputdir=</span><span class="nv">$INPUTDIR</span><span class="s2">&quot;</span>
454<span class="k">fi</span>
455<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$OUTPUTDIR</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
456  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --outputdir=</span><span class="nv">$OUTPUTDIR</span><span class="s2">&quot;</span>
457<span class="k">fi</span>
458<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$PP_ID</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
459  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --ppid=</span><span class="nv">$PP_ID</span><span class="s2">&quot;</span>
460<span class="k">fi</span>
461<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$JOB_TEMPLATE</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
462  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --job_template=</span><span class="nv">$JOB_TEMPLATE</span><span class="s2">&quot;</span>
463<span class="k">fi</span>
464<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$QUEUE</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
465  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --queue=</span><span class="nv">$QUEUE</span><span class="s2">&quot;</span>
466<span class="k">fi</span>
467<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$CONTROLFILE</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
468  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --controlfile=</span><span class="nv">$CONTROLFILE</span><span class="s2">&quot;</span>
469<span class="k">fi</span>
470<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$DEBUG</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
471  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --debug=</span><span class="nv">$DEBUG</span><span class="s2">&quot;</span>
472<span class="k">fi</span>
473<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$REQUEST</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
474  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --request=</span><span class="nv">$REQUEST</span><span class="s2">&quot;</span>
475<span class="k">fi</span>
476<span class="k">if</span> <span class="o">[</span> -n <span class="s2">&quot;</span><span class="nv">$PUBLIC</span><span class="s2">&quot;</span> <span class="o">]</span><span class="p">;</span> <span class="k">then</span>
477  <span class="nv">parameterlist</span><span class="o">+=</span><span class="s2">&quot; --public=</span><span class="nv">$PUBLIC</span><span class="s2">&quot;</span>
478<span class="k">fi</span>
479
480<span class="c1"># -----------------------------------------------------------------</span>
481<span class="c1"># CALL SCRIPT WITH DETERMINED COMMANDLINE ARGUMENTS</span>
482
483<span class="nv">$pyscript</span> <span class="nv">$parameterlist</span>
484</pre></div>
485</div>
486</div>
487</div>
488<div class="section" id="usage-of-submit-py-optional">
489<h2>Usage of <code class="docutils literal notranslate"><span class="pre">submit.py</span></code> (optional)<a class="headerlink" href="#usage-of-submit-py-optional" title="Permalink to this headline"></a></h2>
490<p>It is also possible to start <code class="docutils literal notranslate"><span class="pre">flex_extract</span></code> directly from command line by using the <code class="docutils literal notranslate"><span class="pre">submit.py</span></code> script instead of the wrapper shell script <code class="docutils literal notranslate"><span class="pre">run.sh</span></code>.  This top-level script is located in
491<code class="docutils literal notranslate"><span class="pre">flex_extract_vX.X/Source/Python</span></code> and is executable. With the <code class="docutils literal notranslate"><span class="pre">--help</span></code> parameter
492we see again all possible command line parameters.</p>
493<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>submit.py --help
494
495usage: submit.py <span class="o">[</span>-h<span class="o">]</span> <span class="o">[</span>--start_date START_DATE<span class="o">]</span> <span class="o">[</span>--end_date END_DATE<span class="o">]</span>
496              <span class="o">[</span>--date_chunk DATE_CHUNK<span class="o">]</span> <span class="o">[</span>--job_chunk JOB_CHUNK<span class="o">]</span>
497              <span class="o">[</span>--controlfile CONTROLFILE<span class="o">]</span> <span class="o">[</span>--basetime BASETIME<span class="o">]</span>
498              <span class="o">[</span>--step STEP<span class="o">]</span> <span class="o">[</span>--levelist LEVELIST<span class="o">]</span> <span class="o">[</span>--area AREA<span class="o">]</span>
499              <span class="o">[</span>--debug DEBUG<span class="o">]</span> <span class="o">[</span>--oper OPER<span class="o">]</span> <span class="o">[</span>--request REQUEST<span class="o">]</span>
500              <span class="o">[</span>--public PUBLIC<span class="o">]</span> <span class="o">[</span>--rrint RRINT<span class="o">]</span> <span class="o">[</span>--inputdir INPUTDIR<span class="o">]</span>
501              <span class="o">[</span>--outputdir OUTPUTDIR<span class="o">]</span> <span class="o">[</span>--ppid PPID<span class="o">]</span>
502              <span class="o">[</span>--job_template JOB_TEMPLATE<span class="o">]</span> <span class="o">[</span>--queue QUEUE<span class="o">]</span>
503
504 Retrieve FLEXPART input from ECMWF MARS archive
505
506 optional arguments:
507   -h, --help            show this <span class="nb">help</span> message and <span class="nb">exit</span>
508   --start_date START_DATE
509                         start date YYYYMMDD <span class="o">(</span>default: None<span class="o">)</span>
510   --end_date END_DATE   end_date YYYYMMDD <span class="o">(</span>default: None<span class="o">)</span>
511   --date_chunk DATE_CHUNK
512                         <span class="c1"># of days to be retrieved at once (default: None)</span>
513   --job_chunk JOB_CHUNK
514                         <span class="c1"># of days to be retrieved within a single job</span>
515                         <span class="o">(</span>default: None<span class="o">)</span>
516   --controlfile CONTROLFILE
517                         The file with all CONTROL parameters. <span class="o">(</span>default:
518                         CONTROL_EA5<span class="o">)</span>
519   --basetime BASETIME   base such as <span class="m">0</span> or <span class="m">12</span> <span class="o">(</span><span class="k">for</span> half day retrievals<span class="o">)</span>
520                         <span class="o">(</span>default: None<span class="o">)</span>
521   --step STEP           Forecast steps such as <span class="m">00</span>/to/48 <span class="o">(</span>default: None<span class="o">)</span>
522   --levelist LEVELIST   Vertical levels to be retrieved, e.g. <span class="m">30</span>/to/60
523                         <span class="o">(</span>default: None<span class="o">)</span>
524   --area AREA           area defined as north/west/south/east <span class="o">(</span>default: None<span class="o">)</span>
525   --debug DEBUG         debug mode - leave temporary files intact <span class="o">(</span>default:
526                         None<span class="o">)</span>
527   --oper OPER           operational mode - prepares dates with environment
528                         variables <span class="o">(</span>default: None<span class="o">)</span>
529   --request REQUEST     list all mars requests in file mars_requests.dat
530                         <span class="o">(</span>default: None<span class="o">)</span>
531   --public PUBLIC       public mode - retrieves the public datasets <span class="o">(</span>default:
532                         None<span class="o">)</span>
533   --rrint RRINT         Selection of old or new precipitation interpolation: <span class="m">0</span>
534                         - old method <span class="m">1</span> - new method <span class="o">(</span>additional subgrid
535                         points<span class="o">)</span> <span class="o">(</span>default: None<span class="o">)</span>
536   --inputdir INPUTDIR   Path to the temporary directory <span class="k">for</span> the retrieval grib
537                         files and other processing files. <span class="o">(</span>default: None<span class="o">)</span>
538   --outputdir OUTPUTDIR
539                         Path to the final directory where the final FLEXPART
540                         ready input files are stored. <span class="o">(</span>default: None<span class="o">)</span>
541   --ppid PPID           This is the specify parent process id of a single
542                         flex_extract run to identify the files. It is the
543                         second number in the GRIB files. <span class="o">(</span>default: None<span class="o">)</span>
544   --job_template JOB_TEMPLATE
545                         The job template file which are adapted to be
546                         submitted to the batch system on ECMWF server.
547                         <span class="o">(</span>default: job.temp<span class="o">)</span>
548   --queue QUEUE         The ECMWF server name <span class="k">for</span> submission of the job script
549                         to the batch system <span class="o">(</span>e.g. ecgate <span class="p">|</span> cca <span class="p">|</span> ccb<span class="o">)</span>
550                         <span class="o">(</span>default: None<span class="o">)</span>
551</pre></div>
552</div>
553<div class="toctree-wrapper compound">
554</div>
555</div>
556</div>
557
558
559           </div>
560           
561          </div>
562          <footer>
563 
564    <div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
565     
566        <a href="jobscript.html" class="btn btn-neutral float-right" title="The job script job.ksh" accesskey="n" rel="next">Next <span class="fa fa-arrow-circle-right"></span></a>
567     
568     
569        <a href="fortran_makefile.html" class="btn btn-neutral float-left" title="The Fortran makefile for calc_etadot" accesskey="p" rel="prev"><span class="fa fa-arrow-circle-left"></span> Previous</a>
570     
571    </div>
572 
573
574  <hr/>
575
576  <div role="contentinfo">
577    <p>
578        &copy; Copyright 2020, Anne Philipp, Leopold Haimberger and Petra Seibert
579
580    </p>
581  </div>
582  Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>.
583
584</footer>
585
586        </div>
587      </div>
588
589    </section>
590
591  </div>
592 
593
594
595  <script type="text/javascript">
596      jQuery(function () {
597          SphinxRtdTheme.Navigation.enable(true);
598      });
599  </script>
600
601 
602 
603   
604   
605
606</body>
607</html>
Note: See TracBrowser for help on using the repository browser.
hosted by ZAMG