From 2a2035aa5695dcaa83f29b09cfbcf11845a792c5 Mon Sep 17 00:00:00 2001 From: RagnarB83 Date: Fri, 13 Sep 2024 14:54:05 +0200 Subject: [PATCH] cleanup: QM/MM linkatom printing --- ash/modules/module_QMMM.py | 4 ++-- ash/modules/module_coords.py | 10 +++++++--- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/ash/modules/module_QMMM.py b/ash/modules/module_QMMM.py index 170ece16a..021d8208e 100644 --- a/ash/modules/module_QMMM.py +++ b/ash/modules/module_QMMM.py @@ -1259,8 +1259,8 @@ def elstat_run(self, current_coords=None, elems=None, Grad=False, numcores=1, ex else: print("Unknown linkatom_forceproj_method. Exiting") ashexit() - print("QM1grad contrib:", QM1grad_contrib) - print("MM1grad contrib:", MM1grad_contrib) + #print("QM1grad contrib:", QM1grad_contrib) + #print("MM1grad contrib:", MM1grad_contrib) self.QM_PC_gradient[fullatomindex_qm] = QM1grad_contrib self.QM_PC_gradient[fullatomindex_mm] = MM1grad_contrib diff --git a/ash/modules/module_coords.py b/ash/modules/module_coords.py index b6569699e..29b5a0df6 100644 --- a/ash/modules/module_coords.py +++ b/ash/modules/module_coords.py @@ -3117,9 +3117,13 @@ def get_linkatom_positions(qm_mm_boundary_dict, qmatoms, coords, elems, linkatom print("Inside get_linkatom_positions") print("linkatom_method:", linkatom_method) + if linkatom_simple_distance is None: + print("linkatom_simple_distance not set. Getting standard distance from dictionary for each element:") + else: + print("linkatom_simple_distance was set by user:", linkatom_simple_distance) #Dict of linkatom distances for different elements linkdistances_dict = {('C', 'H'): 1.09, ('O', 'H'): 0.98, ('N', 'H'): 0.99} - + print("Linkdatom distance dictionary:", linkdistances_dict) # If dictionary of linkatom-distances provided then use that instead if linkatom_method == 'ratio': if linkatom_ratio == 'Auto' and bondpairs_eq_dict is None: @@ -3161,11 +3165,11 @@ def get_linkatom_positions(qm_mm_boundary_dict, qmatoms, coords, elems, linkatom elif linkatom_method == 'simple': print("Linkatom method: simple") if linkatom_simple_distance is None: - print("linkatom_simple_distance not set. Getting standard distance from dictionary for element:", elems[dict_item[0]]) + #print("linkatom_simple_distance not set. Getting standard distance from dictionary for element:", elems[dict_item[0]]) #Getting from dict linkatom_distance = linkdistances_dict[(elems[dict_item[0]], 'H')] else: - print("linkatom_simple_distance was set by user:", linkatom_simple_distance) + #print("linkatom_simple_distance was set by user:", linkatom_simple_distance) #Getting from user linkatom_distance = linkatom_simple_distance print("Linkatom distance (QM1-L) is:", linkatom_distance)