| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=255), | intent(in) | :: | filename |
subroutine ReadBosonicPopsfile(filename) !The Bosonic popsfile is just a normal popsfile resulting from a bosoic !FCIQMC simulation. What is special here is what information we exctract !out of that file and how we use it in specifiying flag_nospawn character(255), intent(in) :: filename character(*), parameter :: t_r = 'ReadBosonicPopsFile' #ifdef USE_HDF_ integer(hid_t) :: file_id, plist_id integer(hdf_err) :: err integer :: mpi_err write(6, *) write(6, *) "========== Reading in Bosonic WF from HDF5 popsfile ==========" write(6, *) 'File name: ', trim(filename) ! Initialise the hdf5 fortran interface call h5open_f(err) ! Set up a property list to ensure file handling across all nodes. call h5pcreate_f(H5P_FILE_ACCESS_F, plist_id, err) call h5pset_fapl_mpio_f(plist_id, CommGlobal%MPI_VAL, mpiInfoNull%MPI_VAL, err) ! Open the popsfile call h5fopen_f(filename, H5F_ACC_RDONLY_F, file_id, err, & access_prp=plist_id) if (err /= 0) call stop_all(t_r, "No bosonic popsfile found") call read_bosonic_walkers(file_id) ! And we are done call h5pclose_f(plist_id, err) call h5fclose_f(file_id, err) call h5close_f(err) call neci_flush(6) call MPIBarrier(mpi_err) #else unused_var(filename) call stop_all(t_r, 'HDF5 support not enabled at compile time') #endif end subroutine ReadBosonicPopsfile