Skip to content

Commit

Permalink
LOGGER info added to SignInt functions
Browse files Browse the repository at this point in the history
  • Loading branch information
karolamik13 committed Nov 10, 2024
1 parent ca71719 commit f736b8a
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions prody/proteins/interactions.py
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ def remove_empty_strings(row):

def log_message(message, level="INFO"):
"""Log a message with a specified log level."""
print("[{}] {}".format(level, message))
LOGGER.info("[{}] {}".format(level, message))

def is_module_installed(module_name):
"""Check if a Python module is installed."""
Expand Down Expand Up @@ -3305,6 +3305,8 @@ def find_match_index(tar_nogap, nat_seq):
else:
fp.write("-")
fp.write("\n")

LOGGER.info("MSA file is now created, and saved as {}.".format(msa_output_name))


def extractMultiModelPDB(multimodelPDB, **kwargs):
Expand All @@ -3317,7 +3319,8 @@ def extractMultiModelPDB(multimodelPDB, **kwargs):
:arg folder_name: The name of the folder to which PDBs will be extracted
:type folder_name: str
"""

import os

folder_name = kwargs.pop('folder_name', 'struc_homologs')

with open(multimodelPDB, 'r') as f:
Expand Down Expand Up @@ -3345,6 +3348,8 @@ def extractMultiModelPDB(multimodelPDB, **kwargs):

if sig3 == 'ATOM' and fp:
fp.write("{}\n".format(line))

LOGGER.info("Individual models are saved in {}.".format(folder_name))


def calcSignatureInteractions(mapping_file, PDB_folder, fixer='pdbfixer'):
Expand All @@ -3360,6 +3365,7 @@ def calcSignatureInteractions(mapping_file, PDB_folder, fixer='pdbfixer'):
:arg fixer: The method for fixing lack of hydrogen bonds
:type fixer: 'pdbfixer' or 'openbabel'
"""
import os

functions = {
"HydrogenBonds": calcHydrogenBonds,
Expand Down

0 comments on commit f736b8a

Please sign in to comment.