mdolab / idwarp

IDWarp is a mesh warping package for the MACH framework.
Other
17 stars 29 forks source link

Restart file functionality is broken #37

Open anilyil opened 3 years ago

anilyil commented 3 years ago

Description of feature

IDWarp can restart from a file and skip the costly full initialization. See: https://github.com/mdolab/idwarp/blob/master/src/warp/initializeWarping.F90#L66-L76 This feature is not widely used, and it is not tested. We should include tests for this and make its usage widespread. For most cases, people run the same meshes over and over again, and with this option, idwarp can automatically save and load restart files and speed up initialization. Possibly not huge gains but it is free so why not.

sseraj commented 3 years ago

This feature did not work when I tested it. I am adding the output here for documentation.

I ran the same ASO case twice. The first run saved the file as expected:

#--------------------------------#
 Unique Surface Nodes :     21444
#--------------------------------#
 Computing Denomenator Estimate...
 Load Balancing...
 Saving restart file...
 Finished Mesh Initialization.

I quit the optimization before the first iteration completed and ran the case again with the same number of processors. The restart file did not work:

#--------------------------------#
 Unique Surface Nodes :     21444
#--------------------------------#
 Loading restart file...
 Number of points in restart file are different...
 Computing Denomenator Estimate...

This deletes the restart file immediately after it determines the file is wrong. I quit the run before it recomputed everything again.

To see if this was case-specific, I tried the same thing on a different ASO case (the MACH-Aero tutorial wing). As with the previous case, the first save appeared to work. Loading the file was still unsuccessful, this time with a different error.

#--------------------------------#
 Unique Surface Nodes :      4077
#--------------------------------#
 Loading restart file...
 Checking restart file...
           0       10001   1.0033570785290862E-002   1.0571498650968850E-002   1.0000000000000001E-015
 Restart file not accurate...
 Computing Denomenator Estimate...
 Load Balancing...
 Saving restart file...
 Finished Mesh Initialization.

Maybe I'm doing something wrong, but this feature is probably broken.