- Timestamp:
- Aug 7, 2012 4:03:47 PM (12 years ago)
- Location:
- palm/trunk/TUTORIAL/SOURCE
- Files:
-
- 95 added
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
palm/trunk/TUTORIAL/SOURCE/debugging.tex
r945 r973 1 1 % $Id$ 2 2 \input{header_tmp.tex} 3 %\input{../header_ lectures.tex}3 %\input{../header_LECTURE.tex} 4 4 5 5 \usepackage[utf8]{inputenc} … … 117 117 \item<4->{The default {\tt .mrun.config.imuk\_hlrn} file contains an additional block with debug options. It can bei used with mrun-call 118 118 \par\medskip 119 {\tt mrun ... -h lcsgih -K parallel trace...}}119 {\tt mrun ... -h lcsgih -K \dq parallel trace\dq ...}} 120 120 \end{itemize} 121 121 \end{frame} … … 177 177 \textbf{advec\_s\_bc.f90}\\ 178 178 ...}; 179 \node[green3](depository_parallel) [below=0.5cm of trunk] [xshift = 2cm] {MAKE\_D epository\_parallel/};}180 \uncover<3->{ 181 \node[green4](depository_parallel_trace) [below=0.5cm of depository_parallel] [xshift = 0.25cm] {MAKE\_D epository\_parallel\_trace/};}179 \node[green3](depository_parallel) [below=0.5cm of trunk] [xshift = 2cm] {MAKE\_DEPOSITORY\_parallel/};} 180 \uncover<3->{ 181 \node[green4](depository_parallel_trace) [below=0.5cm of depository_parallel] [xshift = 0.25cm] {MAKE\_DEPOSITORY\_parallel\_trace/};} 182 182 183 183 \uncover<2->{ … … 192 192 \path[arrow, thick] (7.3,-1.01) -- (depository_parallel.east);} 193 193 \uncover<3->{ 194 \path[line, thick] (7. 5,-0.3) -- (7.5,-2.02);195 \path[arrow, thick] (7. 5,-2.02) -- (depository_parallel_trace.east);}194 \path[line, thick] (7.7,-0.3) -- (7.7,-2.02); 195 \path[arrow, thick] (7.7,-2.02) -- (depository_parallel_trace.east);} 196 196 \end{tikzpicture} 197 197 \end{center} … … 202 202 \begin{tabbing} 203 203 \qquad \={\tt mrun ... -K parallel ...} will use the optimized version \\ 204 \> {\tt mrun ... -K "'parallel trace"'...} will use the debug version204 \> {\tt mrun ... -K \dq parallel trace\dq ...} will use the debug version 205 205 \end{tabbing} } 206 206 \uncover<5->{\begin{center} \textbf{Enabling debug options slows down the execution speed significantly!} \end{center}} -
palm/trunk/TUTORIAL/SOURCE/mrun_data_analysis.tex
r945 r973 69 69 \item<3-> Mean vertical profiles 70 70 \begin{itemize} 71 \footnotesize 71 72 \item[-]<3-> horizontally averaged, instantaneous or time-averaged 72 73 \end{itemize} … … 74 75 \item<5-> Two-dimensional cross sections ($xy$, $xz$, $yz$) 75 76 \begin{itemize} 77 \footnotesize 76 78 \item[-]<5-> instantaneous or time-averaged, + averaged along 3rd dimension 77 79 \end{itemize} 78 80 \item<6-> Complete three-dimensional data arrays 79 81 \begin{itemize} 82 \footnotesize 80 83 \item[-]<6-> instantaneous or time-averaged 81 84 \end{itemize} … … 85 88 \onslide<8-> First item is pure ASCII-data to give a short overview of the run. All other output is in netCDF format and can be graphically displayed.\\ 86 89 \vspace{2mm} 87 Additionally, power spectra can be output using the spectra-package (use \texttt{mrun}-option \ texttt{â-p spectraâ}).90 Additionally, power spectra can be output using the spectra-package (use \texttt{mrun}-option \grqq \texttt{-p spectra}\grqq). 88 91 89 92 \end{frame} … … 142 145 \texttt{ferret -gui}}; 143 146 144 147 \draw[-] (1.south west) -- (4.south east); 148 \draw[-] (13.south west) -- (43.south east); 149 \draw[-] (1.north east) -- (15.south east); 145 150 \end{tikzpicture} 146 151 \end{frame} … … 153 158 \begin{enumerate} 154 159 155 \item<2-> Carefully think about, which variables you want to analyze160 \item<2-> \textbf{Carefully think about, which variables you want to analyze} 156 161 \begin{itemize} 157 162 \scriptsize 158 163 \item[]<2-> e.g. temperature, wind, etc., resolved- or subgrid-scale?, output interval?, should they be time averaged? 159 164 \end{itemize} 160 161 \item<3-> Find and set the appropriate output parameters in the parameter file165 \vspace{1mm} 166 \item<3-> \textbf{Find and set the appropriate output parameters in the parameter file} 162 167 \begin{itemize} 163 168 \scriptsize 164 \item[]<3-> \texttt{data\_output\_pr = 'pt', 'u', 'w ''pt''', dt\_dopr = 900.0,}169 \item[]<3-> \texttt{data\_output\_pr = 'pt', 'u', 'w \dq pt\dq\, ', dt\_dopr = 900.0,} 165 170 \item[]<3-> \texttt{averaging\_interval\_pr = 600.0, dt\_averaging\_input\_pr = 10.0} 166 171 \end{itemize} 167 168 \item<4-> Check, if the necessary file connection statements exist in the .mrun.config file172 \vspace{1mm} 173 \item<4-> \textbf{Check, if the necessary file connection statements exist in the .mrun.config file}\\ 169 174 \begin{itemize} 170 175 \scriptsize 171 176 \item[]<4-> \texttt{DATA\_1D\_PR\_NETCDF out:loc:tr pr\# \~{}/palm/current\_version/JOBS/\$fname/OUTPUT \_pr nc} 172 177 \end{itemize} 173 174 \item<5-> Don't forget to activate the file connection statements by setting the correct activation string(s) in \texttt{mrun}-option \texttt{-r}178 \vspace{1mm} 179 \item<5-> \textbf{Don't forget to activate the file connection statements by setting the correct activation string(s) in \texttt{mrun}-option \texttt{-r}}\\ 175 180 \begin{itemize} 176 181 \scriptsize 177 \item[]<5-> \texttt{mrun ... -r ''... pr\# ...''...}182 \item[]<5-> \texttt{mrun ... -r \dq ... pr\# ...\dq\, ...} 178 183 \end{itemize} 179 180 \item<6-> After job completion, change to the OUTPUT-directory and call the appropriate graphics software184 \vspace{1mm} 185 \item<6-> \textbf{After job completion, change to the OUTPUT-directory and call the appropriate graphics software}\\ 181 186 \begin{itemize} 182 187 \scriptsize 183 \item[]<6-> \texttt{ncview <filename>} or\texttt{palmplot pr <options>}188 \item[]<6-> \texttt{ncview <filename>} \quad \textbf{or} \quad \texttt{palmplot pr <options>} 184 189 \end{itemize} 185 190 \end{enumerate} -
palm/trunk/TUTORIAL/SOURCE/mrun_steering_parameters.tex
r945 r973 67 67 \scriptsize 68 68 69 \item<2-> Domain size69 \item<2-> \textbf{Domain size} 70 70 \begin{itemize} 71 71 \scriptsize … … 73 73 \end{itemize} 74 74 75 \item<4-> Grid spacing76 \begin{itemize} 77 \scriptsize 78 \item[-]<4-> Must be so fine that most of the turbulent transport is resolved (explicit transport $>>$ subgrid-scale transport)\\ $\rightarrow$ check profiles of resolved-scale and subgrid-scale fluxes75 \item<4-> \textbf{Grid spacing} 76 \begin{itemize} 77 \scriptsize 78 \item[-]<4-> Must be so fine that most of the turbulent transport is resolved\\ (explicit transport $>>$ subgrid-scale transport)\\ $\rightarrow$ check profiles of resolved-scale and subgrid-scale fluxes 79 79 \item[-]<5-> Results should not depend on grid spacing $\rightarrow$ carry out sensitivity study 80 80 \end{itemize} 81 81 82 \item<6-> Simulation time82 \item<6-> \textbf{Simulation time} 83 83 \begin{itemize} 84 84 \scriptsize … … 88 88 \end{itemize} 89 89 90 \item<9-> Data analysis90 \item<9-> \textbf{Data analysis} 91 91 \begin{itemize} 92 92 \scriptsize … … 106 106 \footnotesize 107 107 108 \item<2-> Grid parameters (computational grid / processor grid)108 \item<2-> \textbf{Grid parameters (computational grid / processor grid)} 109 109 \begin{itemize} 110 110 \footnotesize … … 112 112 \end{itemize} 113 113 114 \item<3-> Numerical parameters114 \item<3-> \textbf{Numerical parameters} 115 115 \begin{itemize} 116 116 \footnotesize … … 118 118 \end{itemize} 119 119 120 \item<4-> Boundary condition parameters120 \item<4-> \textbf{Boundary condition parameters} 121 121 \begin{itemize} 122 122 \footnotesize … … 124 124 \end{itemize} 125 125 126 \item<5-> Initialization parameters126 \item<5-> \textbf{Initialization parameters} 127 127 \begin{itemize} 128 128 \footnotesize … … 130 130 \end{itemize} 131 131 132 \item<6-> Output parameters132 \item<6-> \textbf{Output parameters} 133 133 \begin{itemize} 134 134 \footnotesize … … 136 136 \end{itemize} 137 137 138 \item<7-> Physical parameters138 \item<7-> \textbf{Physical parameters} 139 139 \begin{itemize} 140 140 \footnotesize … … 154 154 \footnotesize 155 155 156 \item<2-> General initialization methods156 \item<2-> \textbf{General initialization methods} 157 157 \begin{itemize} 158 158 \footnotesize … … 160 160 \end{itemize} 161 161 162 \item<3-> Initial run:162 \item<3-> \textbf{Initial run:} 163 163 \begin{itemize} 164 164 \footnotesize … … 170 170 3d-data from a pre-run (possibly with smaller domain size than the initial run) are used 171 171 \item[-]<6-> \texttt{initializing\_actions = âby\_userâ}\\ 172 user has to provide allinitial settings173 \end{itemize} 174 175 \item<7-> Restart run:172 user has to provide \textbf{all} initial settings 173 \end{itemize} 174 175 \item<7-> \textbf{Restart run:} 176 176 \begin{itemize} 177 177 \footnotesize … … 190 190 \begin{itemize} 191 191 \footnotesize 192 \item<1-> The following parameters have to be set for an initial atmosphere at rest with neutral temperature stratification and a capping inversion:192 \item<1-> \textbf{The following parameters have to be set for an initial atmosphere at rest with neutral temperature stratification and a capping inversion:} 193 193 194 194 \quad \texttt{initializing\_actions = âset\_constant\_profilesâ,}\\ -
palm/trunk/TUTORIAL/SOURCE/parallelization.tex
r945 r973 108 108 109 109 \node (center) at (0,1) {}; 110 \onslide<2-> \node (Network) at (-3.5,1) [ ellipse,fill=green!20] {Network};110 \onslide<2-> \node (Network) at (-3.5,1) [draw, ellipse,fill=green!20] {Network}; 111 111 \node (dis_mem) at (-3.5,-1) [text width=0.28\textwidth] {\footnotesize \textbf{distributed} memory\\(Cray-T3E)}; 112 112 \onslide<3-> \node (add_mem) at (3.5,1) [rectangle, draw] {adressable memory}; … … 116 116 \onslide<6-> \node (clustered_systems) at (0,-3) [draw, text width=0.15\textwidth] {clustered systems}; 117 117 \node (cs_info) at (0,-4.2) [text width=0.4\textwidth] {\footnotesize (IBM-Regatta, Linux-Cluster, 118 NEC-SX, SGI-ICE, Cray-X T4)};118 NEC-SX, SGI-ICE, Cray-XE6)}; 119 119 120 120 % Adressable memory node (big) … … 138 138 % Adressable memory node (small) 139 139 \onslide<4-> 140 \draw[->, thick] (1.5,0.2) -- (0.4,0.2) ; 141 \node at (0,0.2) [scale=0.2] {% 142 \begin{tikzpicture} 140 141 \node (small_node) at (-2,0.6) [scale=0.2] {% 142 \begin{tikzpicture} 143 144 \node (add_mem_small) at (3.5,0.9) [ultra thick, rectangle, draw, minimum width=3cm] {}; 145 146 \node (p1_small) at (2,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 147 \node (p2_small) at (2.6,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 148 \node (p3_small) at (3.2,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 149 \node (p4_small) at (3.8,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 150 \node (p5_small) at (4.4,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 151 \node (p6_small) at (5,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 143 152 144 \node (add_mem_small) at (3.5,0.9) [ultra thick, rectangle, draw, minimum width=3cm] {}; 145 \node (p1_small) at (2,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 146 \node (p2_small) at (2.6,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 147 \node (p3_small) at (3.2,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 148 \node (p4_small) at (3.8,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 149 \node (p5_small) at (4.4,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 150 \node (p6_small) at (5,-0.05) [ultra thick, draw,circle, scale=0.9] {}; 151 152 \draw[-, ultra thick] (add_mem_small.south) -- (3.5,0.4); 153 \draw[-, ultra thick] (2,0.4) -- (5,0.4); 154 \draw[-, ultra thick] (2,0.4) -- (p1_small); 155 \draw[-, ultra thick] (2.6,0.4) -- (p2_small); 156 \draw[-, ultra thick] (3.2,0.4) -- (p3_small); 157 \draw[-, ultra thick] (3.8,0.4) -- (p4_small); 158 \draw[-, ultra thick] (4.4,0.4) -- (p5_small); 159 \draw[-, ultra thick] (5,0.4) -- (p6_small); 153 \draw[-, ultra thick] (add_mem_small.south) -- (3.5,0.4); 154 \draw[-, ultra thick] (2,0.4) -- (5,0.4); 155 \draw[-, ultra thick] (2,0.4) -- (p1_small); 156 \draw[-, ultra thick] (2.6,0.4) -- (p2_small); 157 \draw[-, ultra thick] (3.2,0.4) -- (p3_small); 158 \draw[-, ultra thick] (3.8,0.4) -- (p4_small); 159 \draw[-, ultra thick] (4.4,0.4) -- (p5_small); 160 \draw[-, ultra thick] (5,0.4) -- (p6_small); 161 162 163 \end{tikzpicture} 164 } ; 160 165 161 162 \end{tikzpicture} 163 } ; 164 166 \draw[->, thick] (1.5,0.2) -- (small_node) ; 167 \draw[-] (-2.7,0.75) -- (-2.3,0.725); 165 168 \onslide<5-> 166 \node (add_info) at (0,-0.1) [scale=0.9] {\scriptsize node};169 \node[below=-0.1cm of small_node] (add_info) [scale=0.9] {\scriptsize node}; 167 170 168 171 % Black Arrows … … 177 180 % OpenMP Arrows 178 181 \onslide<8-> \draw[->, ultra thick, color=yellow] (3.5,-2.6) -- (3.5,-1.5) ; 179 \draw[->, ultra thick, color=yellow] (2.5,-2.8) -- (-2. 5,0.7) ;182 \draw[->, ultra thick, color=yellow] (2.5,-2.8) -- (-2.0,0.1) ; 180 183 181 184 % Network decorations … … 209 212 \draw[-] (-2.45,1.0) -- (pr6); 210 213 \draw[-] (mem6) -- (pr6); 211 214 215 \onslide<1-> 212 216 \end{tikzpicture} 213 217 \end{center} … … 245 249 \begin{itemize} 246 250 \item<10-> Alternatively, a 1D-decomposition along $x$ or $y$ may be used in case of slow networks, but this generally doesn't scale for processor numbers $>$ 256. 251 \vspace{2mm} 247 252 \item<11-> Message passing is realized using MPI. 253 \vspace{2mm} 248 254 \item<12-> OpenMP parallelization as well as mixed usage of OpenMP and 249 255 MPI is also possible. (OpenMP tests and optimization is under way) … … 279 285 \onslide<5-> \includegraphics[width=0.8\textwidth]{parallelization_figures/fft.png} \end{center} 280 286 \vspace{-4mm} 281 \textbf{Example: transpositions for solving the poissonequation}287 \textbf{Example: transpositions for solving the Poisson\\ \hspace{4em}equation} 282 288 \end{column} 283 289 \end{columns} … … 353 359 \begin{frame} 354 360 \frametitle{Virtual Processor Grid Used in PALM} 355 \footnotesize 356 The processor grid and special data types are defined in file \texttt{init\_pegrid.f90} 361 \scriptsize 362 \vspace{2mm} 363 The processor grid and special data types are defined in file \texttt{init\_pegrid.f90}\\ 364 \ \\ 357 365 \begin{itemize} 358 366 \item<2-> PALM uses a two-dimensional virtual processor grid (in case of a 1D-decomposition, it has only one element along $y$). It is defined by a so called communicator (here: \texttt{comm2d}):\\ 359 \scriptsize 367 \tiny 368 \vspace{1.5mm} 360 369 \quad \texttt{ndim = 2}\\ 361 \quad \texttt{pdims(1) = npex ! \# of processors along x}\\362 \quad \texttt{pdims(2) = npey ! \# of processors along y}\\370 \quad \texttt{pdims(1) = npex \quad ! \# of processors along x}\\ 371 \quad \texttt{pdims(2) = npey \quad ! \# of processors along y}\\ 363 372 \quad \texttt{cyclic(1) = .TRUE.}\\ 364 373 \quad \texttt{cyclic(2) = .TRUE.}\\ 365 366 \quad \texttt{CALL MPI\underline{\ }CART\underline{\ }CREATE( MPI\underline{\ }COMM\underline{\ }WORLD, ndim, pdims, cyclic, \&}\\ 367 \quad \texttt{\hspace{10.5em} reorder, \textcolor{blue}{comm2d}, ierr )} 374 \ \\ 375 \quad \texttt{CALL MPI\underline{\ }CART\underline{\ }CREATE( MPI\underline{\ }COMM\underline{\ }WORLD, ndim, pdims, cyclic, reorder, \&}\\ 376 \quad \texttt{\hspace{10.5em} \textcolor{blue}{comm2d}, ierr )} 377 \scriptsize 378 \vspace{4mm} 368 379 \item<3-> The processor number (id) with respect to this processor grid, \texttt{myid}, is given by:\\ 369 \scriptsize 370 \quad \texttt{CALL MPI\underline{\ }COMM\underline{\ }RANK( comm2d, \textcolor{blue}{myid}, ierr )} 380 \tiny 381 \vspace{1.5mm} 382 \quad \texttt{CALL MPI\underline{\ }COMM\underline{\ }RANK( comm2d, \textcolor{blue}{myid}, ierr )} 383 \scriptsize 384 \vspace{4mm} 371 385 \item<4-> The ids of the neighbouring PEs are determined by:\\ 372 \scriptsize 386 \tiny 387 \vspace{1.5mm} 373 388 \quad \texttt{CALL MPI\underline{\ }CARD\underline{\ }SHIFT( comm2d, 0, 1, \textcolor{blue}{pleft}, \textcolor{blue}{pright}, ierr )}\\ 374 \quad \texttt{CALL MPI\underline{\ }CARD\underline{\ }SHIFT( comm2d, 1, 1, \textcolor{blue}{psouth}, \textcolor{blue}{pnorth}, ierr )} 389 \quad \texttt{CALL MPI\underline{\ }CARD\underline{\ }SHIFT( comm2d, 1, 1, \textcolor{blue}{psouth}, \textcolor{blue}{pnorth}, ierr )}\\ 375 390 \end{itemize} 376 391 \end{frame} … … 383 398 \item<1-> Ghost points are stored in additional array elements added at the horizontal boundaries of the subdomains, e.g.\\ 384 399 \tiny 400 \vspace{2mm} 385 401 \quad \texttt{u(:,:,nxl\textcolor{blue}{-ngl}), u(:,:,nxr\textcolor{blue}{+ngl}) ! left and right boundary}\\ 386 402 \quad \texttt{u(:,nys\textcolor{blue}{-ngl},:), u(:,nyn\textcolor{blue}{+ngl},:) ! south and north boundary}\\ 387 \ hspace{3mm}403 \vspace{4mm} 388 404 \item<2-> \scriptsize The exchange of ghost points is done in file \texttt{exchange\underline{\ }horiz.f90}\\ 389 405 \textbf{\underline{Simplified} example:} synchroneous exchange of ghost points along $x$ ($yz$-planes, send left, receive right plane):\\ 390 406 \tiny 407 \vspace{2mm} 391 408 \quad \texttt{CALL MPI\underline{\ }SENDRECV( ar(nzb,nys-\textcolor{blue}{ngl},nxl), ngp\underline{\ }yz, MPI\underline{\ }REAL, pleft, 0,}\\ 392 409 \quad \texttt{\hspace{9.5em}ar(nzb,nys-\textcolor{blue}{ngl},nxr+1), ngp\underline{\ }yz, MPI\underline{\ }REAL, pright, 0,}\\ 393 410 \quad \texttt{\hspace{9.5em}comm2d, status, ierr )}\\ 394 \ hspace{3mm}411 \vspace{4mm} 395 412 \item<3-> \scriptsize In the real code special MPI data types (vectors) are defined for exchange of $yz$/$xz$-planes for performance reasons and because array elements to be exchanged are not consecutively stored in memory for $xz$-planes:\\ 396 413 \tiny 414 \vspace{2mm} 397 415 \quad \texttt{ngp\underline{\ }yz(0) = (nzt - nzb + 2) * (nyn - nys + 1 + 2 * \textcolor{blue}{ngl} )}\\ 398 416 \quad \texttt{CALL MPI\underline{\ }TYPE\underline{\ }VECTOR( \textcolor{blue}{ngl}, ngp\underline{\ }yz(0), ngp\underline{\ }yz(0), MPI\underline{\ }REAL, type\underline{\ }yz(0), ierr )}\\ 399 \quad \texttt{CALL MPI\underline{\ }TYPE\underline{\ }COMMIT( type\underline{\ } xz(0), ierr ) ! see file init\underline{\ }pegrid.f90}\\417 \quad \texttt{CALL MPI\underline{\ }TYPE\underline{\ }COMMIT( type\underline{\ }yz(0), ierr ) ! see file init\underline{\ }pegrid.f90}\\ 400 418 \ \\ 401 419 \quad \texttt{CALL MPI\underline{\ }SENDRECV( ar(nzb,nys-ngl,nxl), type\underline{\ }yz(grid\underline{\ }level), MPI\underline{\ }REAL, pleft, 0, ...}\\ … … 431 449 \frametitle{Parallel I/O} 432 450 \scriptsize 451 \vspace{-2mm} 433 452 \begin{columns}[T] 434 453 \begin{column}{1.1\textwidth} … … 449 468 \onslide<4-> \textbf{General comment:} 450 469 \begin{itemize} 451 \item Parallel I/O on a large number of files ($>$1000) currently may cause severe file system problems (e.g. on Lustre file systems). A workaround for this problem will\\ be available soon.470 \item Parallel I/O on a large number of files ($>$1000) currently may cause severe file system problems (e.g. on Lustre file systems).\\ \textbf{Workaround:} reduce the maximum number of parallel I/O streams\\ \hspace{5.75em}(see \texttt{mrun}-options) 452 471 \end{itemize} 453 472 \end{column} -
palm/trunk/TUTORIAL/SOURCE/program_control.tex
r954 r973 290 290 errors have occurred!}} 291 291 \par\bigskip 292 \includegraphics[width= \textwidth]{program_control_figures/run_control_file.png}292 \includegraphics[width=1.08\textwidth]{program_control_figures/run_control_file.png} 293 293 \normalsize 294 294 \end{frame} -
palm/trunk/TUTORIAL/SOURCE/restarts_with_mrun.tex
r949 r973 93 93 94 94 95 % Folie 4 (Zu voll)?95 % Folie 4 96 96 \begin{frame} 97 97 \frametitle{Carrying Out Restart Runs With \texttt{mrun}} 98 98 \scriptsize 99 100 Concerning \texttt{mrun}, the first thing required to enable restart runs is to use the additional activating string \grqq \texttt{restart}\grqq\, in the \texttt{mrun}-call for the \underline{initial run}:\\ 101 \quad \texttt{mrun -d test ... -r ''d3\# restart''}\\ 102 This will have the following effects: 103 \vspace{2mm} 104 \begin{itemize} 105 \item<2-> At the end of the run, all necessary variables will bei written as binary data to the local file \texttt{BINOUT}. This is caused by an entry in the configuration file\\ 106 \quad \texttt{\%write\underline{ }binary true restart}\\ 107 which sets the environment variable \texttt{write\underline{ }binary}, which is in turn read by PALM from the local file \texttt{ENVPAR} created by \texttt{mrun}. 108 \item<3-> This binary file will be permanently stored in case that an appropriate file connection statement exists\\ 109 \begin{columns} 110 \column{1.05\textwidth} 111 \texttt{BINOUT out:loc:flpe restart \~{}/palm/current\underline{ }version/JOBS/\$fname/RESTART \underline{ }d3d} 112 \end{columns} 113 \item<4-> If, during the run, PALM detects that the simulation cannot be finished due to limited job time, it tells \texttt{mrun} (by creating a local file named \texttt{CONTINUE\underline{ }RUN}) that a restart job has to be started. \texttt{mrun} will then automatically start such a job by submitting the command\\ 114 \quad \texttt{mrun -d test ... -r ''d3f restart''}\\ 115 on the \textbf{local host}. Options of this command are nearly the same as of the initial run, but every sharp symbol (\grqq\#\grqq) in the activating strings is replaced by an \grqq f\grqq. 116 \end{itemize} 117 \onslide<5->\textcolor{red}{\textbf{This effects the activation of file connections for the restart job!}} 99 \begin{columns}[T] 100 \begin{column}{1.0\textwidth} 101 Concerning \texttt{mrun}, the first thing required to enable restart runs is to use the additional activating string \grqq \texttt{restart}\grqq\, in the \texttt{mrun}-call for the \underline{initial run}:\\ 102 \vspace{1mm} 103 \quad \texttt{mrun -d test ... -r \dq d3\# restart\dq}\\ 104 \ \\ 105 This will have the following effects: 106 \vspace{1mm} 107 \tiny 108 \begin{itemize} 109 \item<2-> At the end of the run, all necessary variables will bei written as binary data to the local file \texttt{BINOUT}. This is caused by an entry in the configuration file\\ 110 \vspace{1mm} 111 \quad \texttt{\%write\underline{ }binary true restart}\\ 112 \vspace{1mm} 113 which sets the environment variable \texttt{write\underline{ }binary}, which is in turn read by PALM from the local file \texttt{ENVPAR} created by \texttt{mrun}. 114 \vspace{3mm} 115 \item<3-> This binary file will be permanently stored in case that an appropriate file connection statement exists\\ 116 \vspace{1mm} 117 \quad \texttt{BINOUT out:loc:flpe restart \~{}/palm/current\underline{ }version/JOBS/\$fname/RESTART \underline{ }d3d} 118 \vspace{3mm} 119 \item<4-> If, during the run, PALM detects that the simulation cannot be finished due to limited job time, it tells \texttt{mrun} (by creating a local file named \texttt{CONTINUE\underline{ }RUN}) that a restart job has to be started. \texttt{mrun} will then automatically start such a job by submitting the command\\ 120 \vspace{1mm} 121 \quad \texttt{mrun -d test ... -r \dq d3f restart\dq}\\ 122 \vspace{1mm} 123 on the \textbf{local host}. Options of this command are nearly the same as of the initial run, but every sharp symbol (\grqq\#\grqq) in the activating strings is replaced by an \grqq f\grqq. 124 \end{itemize} 125 \scriptsize 126 \vspace{2mm} 127 \onslide<5->\textcolor{red}{\textbf{This effects the activation of file connections for the restart job!}} 128 \end{column} 129 \end{columns} 130 118 131 \end{frame} 119 132 … … 131 144 \begin{itemize} 132 145 \item<2-> For the restart job, the model receives a different parameter file than for the initial job (e.g. \texttt{example\underline{ }cbl\underline{ }p3d\textcolor{blue}{f}} instead of \texttt{example\underline{ }cbl\underline{ }p3d}).\\ 133 \vspace{ 2mm}146 \vspace{4mm} 134 147 The parameter file for the restart job is nearly the same as for the initial run, but it must contain the parameter setting\\ 148 \vspace{1mm} 135 149 \quad \texttt{initializing\underline{ }actions = 'read\underline{ }restart\underline{ }data'}\\ 150 \vspace{1mm} 136 151 in the \texttt{\&inipar}-NAMELIST-group. All other \texttt{\&inipar}-parameter-settings are ignored!\\ 137 \vspace{ 2mm}152 \vspace{4mm} 138 153 \texttt{\&d3par}-parameter values can freely be changed compared with the parameter file for the initial run.\\ 139 154 \vspace{4mm} 140 \item<3-> Input binary data file (\texttt{BININ}) is necessary (and available) only for restart jobs155 \item<3-> Input binary data file (\texttt{BININ}) is necessary (and available) only for\\ restart jobs 141 156 \end{itemize} 142 157 \end{frame} … … 167 182 168 183 169 % Folie 7 (Zu voll?)184 % Folie 7 170 185 \begin{frame} 171 186 \frametitle{Handling of Large Binary Data Files} … … 173 188 \begin{columns} 174 189 \column{1.1\textwidth} 190 \vspace{-1mm} 175 191 \begin{itemize} 176 192 \item<1-> Typically, the binary restart files are very large, so that they cannot be stored in the user's home-directory because of limited file quotas. Also, hard disks where \texttt{/home} is stored are typically very slow, so that the copy process needs very long time. 193 \vspace{1mm} 177 194 \item<2-> Using the file attribute \texttt{fl} (abbreviation for german \grqq Fortsetzungslauf\grqq) in the output file connection statement causes \texttt{mrun} to copy the local file to a special directory, which can be defined in the configuration file by the environment variable \texttt{tmp\underline{ }data\underline{ }catalog}. The permanent file described in the connection statement is also created, but it is \textbf{empty}. 195 \vspace{1mm} 178 196 \item<3-> At the end of the job, the second last cycle of the respective file with attribute \texttt{fl} is automatically deleted by \texttt{mrun} from the \texttt{tmp\underline{ }data\underline{ }catalog} in order to spare disc space. This can be prevented by setting the \texttt{mrun}-option \grqq\texttt{-k}\grqq (keep data from previous run). 179 197 \end{itemize} 180 198 \end{columns} 181 \ \\199 \vspace{2mm} 182 200 \onslide<4-> \textbf{Example:}\\ 183 201 \tiny \quad \texttt{\%base\underline{ }data\hspace{4.5em}\~{}/palm/current\underline{ }version/JOBS}\\ … … 189 207 \tiny \quad \texttt{/gfs2/work/niksiraa/palm\underline{ }restart\underline{ }data/example\underline{ }cbl\underline{ }d3d}\\ 190 208 \tiny \quad \texttt{\~{}/palm/current\underline{ }version/JOBS/example/RESTART/example\underline{ }cbl\underline{ }d3d \# empty file (directory)}\\ 191 \vspace{ 1mm}192 \onslide<6-> \scriptsize \textcolor{red}{Concerning input files, \texttt{mrun} always determines the current cycle number to be \underline{used from the contents of the directory defined by the file connection 209 \vspace{2mm} 210 \onslide<6-> \scriptsize \textcolor{red}{Concerning input files, \texttt{mrun} always determines the current cycle number to be \underline{used from the contents of the directory defined by the file connection}\\ \underline{statement!}} 193 211 194 212 \end{frame} … … 222 240 \begin{itemize} 223 241 \item<1-> By default, PALM checks after every timestep, if enough time remains from the job cpu limit to carry out the next timestep:\\ 224 \quad \grqq\texttt{total job time}\grqq\, - \grqq\texttt{time already consumed}\grqq\, $\leftarrow$ \texttt{termination\underline{ }time\underline{ }needed}\\ 225 (as given by \texttt{mrun}-option \texttt{-t} ...) \hspace{5mm} (as given by parameter in \texttt{\&d3par}-NAMELIST) 242 \vspace{1mm} 243 (\quad \grqq\texttt{total job time}\grqq\, - \grqq\texttt{time already consumed}\grqq\,) \texttt{<=} \texttt{termination\underline{ }time\underline{ }needed}\\ 244 (as given by \texttt{mrun}-option \texttt{-t} ...) \hspace{5mm} (as given by parameter in \texttt{\&d3par}-NAMELIST)\\ 245 \vspace{3mm} 226 246 \item<2-> \texttt{termination\underline{ }time\underline{ }needed} has to include the cpu time needed before running PALM (e.g. for compilation, copying of input data, etc.; default value: 300 s)!\\ 227 247 \ \\ 228 248 \onslide<3-> \textbf{Warning:}\\ 229 \quad \quad \grqq\texttt{total job time}\grqq\, $\leftarrow$ \texttt{termination\underline{ }time\underline{ }needed},\\ 249 \vspace{1mm} 250 \quad \quad \grqq\texttt{total job time}\grqq\, \texttt{<=} \texttt{termination\underline{ }time\underline{ }needed},\\ 230 251 \quad forces a restart after the first timestep! 231 \item<4-> \texttt{\&d3par}-parameters \texttt{restart\underline{ }time} and \texttt{dt\underline{ }restart} can be used to set restart time(s) manually. 232 \item<5-> In case of manually setting the restart time, the default checking (see above) is still active and a restart will be automatically forced if the job reaches its cpu limit, even if the manually set restart time has not been reached! 252 \vspace{3mm} 253 \item<4-> \texttt{\&d3par}-parameters \texttt{restart\underline{ }time} and \texttt{dt\underline{ }restart} can be used to set restart time(s) manually.\\ 254 \vspace{3mm} 255 \item<5-> In case of manually setting the restart time, the default checking (see above) is still active and a restart will be automatically forced if the job reaches its cpu limit, even if the manually set restart time has not been reached!\\ 233 256 \end{itemize} 234 257 \end{columns} … … 243 266 \item<1-> After a job has finished (\texttt{end\underline{ }time} has been reached), the user can submit a restart job manually (provided that restart data have been saved) by entering:\\ 244 267 \vspace{2mm} 245 \quad \texttt{mrun ... -r ''d3f ...''...}\\268 \quad \texttt{mrun ... -r \dq d3f ...\dq\, ...}\\ 246 269 or\\ 247 \quad \texttt{mrun ... -r ''d3f restart ...''...}\\270 \quad \texttt{mrun ... -r \dq d3f restart ...\dq\, ...}\\ 248 271 \ \\ 249 272 \item<2-> Remember to increase the value of \texttt{end\underline{ }time} in the parameter file before submitting the job. 273 \vspace{2mm} 250 274 \item<3-> If a manually started restart job shall continue a run of a former job chain which is somewhere in the middle of this chain, all binary files with respective higher cycle numbers have to be deleted or removed from their respective directories. 251 275 \end{itemize} -
palm/trunk/TUTORIAL/SOURCE/runs_with_mrun.tex
r964 r973 126 126 \onslide<6->\textcolor{red}{\textbf{Problems:} The user has to copy or rename output files, if 127 127 he/she wants to run the program more than once and if he concurrently wants to keep 128 the files from the former run(s).\\ 129 If he/she is using different input parameter files for steering, these files also have 128 the files from the former run(s). If he/she is using different input parameter files for steering, these files also have 130 129 to be copied into the working directory before the program is executed.}\\ 131 130 \vspace{1mm}
Note: See TracChangeset
for help on using the changeset viewer.