From 3a37ffee7e25196e3ea29a7cea49024be8c67a93 Mon Sep 17 00:00:00 2001 From: Philipp Pracht Date: Fri, 3 May 2024 15:18:27 +0100 Subject: [PATCH] Fix bug from issue #296 Signed-off-by: Philipp Pracht --- src/algos/refine.f90 | 5 +++-- src/axis_module.f90 | 2 +- src/qcg/solvtool_misc.f90 | 9 +++++++-- 3 files changed, 11 insertions(+), 5 deletions(-) diff --git a/src/algos/refine.f90 b/src/algos/refine.f90 index 4acb0be8..c335426d 100644 --- a/src/algos/refine.f90 +++ b/src/algos/refine.f90 @@ -36,7 +36,7 @@ subroutine crest_refine(env,input,output) character(len=*),intent(in) :: input character(len=*),intent(in),optional :: output !===========================================================! - integer :: i,j,k,l,io,ich,m + integer :: i,j,k,l,io,ich,m,t1,t2 logical :: pr,wr,ex !===========================================================! character(len=:),allocatable :: outname @@ -98,8 +98,9 @@ subroutine crest_refine(env,input,output) call crest_oloop(env,nat,nall,at,xyz,eread,.false.) case(refine%confsolv) + call new_ompautoset(env,'subprocess',1,t1,t2) write (stdout,'("> ConfSolv: ΔΔGsoln estimation from 3D directed message passing neural networks (D-MPNN)")') - call confsolv_request( input, nall, env%threads, etmp, io) + call confsolv_request( input, nall, t2, etmp, io) if(io == 0)then eread(:) = etmp(:)*kcaltoau !> since CREGEN deals with Eh energies endif diff --git a/src/axis_module.f90 b/src/axis_module.f90 index 50f045b1..f6e7379a 100644 --- a/src/axis_module.f90 +++ b/src/axis_module.f90 @@ -336,7 +336,7 @@ subroutine axistrf(nat,nat0,at,coord) allocate (attmp(nat0)) allocate (coordtmp(3,nat0)) attmp(1:nat0) = at(1:nat0) - coordtmp(3,1:nat0) = coord(3,1:nat0) + coordtmp(1:3,1:nat0) = coord(1:3,1:nat0) call axis_0(nat0,attmp,coordtmp,rot,avmom,evec) deallocate (coordtmp,attmp) diff --git a/src/qcg/solvtool_misc.f90 b/src/qcg/solvtool_misc.f90 index c5272de1..4e6bdf44 100644 --- a/src/qcg/solvtool_misc.f90 +++ b/src/qcg/solvtool_misc.f90 @@ -115,7 +115,7 @@ subroutine xtb_lmo(env, fname)!,chrg) character(len=*), intent(in) :: fname character(len=80) :: pipe character(len=512) :: jobcall - integer :: T,Tn + integer :: T,Tn,io pipe = ' > xtb.out 2>/dev/null' @@ -125,7 +125,12 @@ subroutine xtb_lmo(env, fname)!,chrg) !---- jobcall, special gbsa treatment not needed, as the entire flag is included in env%solv write (jobcall, '(a,1x,a,1x,a,'' --sp --lmo '',a)') & & trim(env%ProgName), trim(fname), trim(env%lmover), trim(pipe) - call command(trim(jobcall)) + call command(trim(jobcall), exitstat=io) + + if(io /= 0)then + write(*,*) 'error in xtb_lmo' + stop + endif !--- cleanup call remove('wbo')