mirror of
https://github.com/LCPQ/quantum_package
synced 2024-07-22 18:57:31 +02:00
Fixed read wf
This commit is contained in:
parent
3ac2e2d8c3
commit
f7831c033a
@ -138,21 +138,21 @@ BEGIN_PROVIDER [ integer(bit_kind), psi_det, (N_int,2,psi_det_size) ]
|
|||||||
|
|
||||||
if (exists) then
|
if (exists) then
|
||||||
call read_dets(psi_det,N_int,N_det)
|
call read_dets(psi_det,N_int,N_det)
|
||||||
else
|
|
||||||
psi_det = 0_bit_kind
|
|
||||||
do i=1,N_int
|
|
||||||
psi_det(i,1,1) = HF_bitmask(i,1)
|
|
||||||
psi_det(i,2,1) = HF_bitmask(i,2)
|
|
||||||
enddo
|
|
||||||
endif
|
|
||||||
else
|
|
||||||
psi_det = 0_bit_kind
|
|
||||||
do i=1,N_int
|
|
||||||
psi_det(i,1,1) = HF_bitmask(i,1)
|
|
||||||
psi_det(i,2,1) = HF_bitmask(i,2)
|
|
||||||
enddo
|
|
||||||
endif
|
|
||||||
print *, 'Read psi_det'
|
print *, 'Read psi_det'
|
||||||
|
else
|
||||||
|
psi_det = 0_bit_kind
|
||||||
|
do i=1,N_int
|
||||||
|
psi_det(i,1,1) = HF_bitmask(i,1)
|
||||||
|
psi_det(i,2,1) = HF_bitmask(i,2)
|
||||||
|
enddo
|
||||||
|
endif
|
||||||
|
else
|
||||||
|
psi_det = 0_bit_kind
|
||||||
|
do i=1,N_int
|
||||||
|
psi_det(i,1,1) = HF_bitmask(i,1)
|
||||||
|
psi_det(i,2,1) = HF_bitmask(i,2)
|
||||||
|
enddo
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
IRP_IF MPI
|
IRP_IF MPI
|
||||||
include 'mpif.h'
|
include 'mpif.h'
|
||||||
|
@ -175,11 +175,20 @@ subroutine zmq_get_psi(zmq_to_qp_run_socket, worker_id)
|
|||||||
call zmq_get_N_states(zmq_to_qp_run_socket, worker_id)
|
call zmq_get_N_states(zmq_to_qp_run_socket, worker_id)
|
||||||
call zmq_get_N_det(zmq_to_qp_run_socket, worker_id)
|
call zmq_get_N_det(zmq_to_qp_run_socket, worker_id)
|
||||||
call zmq_get_psi_det_size(zmq_to_qp_run_socket, worker_id)
|
call zmq_get_psi_det_size(zmq_to_qp_run_socket, worker_id)
|
||||||
TOUCH psi_det_size N_det N_states
|
|
||||||
|
if (size(psi_det) /= N_int*2_8*psi_det_size*bit_kind) then
|
||||||
|
deallocate(psi_det)
|
||||||
|
allocate(psi_det(N_int,2,psi_det_size))
|
||||||
|
endif
|
||||||
|
|
||||||
|
if (size(psi_coef) /= psi_det_size*N_states) then
|
||||||
|
deallocate(psi_coef)
|
||||||
|
allocate(psi_coef(psi_det_size,N_states))
|
||||||
|
endif
|
||||||
|
|
||||||
call zmq_get_psi_det(zmq_to_qp_run_socket, worker_id)
|
call zmq_get_psi_det(zmq_to_qp_run_socket, worker_id)
|
||||||
call zmq_get_psi_coef(zmq_to_qp_run_socket, worker_id)
|
call zmq_get_psi_coef(zmq_to_qp_run_socket, worker_id)
|
||||||
SOFT_TOUCH psi_det psi_coef
|
SOFT_TOUCH psi_det psi_coef psi_det_size N_det N_states
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user