Skip to content

Commit ab15992

Browse files
committed
Don't log species to calc if thermo shouldn't be computed for them
1 parent 81dd414 commit ab15992

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

t3/logger.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -177,11 +177,8 @@ def log_species_to_calculate(self,
177177
Args:
178178
species_keys (List[int]): Entries are T3 species indices.
179179
species_dict (dict): The T3 species dictionary.
180-
181-
Todo:
182-
Log the reasons one by one with line breaks and enumerate
183180
"""
184-
if len(species_keys):
181+
if len(species_keys) and any(spc_dict['compute_thermo'] for spc_dict in species_dict.values()):
185182
self.info('\n\nSpecies to calculate thermodynamic data for:')
186183
max_label_length = max([len(spc_dict['QM label'])
187184
for key, spc_dict in species_dict.items() if key in species_keys])
@@ -193,6 +190,8 @@ def log_species_to_calculate(self,
193190
self.info(f'-----{space1} ------{space2} -----------------------------')
194191
for key in species_keys:
195192
spc_dict = species_dict[key]
193+
if not spc_dict['compute_thermo']:
194+
continue
196195
smiles = spc_dict['object'].molecule[0].to_smiles()
197196
space1 = ' ' * (max_label_length - len(spc_dict['QM label']) + 1)
198197
space2 = ' ' * (max_smiles_length - len(smiles) + 1)

0 commit comments

Comments
 (0)