diff --git a/src/trexio_tools/converters/convert_from.py b/src/trexio_tools/converters/convert_from.py index 023172d..5ec4e9d 100644 --- a/src/trexio_tools/converters/convert_from.py +++ b/src/trexio_tools/converters/convert_from.py @@ -201,6 +201,9 @@ def run_resultsFile(trexio_file, filename, motype=None): trexio.write_basis_coefficient(trexio_file,coefficient) trexio.write_basis_prim_factor(trexio_file,prim_factor) + # For Gaussian basis sets, basis_r_power is zero + basis_r_power = [0.0 for _ in range(shell_num) ] + trexio.write_basis_r_power(trexio_file,basis_r_power) # AO # -- @@ -650,6 +653,10 @@ def run_molden(trexio_file, filename, normalized_basis=True, multiplicity=None, # write normalization factor for each shell trexio.write_basis_shell_factor(trexio_file,shell_factor) + # For Gaussian basis sets, basis_r_power is zero + basis_r_power = [0.0 for _ in range(basis_shell_num) ] + trexio.write_basis_r_power(trexio_file,basis_r_power) + # write parameters of the primitives trexio.write_basis_exponent(trexio_file,exponent) trexio.write_basis_coefficient(trexio_file,coefficient) diff --git a/src/trexio_tools/converters/convert_to.py b/src/trexio_tools/converters/convert_to.py index 1644144..28568b3 100755 --- a/src/trexio_tools/converters/convert_to.py +++ b/src/trexio_tools/converters/convert_to.py @@ -272,6 +272,12 @@ def run_molden(t, filename): coefficient = trexio.read_basis_coefficient(t) prim_factor = trexio.read_basis_prim_factor(t) + # For Gaussian basis sets, basis_r_power is zero by default + if trexio.has_basis_r_power(t): + basis_r_power = trexio.read_basis_r_power(t) + else: + basis_r_power = [0.0 for _ in range(basis_shell_num) ] + contr = [ { "exponent" : [], "coefficient" : [], "prim_factor" : [] } for _ in range(shell_num) ] @@ -463,7 +469,7 @@ def run_cart_phe(inp, filename, to_cartesian): normalization = np.array( [ 1. ] * ao_num_in ) if trexio.has_ao_normalization(inp): normalization = trexio.read_ao_normalization(inp) - + trexio.write_ao_normalization(out, cart_normalization) """ diff --git a/src/trexio_tools/converters/orca_to_trexio.py b/src/trexio_tools/converters/orca_to_trexio.py index 6a37ec5..3d16ebb 100644 --- a/src/trexio_tools/converters/orca_to_trexio.py +++ b/src/trexio_tools/converters/orca_to_trexio.py @@ -136,7 +136,7 @@ def orca_to_trexio( dict_ang_mom['h'] = 5 dict_ang_mom['i'] = 6 - basis_type = "Gaussian" # thanks anthony! + basis_type = "Gaussian" basis_shell_num = int(np.sum([atom_nshells[i] for i in range(nucleus_num)])) nucleus_index = [] for i in range(nucleus_num):