diff --git a/ocaml/qptypes_generator.ml b/ocaml/qptypes_generator.ml index fd1739f1..be2bf18c 100644 --- a/ocaml/qptypes_generator.ml +++ b/ocaml/qptypes_generator.ml @@ -150,12 +150,12 @@ end = struct let to_string = function | Huckel -> \"Huckel\" - | HCore -> \"Hcore\" + | HCore -> \"HCore\" let of_string s = - match s with - | \"Huckel\" -> Huckel - | \"Hcore\" -> HCore + match (String.lowercase s) with + | \"huckel\" -> Huckel + | \"hcore\" -> HCore | _ -> failwith (\"Wrong Guess type : \"^s) end @@ -176,10 +176,10 @@ end = struct | Write -> \"Write\" | None -> \"None\" let of_string s = - match s with - | \"Read\" -> Read - | \"Write\" -> Write - | \"None\" -> None + match (String.lowercase s) with + | \"read\" -> Read + | \"write\" -> Write + | \"none\" -> None | _ -> failwith (\"Wrong IO type : \"^s) end diff --git a/scripts/compilation/qp_create_ninja.py b/scripts/compilation/qp_create_ninja.py index f78e20e8..242a2b63 100755 --- a/scripts/compilation/qp_create_ninja.py +++ b/scripts/compilation/qp_create_ninja.py @@ -127,7 +127,7 @@ def dict_module_genelogy_path(d_module_genelogy): def get_l_module_with_ezfio_cfg(): """ - Return all the module who have a EZFIO.cfg + Return all the modules that have a EZFIO.cfg """ from os import listdir from os.path import isfile @@ -734,7 +734,7 @@ def create_build_ninja_module(path_module): l_string += ["rule make_all_binaries", " command = ninja -f {0}".format(ROOT_BUILD_NINJA), - " pool = console", " description = Compile all the module", + " pool = console", " description = Compiling all modules", ""] l_string += ["rule make_clean", " command = module_handler.py clean {0}".format(path_module.rel), @@ -761,7 +761,7 @@ def create_build_ninja_global(l_module): l_string += ["rule make_all_binaries", " command = ninja -f {0}".format(ROOT_BUILD_NINJA), - " pool = console", " description = Compile all the module", + " pool = console", " description = Compiling all modules", ""] l_string += ["rule make_clean", diff --git a/scripts/pseudo/put_pseudo_in_ezfio.py b/scripts/pseudo/put_pseudo_in_ezfio.py index ff63a18d..f44fb097 100755 --- a/scripts/pseudo/put_pseudo_in_ezfio.py +++ b/scripts/pseudo/put_pseudo_in_ezfio.py @@ -30,7 +30,7 @@ p = re.compile(ur'\|(\d+)><\d+\|') def get_pseudo_str(l_atom): """ - Run EMSL_local for geting the str of the speudo potential + Run EMSL_local for getting the str of the pseudo potential str_ele : Element Symbol: Na diff --git a/src/Determinants/spindeterminants.irp.f b/src/Determinants/spindeterminants.irp.f index 09a92df6..ad9d9960 100644 --- a/src/Determinants/spindeterminants.irp.f +++ b/src/Determinants/spindeterminants.irp.f @@ -14,12 +14,13 @@ integer*8 function spin_det_search_key(det,Nint) END_DOC integer, intent(in) :: Nint integer(bit_kind), intent(in) :: det(Nint) + integer(bit_kind), parameter :: unsigned_shift = not(huge(1_bit_kind)) ! 100...00 integer :: i spin_det_search_key = det(1) do i=2,Nint spin_det_search_key = ieor(spin_det_search_key,det(i)) enddo - spin_det_search_key = iand(huge(det(1)),spin_det_search_key) + spin_det_search_key = spin_det_search_key-unsigned_shift end @@ -347,53 +348,6 @@ subroutine write_spindeterminants call ezfio_set_spindeterminants_psi_coef_matrix_rows(psi_svd_matrix_rows) call ezfio_set_spindeterminants_psi_coef_matrix_columns(psi_svd_matrix_columns) -! integer :: n_svd_coefs -! double precision :: norm, f -! f = 1.d0/dble(N_states) -! norm = 1.d0 -! do n_svd_coefs=1,N_det_alpha_unique -! do k=1,N_states -! norm -= psi_svd_coefs(n_svd_coefs,k)*psi_svd_coefs(n_svd_coefs,k) -! enddo -! if (norm < 1.d-4) then -! exit -! endif -! enddo -! n_svd_coefs -= 1 -! call ezfio_set_spindeterminants_n_svd_coefs(n_svd_coefs) -! -! double precision, allocatable :: dtmp(:,:,:) -! allocate(dtmp(N_det_alpha_unique,n_svd_coefs,N_states)) -! do k=1,N_states -! do j=1,n_svd_coefs -! do i=1,N_det_alpha_unique -! dtmp(i,j,k) = psi_svd_alpha(i,j,k) -! enddo -! enddo -! enddo -! call ezfio_set_spindeterminants_psi_svd_alpha(dtmp) -! deallocate(dtmp) -! -! allocate(dtmp(N_det_beta_unique,n_svd_coefs,N_states)) -! do k=1,N_states -! do j=1,n_svd_coefs -! do i=1,N_det_beta_unique -! dtmp(i,j,k) = psi_svd_beta(i,j,k) -! enddo -! enddo -! enddo -! call ezfio_set_spindeterminants_psi_svd_beta(dtmp) -! deallocate(dtmp) -! -! allocate(dtmp(n_svd_coefs,N_states,1)) -! do k=1,N_states -! do j=1,n_svd_coefs -! dtmp(j,k,1) = psi_svd_coefs(j,k) -! enddo -! enddo -! call ezfio_set_spindeterminants_psi_svd_coefs(dtmp) -! deallocate(dtmp) - end @@ -420,28 +374,6 @@ BEGIN_PROVIDER [ double precision, psi_svd_matrix_values, (N_det,N_states) ] PROVIDE psi_coef_sorted_bit -! l=0 -! do j=1,N_det_beta_unique -! do k=1,N_int -! tmp_det(k,2) = psi_det_beta_unique(k,j) -! enddo -! do i=1,N_det_alpha_unique -! do k=1,N_int -! tmp_det(k,1) = psi_det_alpha_unique(k,i) -! enddo -! idx = get_index_in_psi_det_sorted_bit(tmp_det,N_int) -! if (idx > 0) then -! l += 1 -! psi_svd_matrix_rows(l) = i -! psi_svd_matrix_columns(l) = j -! do k=1,N_states -! psi_svd_matrix_values(l,k) = psi_coef_sorted_bit(idx,k) -! enddo -! endif -! enddo -! enddo -! ASSERT (l == N_det) - integer, allocatable :: iorder(:), to_sort(:) integer, external :: get_index_in_psi_det_alpha_unique integer, external :: get_index_in_psi_det_beta_unique