You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: documentation/md_running.html
+18-22Lines changed: 18 additions & 22 deletions
Original file line number
Diff line number
Diff line change
@@ -127,6 +127,18 @@
127
127
</div><!--header-->
128
128
<divclass="contents">
129
129
<divclass="textblock"><p><aclass="anchor" id="autotoc_md80"></a> MFC can be run using <code>mfc.sh</code>'s <code>run</code> command. It supports both interactive and batch execution, the latter being designed for multi-socket systems, namely supercomputers, equipped with a scheduler such as PBS, SLURM, and LSF. A full (and updated) list of available arguments can be acquired with <code>./mfc.sh run -h</code>.</p>
130
+
<p>MFC supports running simulations locally (Linux, MacOS, and Windows) as well as several supercomputer clusters, both interactively and through batch submission.</p>
131
+
<blockquoteclass="doxtable">
132
+
<p>‍[!IMPORTANT] Running simulations locally should work out of the box. On supported clusters, you can append <code>-c <computer name></code> on the command line to instruct the MFC toolchain to make use of the template file <code>toolchain/templates/<computer name>.mako</code>. You can browse that directory and contribute your own files. Since systems and their schedulers do not have a standardized syntax to request certain resources, MFC can only provide support for a restricted subset of common or user-contributed configuration options.</p>
133
+
<p>Adding a new template file or modifying an existing one will most likely be required if:</p><ul>
134
+
<li>You are on a cluster that does not have a template yet.</li>
135
+
<li>Your cluster is configured with SLURM but interactive job launches fail when using <code>srun</code>. You might need to invoke <code>mpirun</code> instead.</li>
136
+
<li>Something in the existing default or computer template file is incompatible with your system or does not provide a feature you need.</li>
137
+
</ul>
138
+
<p>If <code>-c <computer name></code> is left unspecified, it defaults to <code>-c default</code>. </p>
139
+
</blockquote>
140
+
<p>Additional flags can be appended to the MPI executable call using the <code>-f</code> (i.e <code>--flags</code>) option.</p>
141
+
<p>Please refer to <code>./mfc.sh run -h</code> for a complete list of arguments and options, along with their defaults.</p>
130
142
<h1><aclass="anchor" id="autotoc_md81"></a>
131
143
Interactive Execution</h1>
132
144
<p>To run all stages of MFC, that is <ahref="https://github.com/MFlowCode/MFC/tree/master/src/pre_process/">pre_process</a>, <ahref="https://github.com/MFlowCode/MFC/tree/master/src/simulation/">simulation</a>, and <ahref="https://github.com/MFlowCode/MFC/tree/master/src/post_process/">post_process</a> on the sample case <ahref="https://github.com/MFlowCode/MFC/tree/master/examples/2D_shockbubble/">2D_shockbubble</a>,</p>
<li>Running <ahref="https://github.com/MFlowCode/MFC/tree/master/src/simulation/">simulation</a> and <ahref="https://github.com/MFlowCode/MFC/tree/master/src/post_process/">post_process</a> using 4 cores:</li>
142
154
</ul>
143
155
<divclass="fragment"><divclass="line">$ ./mfc.sh run examples/2D_shockbubble/case.py -t simulation post_process -n 4</div>
144
-
</div><!-- fragment --><p>On some computer clusters, MFC might select the wrong MPI program to execute your application because it uses a general heuristic for its selection. Notably, <code>srun</code> is known to fail on some SLURM systems when using GPUs or MPI implementations from different vendors, whereas <code>mpirun</code> functions properly. To override and manually specify which MPI program you wish to run your application with, please use the <code>-b <program name></code> option (i.e <code>--binary</code>).</p>
145
-
<p>Additional flags can be appended to the MPI executable call using the <code>-f</code> (i.e <code>--flags</code>) option.</p>
146
-
<p>Please refer to <code>./mfc.sh run -h</code> for a complete list of arguments and options, along with their defaults.</p>
147
-
<h1><aclass="anchor" id="autotoc_md82"></a>
156
+
</div><!-- fragment --><h1><aclass="anchor" id="autotoc_md82"></a>
148
157
Batch Execution</h1>
149
-
<p>The MFC detects which scheduler your system is using and handles the creation and execution of batch scripts. The batch engine is requested with the <code>-e batch</code> option. Whereas the interactive engine can execute all of MFC's codes in succession, the batch engine requires you to only specify one target with the <code>-t</code> option. The number of nodes and GPUs can, respectively be specified with the <code>-N</code> (i.e <code>--nodes</code>) and <code>-g</code> (i.e <code>--gpus-per-node</code>) options.</p>
<p>The MFC detects which scheduler your system is using and handles the creation and execution of batch scripts. The batch engine is requested via the <code>-e batch</code> option. The number of nodes can be specified with the <code>-N</code> (i.e <code>--nodes</code>) option.</p>
159
+
<p>We provide a list of (baked-in) submission batch scripts in the <code>toolchain/templates</code> folder.</p>
<li><code>-a <account name></code> to identify the account to be charged for the job. (i.e <code>--account</code>)</li>
157
167
<li><code>-p <partition name></code> to select the job's partition. (i.e <code>--partition</code>)</li>
158
168
</ul>
159
-
<p>Since some schedulers don't have a standardized syntax to request certain resources, MFC can only provide support for a restricted subset of common configuration options. If MFC fails to execute on your system, or if you wish to adjust how the program runs and resources are requested to be allocated, you are invited to modify the template batch script for your queue system. Upon execution of <code>./mfc.sh run</code>, MFC fills in the template with runtime parameters, to generate the batch file it will submit. These files are located in the <ahref="https://github.com/MFlowCode/MFC/tree/master/toolchain/templates/">templates</a> directory. To request GPUs, modification of the template will be required on most systems.</p>
160
-
<ul>
161
-
<li>Lines that begin with <code>#></code> are ignored and won't figure in the final batch script, not even as a comment.</li>
162
-
<li>Statements of the form <code>${expression}</code> are string-replaced to provide runtime parameters, most notably execution options. You can perform therein any Python operation recognized by the built-in <code>expr()</code> function.</li>
163
-
</ul>
164
169
<p>As an example, one might request GPUs on a SLURM system using the following:</p>
<li>Statements of the form <code>{MFC::expression}</code> tell MFC where to place the common code, across all batch files, that is required for proper execution. They are not intended to be modified by users.</li>
168
-
</ul>
169
170
<p><b>Disclaimer</b>: IBM's JSRUN on LSF-managed computers does not use the traditional node-based approach to allocate resources. Therefore, the MFC constructs equivalent resource-sets in task and GPU count.</p>
<trid="row_0_" class="even"><tdclass="entry"><spanstyle="width:0px;display:inline-block;"> </span><spanid="arr_0_" class="arrow" onclick="dynsection.toggleFolder('0_')">▼</span><spanclass="icona"><spanclass="icon">M</span></span><aclass="el" href="namespacem__data__input.html" target="_self">m_data_input</a></td><tdclass="desc">This module features procedures, which for a specific time-step, read in the raw simulation data for the grid and the conservative variables and fill out their buffer regions </td></tr>
132
132
<trid="row_0_0_" class="odd"><tdclass="entry"><spanstyle="width:32px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="interfacem__data__input_1_1s__read__abstract__data__files.html" target="_self">s_read_abstract_data_files</a></td><tdclass="desc">Subroutine for reading data files </td></tr>
133
-
<trid="row_1_" class="even"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structbounds__info.html" target="_self">bounds_info</a></td><tdclass="desc">Derived type adding beginning (beg) and end bounds info as attributes </td></tr>
134
-
<trid="row_2_" class="odd"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structbub__bounds__info.html" target="_self">bub_bounds_info</a></td><tdclass="desc">Bounds for the bubble dynamic variables </td></tr>
135
-
<trid="row_3_" class="even"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structfield__position.html" target="_self">field_position</a></td><tdclass="desc">Derived type adding the field position (fp) as an attribute </td></tr>
136
-
<trid="row_4_" class="odd"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structic__model__parameters.html" target="_self">ic_model_parameters</a></td><tdclass="desc">Defines parameters for a Model Patch </td></tr>
137
-
<trid="row_5_" class="even"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structic__patch__parameters.html" target="_self">ic_patch_parameters</a></td><tdclass="desc">Derived type adding initial condition (ic) patch parameters as attributes NOTE: The requirements for the specification of the above parameters are strongly dependent on both the choice of the multicomponent flow model as well as the choice of the patch geometry </td></tr>
138
-
<trid="row_6_" class="odd"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structint__bounds__info.html" target="_self">int_bounds_info</a></td><tdclass="desc">Integer bounds for variables </td></tr>
139
-
<trid="row_7_" class="even"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structintegral__parameters.html" target="_self">integral_parameters</a></td><tdclass="desc">Derived type annexing integral regions </td></tr>
<trid="row_10_" class="odd"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structphysical__parameters.html" target="_self">physical_parameters</a></td><tdclass="desc">Derived type annexing the physical parameters (PP) of the fluids. These include the specific heat ratio function and liquid stiffness function </td></tr>
143
-
<trid="row_11_" class="even"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structpres__field.html" target="_self">pres_field</a></td><tdclass="desc">Derived type for bubble variables pb and mv at quadrature nodes (qbmm) </td></tr>
144
-
<trid="row_12_" class="odd"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structprobe__parameters.html" target="_self">probe_parameters</a></td><tdclass="desc">Derived type annexing the flow probe location </td></tr>
145
-
<trid="row_13_" class="even"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structscalar__field.html" target="_self">scalar_field</a></td><tdclass="desc">Derived type annexing a scalar field (SF) </td></tr>
<trid="row_18_" class="odd"><tdclass="entry"><spanstyle="width:16px;display:inline-block;"> </span><spanclass="icona"><spanclass="icon">C</span></span><aclass="el" href="structvector__field.html" target="_self">vector_field</a></td><tdclass="desc">Derived type annexing a vector field (VF) </td></tr>
0 commit comments