IO, DRIVER, PYTHON: Fix domain block dimensions with job restart.
Signed-off-by: Grzegorz Kowal <grzegorz@amuncode.org>
This commit is contained in:
parent
e1ee6f39bb
commit
76d7cf8826
@ -222,6 +222,8 @@ def amun_dataset(fname, vname, shrink = 1, progress = False):
|
|||||||
f = h5.File(fname, 'r')
|
f = h5.File(fname, 'r')
|
||||||
if 'rdims' in f['attributes'].attrs:
|
if 'rdims' in f['attributes'].attrs:
|
||||||
rm = amun_attribute(fname, 'rdims')
|
rm = amun_attribute(fname, 'rdims')
|
||||||
|
elif 'bdims' in f['attributes'].attrs:
|
||||||
|
rm = amun_attribute(fname, 'bdims')
|
||||||
else:
|
else:
|
||||||
rm = amun_attribute(fname, 'domain_base_dims')
|
rm = amun_attribute(fname, 'domain_base_dims')
|
||||||
f.close()
|
f.close()
|
||||||
|
@ -288,7 +288,7 @@ program amun
|
|||||||
if (check_status(status /= 0)) go to 3800
|
if (check_status(status /= 0)) go to 3800
|
||||||
call read_snapshot_parameter("maxlev" , toplev , status)
|
call read_snapshot_parameter("maxlev" , toplev , status)
|
||||||
if (check_status(status /= 0)) go to 3800
|
if (check_status(status /= 0)) go to 3800
|
||||||
call read_snapshot_parameter("rdims" , bdims , status)
|
call read_snapshot_parameter("bdims" , bdims , status)
|
||||||
if (check_status(status /= 0)) go to 3800
|
if (check_status(status /= 0)) go to 3800
|
||||||
call read_snapshot_parameter("xmin" , xmin , status)
|
call read_snapshot_parameter("xmin" , xmin , status)
|
||||||
if (check_status(status /= 0)) go to 3800
|
if (check_status(status /= 0)) go to 3800
|
||||||
|
@ -1792,7 +1792,7 @@ module io
|
|||||||
use blocks , only : get_last_id
|
use blocks , only : get_last_id
|
||||||
use coordinates , only : minlev, maxlev
|
use coordinates , only : minlev, maxlev
|
||||||
use coordinates , only : ncells, nghosts
|
use coordinates , only : ncells, nghosts
|
||||||
use coordinates , only : ddims => domain_base_dims
|
use coordinates , only : bdims => domain_base_dims
|
||||||
use coordinates , only : xmin, xmax, ymin, ymax, zmin, zmax
|
use coordinates , only : xmin, xmax, ymin, ymax, zmin, zmax
|
||||||
use coordinates , only : periodic
|
use coordinates , only : periodic
|
||||||
use equations , only : eqsys, eos, gamma, csnd
|
use equations , only : eqsys, eos, gamma, csnd
|
||||||
@ -1819,7 +1819,7 @@ module io
|
|||||||
|
|
||||||
! local vectors
|
! local vectors
|
||||||
!
|
!
|
||||||
integer, dimension(3) :: bdims = 1
|
integer, dimension(3) :: dims = 1
|
||||||
integer, dimension(3) :: per
|
integer, dimension(3) :: per
|
||||||
|
|
||||||
! local allocatable arrays
|
! local allocatable arrays
|
||||||
@ -1904,9 +1904,9 @@ module io
|
|||||||
|
|
||||||
! store the vector attributes
|
! store the vector attributes
|
||||||
!
|
!
|
||||||
bdims(1:NDIMS) = ncells
|
dims(1:NDIMS) = ncells
|
||||||
call write_attribute(gid, 'dims' , bdims)
|
call write_attribute(gid, 'dims' , dims)
|
||||||
call write_attribute(gid, 'domain_base_dims', ddims)
|
call write_attribute(gid, 'bdims', bdims)
|
||||||
|
|
||||||
! store random number generator seed values
|
! store random number generator seed values
|
||||||
!
|
!
|
||||||
|
Loading…
x
Reference in New Issue
Block a user