Hi again
if I ran
mpirun -np 4 ElmerSolver_mpi myfile.sif
up to the allotted time limit on the system,
can i restart the simulation from the generated .vtu files with a single line
Restart File = "case_t1000.pvtu
(assuming my latest saved time index was 1000 for the sake of example)
or do I have to write
Restart File = "case.result.0"
Restart File = "case.result.1"
Restart File = "case.result.2"
Restart File = "case.result.3"
in the .sif ?
Nice weekend everybody
how to restart under mpi
Re: how to restart under mpi
Well from trial and error, I found out that only
Restart File = "case.result"
is accepted by ElmerSolver_mpi
Restart File = "case.result"
is accepted by ElmerSolver_mpi
Re: how to restart under mpi
It would be nice though if we could dispense with .result files altogether as they become ever larger as the simulation progresses since data from subsequent timesteps get appended to it. The .vtu contain the same information but as individual files, one for each timestep. It is more burdensome to open a huge .result file ,and to search for the requested time step let alone that disk space is wasted duplicating the data in both .result and .vtu files.
Just a comment which applies not only to mpi but serial programs in general.
Just a comment which applies not only to mpi but serial programs in general.
-
- Site Admin
- Posts: 4823
- Joined: 22 Aug 2009, 11:57
- Antispam: Yes
- Location: Espoo, Finland
- Contact:
Re: how to restart under mpi
Hi
You could just save the last timestep for Result format. They will be also smaller in binary.
vtu files can never have the same information because they lack possibility to save information associated to edges, faces and bubbles (Hcurl, Hdiv and p-elements), and also does not include permutation information (in passive regions just zero is assumed). So unfortunately there is no way to just rely on vtu files.
-Peter
You could just save the last timestep for Result format. They will be also smaller in binary.
vtu files can never have the same information because they lack possibility to save information associated to edges, faces and bubbles (Hcurl, Hdiv and p-elements), and also does not include permutation information (in passive regions just zero is assumed). So unfortunately there is no way to just rely on vtu files.
-Peter
Re: how to restart under mpi
Sorry but what is the syntax to save just the last timestep for the Result file ? Could not find it in the Elmer Solver manual.
I guess it is a command to overwrite it at every time step.
Regards
Marc
I guess it is a command to overwrite it at every time step.
Regards
Marc
-
- Site Admin
- Posts: 4823
- Joined: 22 Aug 2009, 11:57
- Antispam: Yes
- Location: Espoo, Finland
- Contact:
Re: how to restart under mpi
Hi
You can say "Output Intervals = 0".
While thinking of it there could be a separate keyword to control saving of result file only.
-Peter
You can say "Output Intervals = 0".
While thinking of it there could be a separate keyword to control saving of result file only.
-Peter
-
- Site Admin
- Posts: 4823
- Joined: 22 Aug 2009, 11:57
- Antispam: Yes
- Location: Espoo, Finland
- Contact:
Re: how to restart under mpi
Well, I added a keyword for Simulation section "Output File Final Only = True" that will make it possible to control only the Output File whereas all other effects of Output Internal applies to the other output routines.
https://github.com/ElmerCSC/elmerfem/co ... 26c49cf780
-Peter
Re: how to restart under mpi
As I dont understand the effect of Output Intervals on other output routines.
this is what I did:
Simulation section
.....
Timestep Intervals(1) = 1200000000
Timestep Size = Variable deltaT
Real MATC "tx(0)"
Output Intervals(1) = 0
Output File = "case.result"
Binary Output = Logical True
Output Global Variables = True
.........
Solver 19
Exec Condition = Equals vtuflag
Equation = "result vtu"
Procedure = "ResultOutputSolve" "ResultOutputSolver"
Output File Name = "parav"
Vtu Format = Logical True
Single Precision = Logical True ! double precision is the default
! In the Vtu format all fields are saved if the user does not list them explicitly.
Scalar Field 1 = String Potential
Scalar Field 2 = String Temperature
Scalar Field 3 = String Pressure
Scalar Field 4 = String Ne
Scalar Field 5 = String Np
Scalar Field 6 = String Nn
Vector Field 1 = String Velocity
End
I dont use Exec Solver = after saving
for my Solver 19 because my code will set vtuflag to a nonnegative value once every 100th time step
which seems to work.
Also because of
Output Intervals(1) = 0
case.result
only contains the latest time step
this is what I did:
Simulation section
.....
Timestep Intervals(1) = 1200000000
Timestep Size = Variable deltaT
Real MATC "tx(0)"
Output Intervals(1) = 0
Output File = "case.result"
Binary Output = Logical True
Output Global Variables = True
.........
Solver 19
Exec Condition = Equals vtuflag
Equation = "result vtu"
Procedure = "ResultOutputSolve" "ResultOutputSolver"
Output File Name = "parav"
Vtu Format = Logical True
Single Precision = Logical True ! double precision is the default
! In the Vtu format all fields are saved if the user does not list them explicitly.
Scalar Field 1 = String Potential
Scalar Field 2 = String Temperature
Scalar Field 3 = String Pressure
Scalar Field 4 = String Ne
Scalar Field 5 = String Np
Scalar Field 6 = String Nn
Vector Field 1 = String Velocity
End
I dont use Exec Solver = after saving
for my Solver 19 because my code will set vtuflag to a nonnegative value once every 100th time step
which seems to work.
Also because of
Output Intervals(1) = 0
case.result
only contains the latest time step