10
0
mirror of https://github.com/LCPQ/quantum_package synced 2024-11-09 07:33:53 +01:00
quantum_package/ocaml/qp_create_ezfio_from_xyz.ml

292 lines
8.8 KiB
OCaml
Raw Normal View History

2014-08-27 16:38:13 +02:00
open Qputils;;
open Qptypes;;
open Core.Std;;
let spec =
let open Command.Spec in
empty
2015-05-02 14:50:23 +02:00
+> flag "o" (optional string)
2014-11-16 18:05:04 +01:00
~doc:"file Name of the created EZFIO file."
2014-08-27 16:38:13 +02:00
+> flag "b" (required string)
~doc:"string Name of basis set."
2014-08-27 16:38:13 +02:00
+> flag "c" (optional_with_default 0 int)
~doc:"int Total charge of the molecule. Default is 0."
2015-05-02 14:50:23 +02:00
+> flag "m" (optional_with_default 1 int)
2014-11-16 18:05:04 +01:00
~doc:"int Spin multiplicity (2S+1) of the molecule. Default is 1."
2015-05-04 20:19:59 +02:00
+> flag "p" no_arg
2015-05-21 10:15:13 +02:00
~doc:"Using pseudopotentials"
2014-08-27 16:38:13 +02:00
+> anon ("xyz_file" %: string)
;;
2015-05-02 14:50:23 +02:00
let run ?o b c m p xyz_file =
2014-08-27 16:38:13 +02:00
(* Read molecule *)
let molecule =
(Molecule.of_xyz_file xyz_file ~charge:(Charge.of_int c)
~multiplicity:(Multiplicity.of_int m) )
2014-08-27 16:38:13 +02:00
in
2014-11-16 18:05:04 +01:00
let nuclei = molecule.Molecule.nuclei in
let basis_table = Hashtbl.Poly.create () in
(* Open basis set channels *)
let basis_channel element =
let key = Element.to_string element in
match Hashtbl.find basis_table key with
| Some in_channel ->
in_channel
| None ->
begin
Printf.printf "%s is not defined in basis %s.\nEnter alternate basis : %!"
(Element.to_long_string element) b ;
let bas =
match In_channel.input_line stdin with
| Some line -> String.strip line |> String.lowercase
| None -> failwith "Aborted"
in
let new_channel = In_channel.create
(Qpackage.root ^ "/data/basis/" ^ bas)
in
Hashtbl.add_exn basis_table ~key:key ~data:new_channel;
new_channel
end
in
Added /home/scemama/quantum_package/scripts/make_binary.sh make[1]: Entering directory `/home/scemama/quantum_package/src' cd AOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/AOs' make[3]: Entering directory `/home/scemama/quantum_package/src/AOs' make[3]: Leaving directory `/home/scemama/quantum_package/src/AOs' make[2]: Leaving directory `/home/scemama/quantum_package/src/AOs' cd BiInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[3]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[3]: Leaving directory `/home/scemama/quantum_package/src/BiInts' make[2]: Leaving directory `/home/scemama/quantum_package/src/BiInts' cd Bitmask ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[3]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[3]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' make[2]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' cd Dets ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Dets' make[3]: Entering directory `/home/scemama/quantum_package/src/Dets' make[3]: Leaving directory `/home/scemama/quantum_package/src/Dets' make[2]: Leaving directory `/home/scemama/quantum_package/src/Dets' cd Electrons ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[3]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[3]: Leaving directory `/home/scemama/quantum_package/src/Electrons' make[2]: Leaving directory `/home/scemama/quantum_package/src/Electrons' cd Ezfio_files ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[3]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[3]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' make[2]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' cd Full_CI ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[3]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[3]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' make[2]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' cd Generators_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[3]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[3]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' make[2]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' cd Hartree_Fock ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[3]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[3]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' make[2]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' cd MOGuess ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[3]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[3]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' make[2]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' cd MonoInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[3]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[3]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' make[2]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' cd MOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/MOs' make[3]: Entering directory `/home/scemama/quantum_package/src/MOs' make[3]: Leaving directory `/home/scemama/quantum_package/src/MOs' make[2]: Leaving directory `/home/scemama/quantum_package/src/MOs' cd Nuclei ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[3]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[3]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' make[2]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' cd Output ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Output' make[3]: Entering directory `/home/scemama/quantum_package/src/Output' make[3]: Leaving directory `/home/scemama/quantum_package/src/Output' make[2]: Leaving directory `/home/scemama/quantum_package/src/Output' cd Selectors_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[3]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[3]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' make[2]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' cd Utils ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Utils' make[3]: Entering directory `/home/scemama/quantum_package/src/Utils' make[3]: Leaving directory `/home/scemama/quantum_package/src/Utils' make[2]: Leaving directory `/home/scemama/quantum_package/src/Utils' cd Molden ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Molden' make[3]: Entering directory `/home/scemama/quantum_package/src/Molden' make[3]: Leaving directory `/home/scemama/quantum_package/src/Molden' make[2]: Leaving directory `/home/scemama/quantum_package/src/Molden' make[1]: Leaving directory `/home/scemama/quantum_package/src' make[1]: Entering directory `/home/scemama/quantum_package/ocaml' rm -f -- test_atom ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_atom.byte -use-ocamlfind # No parallelism done ln -s test_atom.byte test_atom rm -f -- test_basis ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_basis.byte -use-ocamlfind # No parallelism done ln -s test_basis.byte test_basis rm -f -- test_bitlist ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_bitlist.byte -use-ocamlfind # No parallelism done ln -s test_bitlist.byte test_bitlist rm -f -- test_determinants ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_determinants.byte -use-ocamlfind # No parallelism done ln -s test_determinants.byte test_determinants rm -f -- test_elements ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_elements.byte -use-ocamlfind # No parallelism done ln -s test_elements.byte test_elements rm -f -- test_excitation ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_excitation.byte -use-ocamlfind # No parallelism done ln -s test_excitation.byte test_excitation rm -f -- test_gto ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_gto.byte -use-ocamlfind # No parallelism done ln -s test_gto.byte test_gto rm -f -- test_input ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_input.byte -use-ocamlfind # No parallelism done ln -s test_input.byte test_input rm -f -- test_mo_label ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_mo_label.byte -use-ocamlfind # No parallelism done ln -s test_mo_label.byte test_mo_label rm -f -- test_molecule ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_molecule.byte -use-ocamlfind # No parallelism done ln -s test_molecule.byte test_molecule rm -f -- test_point3d ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_point3d.byte -use-ocamlfind # No parallelism done ln -s test_point3d.byte test_point3d make -C /home/scemama/quantum_package/data executables make[2]: Entering directory `/home/scemama/quantum_package/data' cd /home/scemama/quantum_package/src ; make executables make[3]: Entering directory `/home/scemama/quantum_package/src' cd AOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/AOs' make[5]: Entering directory `/home/scemama/quantum_package/src/AOs' make[5]: Leaving directory `/home/scemama/quantum_package/src/AOs' make[4]: Leaving directory `/home/scemama/quantum_package/src/AOs' cd BiInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[5]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[5]: Leaving directory `/home/scemama/quantum_package/src/BiInts' make[4]: Leaving directory `/home/scemama/quantum_package/src/BiInts' cd Bitmask ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[5]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[5]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' make[4]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' cd Dets ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Dets' make[5]: Entering directory `/home/scemama/quantum_package/src/Dets' make[5]: Leaving directory `/home/scemama/quantum_package/src/Dets' make[4]: Leaving directory `/home/scemama/quantum_package/src/Dets' cd Electrons ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[5]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[5]: Leaving directory `/home/scemama/quantum_package/src/Electrons' make[4]: Leaving directory `/home/scemama/quantum_package/src/Electrons' cd Ezfio_files ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[5]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[5]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' make[4]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' cd Full_CI ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[5]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[5]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' make[4]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' cd Generators_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[5]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[5]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' make[4]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' cd Hartree_Fock ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[5]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[5]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' make[4]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' cd MOGuess ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[5]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[5]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' make[4]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' cd MonoInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[5]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[5]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' make[4]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' cd MOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/MOs' make[5]: Entering directory `/home/scemama/quantum_package/src/MOs' make[5]: Leaving directory `/home/scemama/quantum_package/src/MOs' make[4]: Leaving directory `/home/scemama/quantum_package/src/MOs' cd Nuclei ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[5]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[5]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' make[4]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' cd Output ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Output' make[5]: Entering directory `/home/scemama/quantum_package/src/Output' make[5]: Leaving directory `/home/scemama/quantum_package/src/Output' make[4]: Leaving directory `/home/scemama/quantum_package/src/Output' cd Selectors_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[5]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[5]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' make[4]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' cd Utils ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Utils' make[5]: Entering directory `/home/scemama/quantum_package/src/Utils' make[5]: Leaving directory `/home/scemama/quantum_package/src/Utils' make[4]: Leaving directory `/home/scemama/quantum_package/src/Utils' cd Molden ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Molden' make[5]: Entering directory `/home/scemama/quantum_package/src/Molden' make[5]: Leaving directory `/home/scemama/quantum_package/src/Molden' make[4]: Leaving directory `/home/scemama/quantum_package/src/Molden' rm -f executables ; \ for EXE in $(find /home/scemama/quantum_package/src -perm /u+x -type f | grep -e "/home/scemama/quantum_package/src/[^/]*/[^/]*$" |sort ) ; \ do printf "%-30s %s\n" $(basename $EXE) $EXE | sed "s|/home/scemama/quantum_package|\$QPACKAGE_ROOT|g" >> executables ;\ done make[3]: Leaving directory `/home/scemama/quantum_package/src' mv /home/scemama/quantum_package/src/executables . make[2]: Leaving directory `/home/scemama/quantum_package/data' rm -f -- qp_basis_clean ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_basis_clean.native -use-ocamlfind # No parallelism done ln -s qp_basis_clean.native qp_basis_clean rm -f -- qp_create_ezfio_from_xyz ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_create_ezfio_from_xyz.native -use-ocamlfind # No parallelism done ln -s qp_create_ezfio_from_xyz.native qp_create_ezfio_from_xyz rm -f -- qp_edit ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_edit.native -use-ocamlfind # No parallelism done ln -s qp_edit.native qp_edit rm -f -- qp_print ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_print.native -use-ocamlfind # No parallelism done ln -s qp_print.native qp_print rm -f -- qp_run ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_run.native -use-ocamlfind # No parallelism done ln -s qp_run.native qp_run rm -f -- qp_set_ddci ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_set_ddci.native -use-ocamlfind # No parallelism done ln -s qp_set_ddci.native qp_set_ddci rm -f -- qp_set_mo_class ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_set_mo_class.native -use-ocamlfind # No parallelism done ln -s qp_set_mo_class.native qp_set_mo_class make[1]: Leaving directory `/home/scemama/quantum_package/ocaml' Creating root of static directory Copying binary files /home/scemama/quantum_package Copying dynamic libraries Copying EMSL_Basis directory Copying scripts directory Creating quantum_package.rc Creating the archive Done : /home/scemama/quantum_package/quantum_package_static.tar.gz
2015-01-16 00:48:09 +01:00
let temp_filename =
Filename.temp_file "qp_create_" ".basis"
in
2014-11-16 18:05:04 +01:00
let rec build_basis = function
| [] -> ()
| elem_and_basis_name :: rest ->
begin
match (String.lsplit2 ~on:':' elem_and_basis_name) with
| None -> (* Principal basis *)
2015-01-12 16:58:22 +01:00
let basis = elem_and_basis_name in
let command =
2015-05-04 20:19:59 +02:00
if (p) then
Added /home/scemama/quantum_package/scripts/make_binary.sh make[1]: Entering directory `/home/scemama/quantum_package/src' cd AOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/AOs' make[3]: Entering directory `/home/scemama/quantum_package/src/AOs' make[3]: Leaving directory `/home/scemama/quantum_package/src/AOs' make[2]: Leaving directory `/home/scemama/quantum_package/src/AOs' cd BiInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[3]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[3]: Leaving directory `/home/scemama/quantum_package/src/BiInts' make[2]: Leaving directory `/home/scemama/quantum_package/src/BiInts' cd Bitmask ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[3]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[3]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' make[2]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' cd Dets ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Dets' make[3]: Entering directory `/home/scemama/quantum_package/src/Dets' make[3]: Leaving directory `/home/scemama/quantum_package/src/Dets' make[2]: Leaving directory `/home/scemama/quantum_package/src/Dets' cd Electrons ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[3]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[3]: Leaving directory `/home/scemama/quantum_package/src/Electrons' make[2]: Leaving directory `/home/scemama/quantum_package/src/Electrons' cd Ezfio_files ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[3]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[3]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' make[2]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' cd Full_CI ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[3]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[3]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' make[2]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' cd Generators_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[3]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[3]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' make[2]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' cd Hartree_Fock ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[3]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[3]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' make[2]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' cd MOGuess ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[3]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[3]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' make[2]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' cd MonoInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[3]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[3]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' make[2]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' cd MOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/MOs' make[3]: Entering directory `/home/scemama/quantum_package/src/MOs' make[3]: Leaving directory `/home/scemama/quantum_package/src/MOs' make[2]: Leaving directory `/home/scemama/quantum_package/src/MOs' cd Nuclei ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[3]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[3]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' make[2]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' cd Output ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Output' make[3]: Entering directory `/home/scemama/quantum_package/src/Output' make[3]: Leaving directory `/home/scemama/quantum_package/src/Output' make[2]: Leaving directory `/home/scemama/quantum_package/src/Output' cd Selectors_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[3]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[3]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' make[2]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' cd Utils ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Utils' make[3]: Entering directory `/home/scemama/quantum_package/src/Utils' make[3]: Leaving directory `/home/scemama/quantum_package/src/Utils' make[2]: Leaving directory `/home/scemama/quantum_package/src/Utils' cd Molden ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Molden' make[3]: Entering directory `/home/scemama/quantum_package/src/Molden' make[3]: Leaving directory `/home/scemama/quantum_package/src/Molden' make[2]: Leaving directory `/home/scemama/quantum_package/src/Molden' make[1]: Leaving directory `/home/scemama/quantum_package/src' make[1]: Entering directory `/home/scemama/quantum_package/ocaml' rm -f -- test_atom ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_atom.byte -use-ocamlfind # No parallelism done ln -s test_atom.byte test_atom rm -f -- test_basis ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_basis.byte -use-ocamlfind # No parallelism done ln -s test_basis.byte test_basis rm -f -- test_bitlist ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_bitlist.byte -use-ocamlfind # No parallelism done ln -s test_bitlist.byte test_bitlist rm -f -- test_determinants ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_determinants.byte -use-ocamlfind # No parallelism done ln -s test_determinants.byte test_determinants rm -f -- test_elements ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_elements.byte -use-ocamlfind # No parallelism done ln -s test_elements.byte test_elements rm -f -- test_excitation ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_excitation.byte -use-ocamlfind # No parallelism done ln -s test_excitation.byte test_excitation rm -f -- test_gto ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_gto.byte -use-ocamlfind # No parallelism done ln -s test_gto.byte test_gto rm -f -- test_input ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_input.byte -use-ocamlfind # No parallelism done ln -s test_input.byte test_input rm -f -- test_mo_label ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_mo_label.byte -use-ocamlfind # No parallelism done ln -s test_mo_label.byte test_mo_label rm -f -- test_molecule ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_molecule.byte -use-ocamlfind # No parallelism done ln -s test_molecule.byte test_molecule rm -f -- test_point3d ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_point3d.byte -use-ocamlfind # No parallelism done ln -s test_point3d.byte test_point3d make -C /home/scemama/quantum_package/data executables make[2]: Entering directory `/home/scemama/quantum_package/data' cd /home/scemama/quantum_package/src ; make executables make[3]: Entering directory `/home/scemama/quantum_package/src' cd AOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/AOs' make[5]: Entering directory `/home/scemama/quantum_package/src/AOs' make[5]: Leaving directory `/home/scemama/quantum_package/src/AOs' make[4]: Leaving directory `/home/scemama/quantum_package/src/AOs' cd BiInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[5]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[5]: Leaving directory `/home/scemama/quantum_package/src/BiInts' make[4]: Leaving directory `/home/scemama/quantum_package/src/BiInts' cd Bitmask ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[5]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[5]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' make[4]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' cd Dets ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Dets' make[5]: Entering directory `/home/scemama/quantum_package/src/Dets' make[5]: Leaving directory `/home/scemama/quantum_package/src/Dets' make[4]: Leaving directory `/home/scemama/quantum_package/src/Dets' cd Electrons ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[5]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[5]: Leaving directory `/home/scemama/quantum_package/src/Electrons' make[4]: Leaving directory `/home/scemama/quantum_package/src/Electrons' cd Ezfio_files ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[5]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[5]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' make[4]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' cd Full_CI ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[5]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[5]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' make[4]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' cd Generators_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[5]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[5]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' make[4]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' cd Hartree_Fock ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[5]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[5]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' make[4]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' cd MOGuess ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[5]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[5]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' make[4]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' cd MonoInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[5]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[5]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' make[4]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' cd MOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/MOs' make[5]: Entering directory `/home/scemama/quantum_package/src/MOs' make[5]: Leaving directory `/home/scemama/quantum_package/src/MOs' make[4]: Leaving directory `/home/scemama/quantum_package/src/MOs' cd Nuclei ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[5]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[5]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' make[4]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' cd Output ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Output' make[5]: Entering directory `/home/scemama/quantum_package/src/Output' make[5]: Leaving directory `/home/scemama/quantum_package/src/Output' make[4]: Leaving directory `/home/scemama/quantum_package/src/Output' cd Selectors_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[5]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[5]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' make[4]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' cd Utils ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Utils' make[5]: Entering directory `/home/scemama/quantum_package/src/Utils' make[5]: Leaving directory `/home/scemama/quantum_package/src/Utils' make[4]: Leaving directory `/home/scemama/quantum_package/src/Utils' cd Molden ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Molden' make[5]: Entering directory `/home/scemama/quantum_package/src/Molden' make[5]: Leaving directory `/home/scemama/quantum_package/src/Molden' make[4]: Leaving directory `/home/scemama/quantum_package/src/Molden' rm -f executables ; \ for EXE in $(find /home/scemama/quantum_package/src -perm /u+x -type f | grep -e "/home/scemama/quantum_package/src/[^/]*/[^/]*$" |sort ) ; \ do printf "%-30s %s\n" $(basename $EXE) $EXE | sed "s|/home/scemama/quantum_package|\$QPACKAGE_ROOT|g" >> executables ;\ done make[3]: Leaving directory `/home/scemama/quantum_package/src' mv /home/scemama/quantum_package/src/executables . make[2]: Leaving directory `/home/scemama/quantum_package/data' rm -f -- qp_basis_clean ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_basis_clean.native -use-ocamlfind # No parallelism done ln -s qp_basis_clean.native qp_basis_clean rm -f -- qp_create_ezfio_from_xyz ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_create_ezfio_from_xyz.native -use-ocamlfind # No parallelism done ln -s qp_create_ezfio_from_xyz.native qp_create_ezfio_from_xyz rm -f -- qp_edit ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_edit.native -use-ocamlfind # No parallelism done ln -s qp_edit.native qp_edit rm -f -- qp_print ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_print.native -use-ocamlfind # No parallelism done ln -s qp_print.native qp_print rm -f -- qp_run ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_run.native -use-ocamlfind # No parallelism done ln -s qp_run.native qp_run rm -f -- qp_set_ddci ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_set_ddci.native -use-ocamlfind # No parallelism done ln -s qp_set_ddci.native qp_set_ddci rm -f -- qp_set_mo_class ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_set_mo_class.native -use-ocamlfind # No parallelism done ln -s qp_set_mo_class.native qp_set_mo_class make[1]: Leaving directory `/home/scemama/quantum_package/ocaml' Creating root of static directory Copying binary files /home/scemama/quantum_package Copying dynamic libraries Copying EMSL_Basis directory Copying scripts directory Creating quantum_package.rc Creating the archive Done : /home/scemama/quantum_package/quantum_package_static.tar.gz
2015-01-16 00:48:09 +01:00
Qpackage.root ^ "/scripts/get_basis.sh \"" ^ temp_filename
2015-05-04 20:23:06 +02:00
^ "\" \"" ^ basis ^"\" pseudo"
2015-05-02 14:50:23 +02:00
else
Qpackage.root ^ "/scripts/get_basis.sh \"" ^ temp_filename
2015-05-04 20:23:06 +02:00
^ "\" \"" ^ basis ^"\""
2015-01-12 16:58:22 +01:00
in
2014-11-16 18:05:04 +01:00
begin
2015-01-12 16:58:22 +01:00
let filename =
Unix.open_process_in command
|> In_channel.input_all
|> String.strip
2014-11-16 18:05:04 +01:00
in
2015-01-12 16:58:22 +01:00
let new_channel =
In_channel.create filename
in
Unix.unlink filename;
List.iter nuclei ~f:(fun elem->
let key = Element.to_string elem.Atom.element
2014-11-16 18:05:04 +01:00
in
match Hashtbl.add basis_table ~key:key ~data:new_channel with
| `Ok -> ()
| `Duplicate -> ()
)
end
| Some (key, basis) -> (*Aux basis *)
begin
let elem = Element.of_string key
and basis = String.lowercase basis
in
2015-01-12 16:58:22 +01:00
let key = Element.to_string elem
2014-11-16 18:05:04 +01:00
in
2015-01-12 16:58:22 +01:00
let command =
Added /home/scemama/quantum_package/scripts/make_binary.sh make[1]: Entering directory `/home/scemama/quantum_package/src' cd AOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/AOs' make[3]: Entering directory `/home/scemama/quantum_package/src/AOs' make[3]: Leaving directory `/home/scemama/quantum_package/src/AOs' make[2]: Leaving directory `/home/scemama/quantum_package/src/AOs' cd BiInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[3]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[3]: Leaving directory `/home/scemama/quantum_package/src/BiInts' make[2]: Leaving directory `/home/scemama/quantum_package/src/BiInts' cd Bitmask ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[3]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[3]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' make[2]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' cd Dets ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Dets' make[3]: Entering directory `/home/scemama/quantum_package/src/Dets' make[3]: Leaving directory `/home/scemama/quantum_package/src/Dets' make[2]: Leaving directory `/home/scemama/quantum_package/src/Dets' cd Electrons ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[3]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[3]: Leaving directory `/home/scemama/quantum_package/src/Electrons' make[2]: Leaving directory `/home/scemama/quantum_package/src/Electrons' cd Ezfio_files ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[3]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[3]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' make[2]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' cd Full_CI ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[3]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[3]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' make[2]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' cd Generators_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[3]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[3]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' make[2]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' cd Hartree_Fock ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[3]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[3]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' make[2]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' cd MOGuess ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[3]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[3]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' make[2]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' cd MonoInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[3]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[3]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' make[2]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' cd MOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/MOs' make[3]: Entering directory `/home/scemama/quantum_package/src/MOs' make[3]: Leaving directory `/home/scemama/quantum_package/src/MOs' make[2]: Leaving directory `/home/scemama/quantum_package/src/MOs' cd Nuclei ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[3]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[3]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' make[2]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' cd Output ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Output' make[3]: Entering directory `/home/scemama/quantum_package/src/Output' make[3]: Leaving directory `/home/scemama/quantum_package/src/Output' make[2]: Leaving directory `/home/scemama/quantum_package/src/Output' cd Selectors_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[3]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[3]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' make[2]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' cd Utils ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Utils' make[3]: Entering directory `/home/scemama/quantum_package/src/Utils' make[3]: Leaving directory `/home/scemama/quantum_package/src/Utils' make[2]: Leaving directory `/home/scemama/quantum_package/src/Utils' cd Molden ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[2]: Entering directory `/home/scemama/quantum_package/src/Molden' make[3]: Entering directory `/home/scemama/quantum_package/src/Molden' make[3]: Leaving directory `/home/scemama/quantum_package/src/Molden' make[2]: Leaving directory `/home/scemama/quantum_package/src/Molden' make[1]: Leaving directory `/home/scemama/quantum_package/src' make[1]: Entering directory `/home/scemama/quantum_package/ocaml' rm -f -- test_atom ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_atom.byte -use-ocamlfind # No parallelism done ln -s test_atom.byte test_atom rm -f -- test_basis ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_basis.byte -use-ocamlfind # No parallelism done ln -s test_basis.byte test_basis rm -f -- test_bitlist ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_bitlist.byte -use-ocamlfind # No parallelism done ln -s test_bitlist.byte test_bitlist rm -f -- test_determinants ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_determinants.byte -use-ocamlfind # No parallelism done ln -s test_determinants.byte test_determinants rm -f -- test_elements ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_elements.byte -use-ocamlfind # No parallelism done ln -s test_elements.byte test_elements rm -f -- test_excitation ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_excitation.byte -use-ocamlfind # No parallelism done ln -s test_excitation.byte test_excitation rm -f -- test_gto ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_gto.byte -use-ocamlfind # No parallelism done ln -s test_gto.byte test_gto rm -f -- test_input ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_input.byte -use-ocamlfind # No parallelism done ln -s test_input.byte test_input rm -f -- test_mo_label ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_mo_label.byte -use-ocamlfind # No parallelism done ln -s test_mo_label.byte test_mo_label rm -f -- test_molecule ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_molecule.byte -use-ocamlfind # No parallelism done ln -s test_molecule.byte test_molecule rm -f -- test_point3d ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt test_point3d.byte -use-ocamlfind # No parallelism done ln -s test_point3d.byte test_point3d make -C /home/scemama/quantum_package/data executables make[2]: Entering directory `/home/scemama/quantum_package/data' cd /home/scemama/quantum_package/src ; make executables make[3]: Entering directory `/home/scemama/quantum_package/src' cd AOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/AOs' make[5]: Entering directory `/home/scemama/quantum_package/src/AOs' make[5]: Leaving directory `/home/scemama/quantum_package/src/AOs' make[4]: Leaving directory `/home/scemama/quantum_package/src/AOs' cd BiInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[5]: Entering directory `/home/scemama/quantum_package/src/BiInts' make[5]: Leaving directory `/home/scemama/quantum_package/src/BiInts' make[4]: Leaving directory `/home/scemama/quantum_package/src/BiInts' cd Bitmask ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[5]: Entering directory `/home/scemama/quantum_package/src/Bitmask' make[5]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' make[4]: Leaving directory `/home/scemama/quantum_package/src/Bitmask' cd Dets ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Dets' make[5]: Entering directory `/home/scemama/quantum_package/src/Dets' make[5]: Leaving directory `/home/scemama/quantum_package/src/Dets' make[4]: Leaving directory `/home/scemama/quantum_package/src/Dets' cd Electrons ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[5]: Entering directory `/home/scemama/quantum_package/src/Electrons' make[5]: Leaving directory `/home/scemama/quantum_package/src/Electrons' make[4]: Leaving directory `/home/scemama/quantum_package/src/Electrons' cd Ezfio_files ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[5]: Entering directory `/home/scemama/quantum_package/src/Ezfio_files' make[5]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' make[4]: Leaving directory `/home/scemama/quantum_package/src/Ezfio_files' cd Full_CI ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[5]: Entering directory `/home/scemama/quantum_package/src/Full_CI' make[5]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' make[4]: Leaving directory `/home/scemama/quantum_package/src/Full_CI' cd Generators_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[5]: Entering directory `/home/scemama/quantum_package/src/Generators_full' make[5]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' make[4]: Leaving directory `/home/scemama/quantum_package/src/Generators_full' cd Hartree_Fock ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[5]: Entering directory `/home/scemama/quantum_package/src/Hartree_Fock' make[5]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' make[4]: Leaving directory `/home/scemama/quantum_package/src/Hartree_Fock' cd MOGuess ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[5]: Entering directory `/home/scemama/quantum_package/src/MOGuess' make[5]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' make[4]: Leaving directory `/home/scemama/quantum_package/src/MOGuess' cd MonoInts ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[5]: Entering directory `/home/scemama/quantum_package/src/MonoInts' make[5]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' make[4]: Leaving directory `/home/scemama/quantum_package/src/MonoInts' cd MOs ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/MOs' make[5]: Entering directory `/home/scemama/quantum_package/src/MOs' make[5]: Leaving directory `/home/scemama/quantum_package/src/MOs' make[4]: Leaving directory `/home/scemama/quantum_package/src/MOs' cd Nuclei ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[5]: Entering directory `/home/scemama/quantum_package/src/Nuclei' make[5]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' make[4]: Leaving directory `/home/scemama/quantum_package/src/Nuclei' cd Output ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Output' make[5]: Entering directory `/home/scemama/quantum_package/src/Output' make[5]: Leaving directory `/home/scemama/quantum_package/src/Output' make[4]: Leaving directory `/home/scemama/quantum_package/src/Output' cd Selectors_full ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[5]: Entering directory `/home/scemama/quantum_package/src/Selectors_full' make[5]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' make[4]: Leaving directory `/home/scemama/quantum_package/src/Selectors_full' cd Utils ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Utils' make[5]: Entering directory `/home/scemama/quantum_package/src/Utils' make[5]: Leaving directory `/home/scemama/quantum_package/src/Utils' make[4]: Leaving directory `/home/scemama/quantum_package/src/Utils' cd Molden ; make -j $(cat /proc/cpuinfo | grep MHz | wc -l) make[4]: Entering directory `/home/scemama/quantum_package/src/Molden' make[5]: Entering directory `/home/scemama/quantum_package/src/Molden' make[5]: Leaving directory `/home/scemama/quantum_package/src/Molden' make[4]: Leaving directory `/home/scemama/quantum_package/src/Molden' rm -f executables ; \ for EXE in $(find /home/scemama/quantum_package/src -perm /u+x -type f | grep -e "/home/scemama/quantum_package/src/[^/]*/[^/]*$" |sort ) ; \ do printf "%-30s %s\n" $(basename $EXE) $EXE | sed "s|/home/scemama/quantum_package|\$QPACKAGE_ROOT|g" >> executables ;\ done make[3]: Leaving directory `/home/scemama/quantum_package/src' mv /home/scemama/quantum_package/src/executables . make[2]: Leaving directory `/home/scemama/quantum_package/data' rm -f -- qp_basis_clean ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_basis_clean.native -use-ocamlfind # No parallelism done ln -s qp_basis_clean.native qp_basis_clean rm -f -- qp_create_ezfio_from_xyz ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_create_ezfio_from_xyz.native -use-ocamlfind # No parallelism done ln -s qp_create_ezfio_from_xyz.native qp_create_ezfio_from_xyz rm -f -- qp_edit ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_edit.native -use-ocamlfind # No parallelism done ln -s qp_edit.native qp_edit rm -f -- qp_print ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_print.native -use-ocamlfind # No parallelism done ln -s qp_print.native qp_print rm -f -- qp_run ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_run.native -use-ocamlfind # No parallelism done ln -s qp_run.native qp_run rm -f -- qp_set_ddci ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_set_ddci.native -use-ocamlfind # No parallelism done ln -s qp_set_ddci.native qp_set_ddci rm -f -- qp_set_mo_class ocamlbuild -j 0 -syntax camlp4o -cflags "-g -warn-error A" -lflags "-g -warn-error A" -ocamlopt ocamlc.opt qp_set_mo_class.native -use-ocamlfind # No parallelism done ln -s qp_set_mo_class.native qp_set_mo_class make[1]: Leaving directory `/home/scemama/quantum_package/ocaml' Creating root of static directory Copying binary files /home/scemama/quantum_package Copying dynamic libraries Copying EMSL_Basis directory Copying scripts directory Creating quantum_package.rc Creating the archive Done : /home/scemama/quantum_package/quantum_package_static.tar.gz
2015-01-16 00:48:09 +01:00
Qpackage.root ^ "/scripts/get_basis.sh \"" ^ temp_filename ^
2015-01-23 16:53:06 +01:00
"\" \"" ^ basis ^ "\" " ^ key
2015-01-12 16:58:22 +01:00
in
begin
let filename =
Unix.open_process_in command
|> In_channel.input_all
|> String.strip
in
let new_channel =
In_channel.create filename
in
Unix.unlink filename;
match Hashtbl.add basis_table ~key:key ~data:new_channel with
| `Ok -> ()
| `Duplicate -> failwith ("Duplicate definition of basis for "^(Element.to_long_string elem))
end
end
2014-11-16 18:05:04 +01:00
end;
build_basis rest
in
2015-01-12 16:58:22 +01:00
String.split ~on:'|' b
2014-11-16 18:05:04 +01:00
|> List.rev_map ~f:String.strip
|> build_basis;
2014-08-27 16:38:13 +02:00
(* Build EZFIO File name *)
let ezfio_file =
match o with
| Some x -> x
| None ->
begin
match String.rsplit2 ~on:'.' xyz_file with
| Some (x,"xyz") -> x^".ezfio"
| _ -> xyz_file^".ezfio"
end
in
if Sys.file_exists_exn ezfio_file then
failwith (ezfio_file^" already exists");
(* Create EZFIO *)
Ezfio.set_file ezfio_file;
(* Write Electrons *)
2014-10-23 14:42:14 +02:00
Ezfio.set_electrons_elec_alpha_num ( Elec_alpha_number.to_int
2014-08-27 16:38:13 +02:00
molecule.Molecule.elec_alpha ) ;
2014-10-23 14:42:14 +02:00
Ezfio.set_electrons_elec_beta_num ( Elec_beta_number.to_int
2014-08-27 16:38:13 +02:00
molecule.Molecule.elec_beta ) ;
(* Write Nuclei *)
let labels =
List.map ~f:(fun x->Element.to_string x.Atom.element) nuclei
and charges =
List.map ~f:(fun x-> Atom.(Charge.to_float x.charge)) nuclei
and coords =
(List.map ~f:(fun x-> x.Atom.coord.Point3d.x) nuclei) @
(List.map ~f:(fun x-> x.Atom.coord.Point3d.y) nuclei) @
(List.map ~f:(fun x-> x.Atom.coord.Point3d.z) nuclei) in
let nucl_num = (List.length labels) in
Ezfio.set_nuclei_nucl_num nucl_num ;
Ezfio.set_nuclei_nucl_label (Ezfio.ezfio_array_of_list
~rank:1 ~dim:[| nucl_num |] ~data:labels);
Ezfio.set_nuclei_nucl_charge (Ezfio.ezfio_array_of_list
~rank:1 ~dim:[| nucl_num |] ~data:charges);
Ezfio.set_nuclei_nucl_coord (Ezfio.ezfio_array_of_list
~rank:2 ~dim:[| nucl_num ; 3 |] ~data:coords);
(* Write Basis set *)
2014-09-17 23:47:13 +02:00
let basis =
2014-10-30 16:26:31 +01:00
let nmax = Nucl_number.get_max () in
2014-10-23 14:42:14 +02:00
let rec do_work (accu:(Atom.t*Nucl_number.t) list) (n:int) = function
2014-09-17 23:47:13 +02:00
| [] -> accu
| e::tail ->
let new_accu = (e,(Nucl_number.of_int ~max:nmax n))::accu in
2014-09-17 23:47:13 +02:00
do_work new_accu (n+1) tail
in
let result = do_work [] 1 nuclei
2014-09-17 23:47:13 +02:00
|> List.rev
|> List.map ~f:(fun (x,i) ->
try
2014-11-16 18:05:04 +01:00
Basis.read_element (basis_channel x.Atom.element) i x.Atom.element
with
| End_of_file ->
begin
2014-11-16 18:05:04 +01:00
let alt_channel = basis_channel x.Atom.element in
2015-01-12 16:58:22 +01:00
try
Basis.read_element alt_channel i x.Atom.element
with
End_of_file -> failwith
("Element "^(Element.to_string x.Atom.element)^" not found")
end
)
2014-09-17 23:47:13 +02:00
|> List.concat
in
(* close all in_channels *)
result
2014-09-17 23:47:13 +02:00
in
let long_basis = Long_basis.of_basis basis in
let ao_num = List.length long_basis in
Ezfio.set_ao_basis_ao_num ao_num;
Ezfio.set_ao_basis_ao_basis b;
2014-09-17 23:47:13 +02:00
let ao_prim_num = List.map long_basis ~f:(fun (_,g,_) -> List.length g.Gto.lc)
2014-10-23 14:42:14 +02:00
and ao_nucl = List.map long_basis ~f:(fun (_,_,n) -> Nucl_number.to_int n)
2014-09-18 17:01:43 +02:00
and ao_power=
let l = List.map long_basis ~f:(fun (x,_,_) -> x) in
(List.map l ~f:(fun t -> Positive_int.to_int Symmetry.Xyz.(t.x)) )@
(List.map l ~f:(fun t -> Positive_int.to_int Symmetry.Xyz.(t.y)) )@
(List.map l ~f:(fun t -> Positive_int.to_int Symmetry.Xyz.(t.z)) )
in
let ao_prim_num_max = List.fold ~init:0 ~f:(fun s x ->
if x > s then x
else s) ao_prim_num
in
let gtos = List.map long_basis ~f:(fun (_,x,_) -> x) in
let create_expo_coef ec =
let coefs =
begin match ec with
| `Coefs -> List.map gtos ~f:(fun x->
List.map x.Gto.lc ~f:(fun (_,coef) -> AO_coef.to_float coef) )
| `Expos -> List.map gtos ~f:(fun x->
2014-10-23 14:42:14 +02:00
List.map x.Gto.lc ~f:(fun (prim,_) -> AO_expo.to_float
2014-09-18 17:01:43 +02:00
prim.Primitive.expo) )
end
in
let rec get_n n accu = function
| [] -> List.rev accu
| h::tail ->
let y =
begin match List.nth h n with
| Some x -> x
| None -> 0.
end
in
get_n n (y::accu) tail
in
let rec build accu = function
| n when n=ao_prim_num_max -> accu
| n -> build ( accu @ (get_n n [] coefs) ) (n+1)
in
build [] 0
in
let ao_coef = create_expo_coef `Coefs
and ao_expo = create_expo_coef `Expos
2014-09-17 23:47:13 +02:00
in
Ezfio.set_ao_basis_ao_prim_num (Ezfio.ezfio_array_of_list
~rank:1 ~dim:[| ao_num |] ~data:ao_prim_num) ;
Ezfio.set_ao_basis_ao_nucl(Ezfio.ezfio_array_of_list
~rank:1 ~dim:[| ao_num |] ~data:ao_nucl) ;
2014-09-18 17:01:43 +02:00
Ezfio.set_ao_basis_ao_power(Ezfio.ezfio_array_of_list
~rank:2 ~dim:[| ao_num ; 3 |] ~data:ao_power) ;
Ezfio.set_ao_basis_ao_coef(Ezfio.ezfio_array_of_list
~rank:2 ~dim:[| ao_num ; ao_prim_num_max |] ~data:ao_coef) ;
Ezfio.set_ao_basis_ao_expo(Ezfio.ezfio_array_of_list
~rank:2 ~dim:[| ao_num ; ao_prim_num_max |] ~data:ao_expo) ;
2015-01-06 19:12:17 +01:00
2015-05-02 14:50:23 +02:00
(* Doesn't work... *)
2015-05-04 20:19:59 +02:00
if (p) then
begin
Qpackage.root ^ "/scripts/pseudo/put_pseudo_in_ezfio.py " ^ ezfio_file
|> Sys.command_exn
end;
2015-05-02 14:50:23 +02:00
2015-01-06 19:12:17 +01:00
match Input.Ao_basis.read () with
| None -> failwith "Error in basis"
| Some x -> Input.Ao_basis.write x
2014-08-27 16:38:13 +02:00
;;
let command =
Command.basic
~summary: "Quantum Package command"
2014-11-16 18:05:04 +01:00
~readme:(fun () -> "
Creates an EZFIO directory from a standard xyz file.
The basis set is defined as a single string if all the
atoms are taken from the same basis set, otherwise specific
elements can be defined as follows:
2015-01-12 16:58:22 +01:00
-b \"cc-pcvdz | H:cc-pvdz | C:6-31g\"
2014-11-16 18:05:04 +01:00
2014-08-27 16:38:13 +02:00
")
spec
2015-05-02 14:50:23 +02:00
(fun o b c m p xyz_file () ->
run ?o b c m p xyz_file )
2014-08-27 16:38:13 +02:00
;;
let () =
Command.run command
;;