Skip to content

Commit 84054d4

Browse files
author
Anand Radhakrishnan
committed
POST PROCESS FIX
1 parent a47cb03 commit 84054d4

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

src/post_process/m_data_input.f90

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@ impure subroutine s_read_parallel_conservative_data(t_step, m_MOK, n_MOK, p_MOK,
531531
mpi_p, status, ierr)
532532
end do
533533
else
534-
do i = 1, adv_idx%end
534+
do i = 1, sys_size
535535
var_MOK = int(i, MPI_OFFSET_KIND)
536536
call MPI_FILE_READ_ALL(ifile, MPI_IO_DATA%var(i)%sf, data_size, &
537537
mpi_p, status, ierr)
@@ -609,7 +609,9 @@ impure subroutine s_initialize_data_input_module
609609
if (p > 0) then
610610
call s_allocate_field_arrays(-buff_size, m + buff_size, n + buff_size, p + buff_size)
611611
if(down_sample) then
612-
allocate(q_cons_temp(i)%sf(-1:m+1,-1:n+1,-1:p+1))
612+
do i = 1, sys_size
613+
allocate(q_cons_temp(i)%sf(-1:m+1,-1:n+1,-1:p+1))
614+
end do
613615
end if
614616
else
615617
! Simulation is 2D

src/post_process/m_global_parameters.fpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -798,7 +798,11 @@ contains
798798
allocate (MPI_IO_DATA%view(1:sys_size))
799799
allocate (MPI_IO_DATA%var(1:sys_size))
800800
do i = 1, sys_size
801-
allocate (MPI_IO_DATA%var(i)%sf(0:m, 0:n, 0:p))
801+
if(down_sample) then
802+
allocate (MPI_IO_DATA%var(i)%sf(-1:m+1, -1:n+1, -1:p+1))
803+
else
804+
allocate (MPI_IO_DATA%var(i)%sf(0:m, 0:n, 0:p))
805+
end if
802806
MPI_IO_DATA%var(i)%sf => null()
803807
end do
804808

0 commit comments

Comments
 (0)