Skip to content

Commit

Permalink
Update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Oct 9, 2024
1 parent 9f24d08 commit c81eaa3
Show file tree
Hide file tree
Showing 288 changed files with 1,035 additions and 1,041 deletions.
14 changes: 4 additions & 10 deletions latest/_modules/compass/ocean/tests/global_ocean/mesh.html
Original file line number Diff line number Diff line change
Expand Up @@ -258,20 +258,14 @@ <h1>Source code for compass.ocean.tests.global_ocean.mesh</h1><div class="highli
<span class="k">if</span> <span class="n">config</span> <span class="ow">is</span> <span class="kc">None</span><span class="p">:</span>
<span class="n">config</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">config</span>
<span class="n">config</span><span class="o">.</span><span class="n">add_from_package</span><span class="p">(</span><span class="s1">&#39;compass.mesh&#39;</span><span class="p">,</span> <span class="s1">&#39;mesh.cfg&#39;</span><span class="p">,</span> <span class="n">exception</span><span class="o">=</span><span class="kc">True</span><span class="p">)</span>
<span class="c1"># a description of the bathymetry</span>
<span class="k">if</span> <span class="s1">&#39;remap_topography&#39;</span> <span class="ow">in</span> <span class="bp">self</span><span class="o">.</span><span class="n">steps</span><span class="p">:</span>
<span class="n">config</span><span class="o">.</span><span class="n">add_from_package</span><span class="p">(</span><span class="s1">&#39;compass.ocean.mesh&#39;</span><span class="p">,</span>
<span class="s1">&#39;remap_topography.cfg&#39;</span><span class="p">,</span> <span class="n">exception</span><span class="o">=</span><span class="kc">True</span><span class="p">)</span>

<span class="k">if</span> <span class="ow">not</span> <span class="bp">self</span><span class="o">.</span><span class="n">high_res_topography</span><span class="p">:</span>
<span class="n">filename</span> <span class="o">=</span> <span class="s1">&#39;BedMachineAntarctica_v2_and_GEBCO_2022_0.05_degree_20220729.nc&#39;</span> <span class="c1"># noqa: E501</span>
<span class="n">description</span> <span class="o">=</span> <span class="s1">&#39;Bathymetry is from GEBCO 2022, combined with &#39;</span> \
<span class="s1">&#39;BedMachine Antarctica v2 around Antarctica.&#39;</span>
<span class="n">config</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s1">&#39;remap_topography&#39;</span><span class="p">,</span> <span class="s1">&#39;topo_filename&#39;</span><span class="p">,</span> <span class="n">filename</span><span class="p">)</span>
<span class="n">config</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s1">&#39;remap_topography&#39;</span><span class="p">,</span> <span class="s1">&#39;bathy_frac_var&#39;</span><span class="p">,</span> <span class="s1">&#39;ocean_mask&#39;</span><span class="p">)</span>
<span class="n">config</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s1">&#39;remap_topography&#39;</span><span class="p">,</span> <span class="s1">&#39;description&#39;</span><span class="p">,</span> <span class="n">description</span><span class="p">)</span>
<span class="n">config</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s1">&#39;remap_topography&#39;</span><span class="p">,</span> <span class="s1">&#39;ntasks&#39;</span><span class="p">,</span> <span class="s1">&#39;64&#39;</span><span class="p">)</span>
<span class="n">config</span><span class="o">.</span><span class="n">set</span><span class="p">(</span><span class="s1">&#39;remap_topography&#39;</span><span class="p">,</span> <span class="s1">&#39;min_tasks&#39;</span><span class="p">,</span> <span class="s1">&#39;4&#39;</span><span class="p">)</span>
<span class="k">if</span> <span class="ow">not</span> <span class="bp">self</span><span class="o">.</span><span class="n">high_res_topography</span><span class="p">:</span>
<span class="n">config</span><span class="o">.</span><span class="n">add_from_package</span><span class="p">(</span><span class="s1">&#39;compass.ocean.mesh&#39;</span><span class="p">,</span>
<span class="s1">&#39;low_res_topography.cfg&#39;</span><span class="p">,</span>
<span class="n">exception</span><span class="o">=</span><span class="kc">True</span><span class="p">)</span>

<span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">mesh_name</span><span class="o">.</span><span class="n">startswith</span><span class="p">(</span><span class="s1">&#39;Kuroshio&#39;</span><span class="p">):</span>
<span class="c1"># add the config options for all kuroshio meshes</span>
Expand Down
4 changes: 2 additions & 2 deletions latest/developers_guide/framework.html
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@
config file and other config files by file name, but these are largely intended
for use by the framework rather than individual test cases.</p>
<p>Other methods for the <code class="docutils literal notranslate"><span class="pre">MpasConfigParser</span></code> are similar to those for
<a class="reference external" href="https://docs.python.org/3/library/configparser.html#configparser.ConfigParser" title="(in Python v3.12)"><code class="xref py py-class docutils literal notranslate"><span class="pre">configparser.ConfigParser</span></code></a>. In addition to <code class="docutils literal notranslate"><span class="pre">get()</span></code>,
<a class="reference external" href="https://docs.python.org/3/library/configparser.html#configparser.ConfigParser" title="(in Python v3.13)"><code class="xref py py-class docutils literal notranslate"><span class="pre">configparser.ConfigParser</span></code></a>. In addition to <code class="docutils literal notranslate"><span class="pre">get()</span></code>,
<code class="docutils literal notranslate"><span class="pre">getinteger()</span></code>, <code class="docutils literal notranslate"><span class="pre">getfloat()</span></code> and <code class="docutils literal notranslate"><span class="pre">getboolean()</span></code> methods, this class
implements <a class="reference external" href="http://mpas-dev.github.io/MPAS-Tools/stable/generated/mpas_tools.config.MpasConfigParser.getlist.html#mpas_tools.config.MpasConfigParser.getlist" title="(in mpas_tools vstable)"><code class="xref py py-meth docutils literal notranslate"><span class="pre">mpas_tools.config.MpasConfigParser.getlist()</span></code></a>, which
can be used to parse a config value separated by spaces and/or commas into
Expand All @@ -304,7 +304,7 @@
<section id="comments-in-config-files">
<h3>Comments in config files<a class="headerlink" href="#comments-in-config-files" title="Link to this heading"></a></h3>
<p>One of the main advantages of <a class="reference external" href="http://mpas-dev.github.io/MPAS-Tools/stable/generated/mpas_tools.config.MpasConfigParser.html#mpas_tools.config.MpasConfigParser" title="(in mpas_tools vstable)"><code class="xref py py-class docutils literal notranslate"><span class="pre">mpas_tools.config.MpasConfigParser</span></code></a>
over <a class="reference external" href="https://docs.python.org/3/library/configparser.html#configparser.ConfigParser" title="(in Python v3.12)"><code class="xref py py-class docutils literal notranslate"><span class="pre">configparser.ConfigParser</span></code></a> is that it keeps track of comments
over <a class="reference external" href="https://docs.python.org/3/library/configparser.html#configparser.ConfigParser" title="(in Python v3.13)"><code class="xref py py-class docutils literal notranslate"><span class="pre">configparser.ConfigParser</span></code></a> is that it keeps track of comments
that are associated with config sections and options.</p>
<p>See <a class="reference external" href="http://mpas-dev.github.io/MPAS-Tools/stable/config.html#config_comments">comments in config files</a>
in MPAS-Tools for more details.</p>
Expand Down
8 changes: 4 additions & 4 deletions latest/developers_guide/generated/compass.MpasCore.html
Original file line number Diff line number Diff line change
Expand Up @@ -146,9 +146,9 @@ <h1>compass.MpasCore<a class="headerlink" href="#compass-mpascore" title="Link t
<dl class="field-list simple">
<dt class="field-odd">Variables<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>name</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a>) – the name of the MPAS core</p></li>
<li><p><strong>test_groups</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.12)"><em>dict</em></a>) – A dictionary of test groups for the MPAS core with their names as keys</p></li>
<li><p><strong>cached_files</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.12)"><em>dict</em></a>) – A dictionary that maps from output file names in test cases to cached
<li><p><strong>name</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a>) – the name of the MPAS core</p></li>
<li><p><strong>test_groups</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.13)"><em>dict</em></a>) – A dictionary of test groups for the MPAS core with their names as keys</p></li>
<li><p><strong>cached_files</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.13)"><em>dict</em></a>) – A dictionary that maps from output file names in test cases to cached
files in the <code class="docutils literal notranslate"><span class="pre">compass_cache</span></code> database for the MPAS core. These
file mappings are read in from <code class="docutils literal notranslate"><span class="pre">cached_files.json</span></code> in the MPAS core.</p></li>
</ul>
Expand All @@ -160,7 +160,7 @@ <h1>compass.MpasCore<a class="headerlink" href="#compass-mpascore" title="Link t
<dd><p>Create a new container for the test groups for a given MPAS core</p>
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><p><strong>name</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a>) – the name of the MPAS core</p>
<dd class="field-odd"><p><strong>name</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a>) – the name of the MPAS core</p>
</dd>
</dl>
</dd></dl>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -161,15 +161,15 @@ <h1>compass.Step.add_input_file<a class="headerlink" href="#compass-step-add-inp
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>filename</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a><em>, </em><em>optional</em>) – The relative path of the input file within the step’s work
<li><p><strong>filename</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a><em>, </em><em>optional</em>) – The relative path of the input file within the step’s work
directory. The default is the file name (without the path) of
<code class="docutils literal notranslate"><span class="pre">target</span></code>.</p></li>
<li><p><strong>target</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a><em>, </em><em>optional</em>) – A file that will be the target of a symlink to <code class="docutils literal notranslate"><span class="pre">filename</span></code>. If
<li><p><strong>target</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a><em>, </em><em>optional</em>) – A file that will be the target of a symlink to <code class="docutils literal notranslate"><span class="pre">filename</span></code>. If
<code class="docutils literal notranslate"><span class="pre">database</span></code> is not specified, this should be an absolute path or a
relative path from the step’s work directory. If <code class="docutils literal notranslate"><span class="pre">database</span></code> is
specified, this is a relative path within the database and the name
of the remote file to download.</p></li>
<li><p><strong>database</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a><em>, </em><em>optional</em>) – The name of a database for caching local files. This will be a
<li><p><strong>database</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a><em>, </em><em>optional</em>) – The name of a database for caching local files. This will be a
subdirectory of the local cache directory for this core. If
<code class="docutils literal notranslate"><span class="pre">url</span></code> is not provided, the URL for downloading the file will be
determined by combining the base URL of the data server, the
Expand All @@ -178,15 +178,15 @@ <h1>compass.Step.add_input_file<a class="headerlink" href="#compass-step-add-inp
default this is the MPAS core name for this step. The suffix
<code class="docutils literal notranslate"><span class="pre">_database_root</span></code> is appended to this string to determine the
config option where the database root resides on the local machine.</p></li>
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a><em>, </em><em>optional</em>) – The URL (including file name) for downloading the file. This
<li><p><strong>url</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a><em>, </em><em>optional</em>) – The URL (including file name) for downloading the file. This
option should be set if the file is not in a database on the data
server. The <code class="docutils literal notranslate"><span class="pre">filename</span></code>, <code class="docutils literal notranslate"><span class="pre">target</span></code> and <code class="docutils literal notranslate"><span class="pre">database</span></code> are not
added to URL even if they are provided.</p></li>
<li><p><strong>work_dir_target</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a><em>, </em><em>optional</em>) – Same as <code class="docutils literal notranslate"><span class="pre">target</span></code> but with a path relative to the base work
<li><p><strong>work_dir_target</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a><em>, </em><em>optional</em>) – Same as <code class="docutils literal notranslate"><span class="pre">target</span></code> but with a path relative to the base work
directory. This is useful if it is not easy to determine the
relative path between the step’s work directory and the target.</p></li>
<li><p><strong>package</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a><em> or </em><em>package</em><em>, </em><em>optional</em>) – A package within <code class="docutils literal notranslate"><span class="pre">compass</span></code> from which the file should be linked</p></li>
<li><p><strong>copy</strong> (<a class="reference external" href="https://docs.python.org/3/library/functions.html#bool" title="(in Python v3.12)"><em>bool</em></a><em>, </em><em>optional</em>) – Whether to make a copy of the file, rather than a symlink</p></li>
<li><p><strong>package</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a><em> or </em><em>package</em><em>, </em><em>optional</em>) – A package within <code class="docutils literal notranslate"><span class="pre">compass</span></code> from which the file should be linked</p></li>
<li><p><strong>copy</strong> (<a class="reference external" href="https://docs.python.org/3/library/functions.html#bool" title="(in Python v3.13)"><em>bool</em></a><em>, </em><em>optional</em>) – Whether to make a copy of the file, rather than a symlink</p></li>
</ul>
</dd>
</dl>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -161,8 +161,8 @@ <h1>compass.Step.add_namelist_file<a class="headerlink" href="#compass-step-add-
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>package</strong> (<em>Package</em>) – The package name or module object that contains <code class="docutils literal notranslate"><span class="pre">namelist</span></code></p></li>
<li><p><strong>namelist</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a>) – The name of the namelist replacements file to read from</p></li>
<li><p><strong>out_name</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a><em>, </em><em>optional</em>) – The name of the namelist file to write out, <code class="docutils literal notranslate"><span class="pre">namelist.&lt;core&gt;</span></code> by
<li><p><strong>namelist</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a>) – The name of the namelist replacements file to read from</p></li>
<li><p><strong>out_name</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a><em>, </em><em>optional</em>) – The name of the namelist file to write out, <code class="docutils literal notranslate"><span class="pre">namelist.&lt;core&gt;</span></code> by
default</p></li>
<li><p><strong>mode</strong> (<em>{'init'</em><em>, </em><em>'forward'}</em><em>, </em><em>optional</em>) – The mode that the model will run in</p></li>
</ul>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -159,9 +159,9 @@ <h1>compass.Step.add_namelist_options<a class="headerlink" href="#compass-step-a
<dl class="field-list simple">
<dt class="field-odd">Parameters<span class="colon">:</span></dt>
<dd class="field-odd"><ul class="simple">
<li><p><strong>options</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.12)"><em>dict</em></a>) – A dictionary of options and value to replace namelist options with
<li><p><strong>options</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#dict" title="(in Python v3.13)"><em>dict</em></a>) – A dictionary of options and value to replace namelist options with
new values</p></li>
<li><p><strong>out_name</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.12)"><em>str</em></a><em>, </em><em>optional</em>) – The name of the namelist file to write out, <code class="docutils literal notranslate"><span class="pre">namelist.&lt;core&gt;</span></code> by
<li><p><strong>out_name</strong> (<a class="reference external" href="https://docs.python.org/3/library/stdtypes.html#str" title="(in Python v3.13)"><em>str</em></a><em>, </em><em>optional</em>) – The name of the namelist file to write out, <code class="docutils literal notranslate"><span class="pre">namelist.&lt;core&gt;</span></code> by
default</p></li>
<li><p><strong>mode</strong> (<em>{'init'</em><em>, </em><em>'forward'}</em><em>, </em><em>optional</em>) – The mode that the model will run in</p></li>
</ul>
Expand Down
Loading

0 comments on commit c81eaa3

Please sign in to comment.