Skip to content

Commit

Permalink
Merge pull request #1 from xchem/logging
Browse files Browse the repository at this point in the history
Logging
  • Loading branch information
ConorFWild authored Nov 23, 2023
2 parents 286481f + e8174fb commit 9a68494
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/ligand_neighbourhood_alignment/cli.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import json
import os
import sys

# import os
import subprocess
Expand All @@ -12,6 +13,8 @@
import pandas as pd
import yaml
from loguru import logger
logger.remove() # for someone not familiar with the lib, whats going on here?
logger.add(sys.stdout, level="INFO")
from rich import print

from ligand_neighbourhood_alignment import constants
Expand Down Expand Up @@ -618,7 +621,6 @@ def _save_neighbourhoods(
dic["/".join(ligand_id)] = neighbourhood.to_dict()
yaml.safe_dump(dic, f)


def _save_ligand_neighbourhood_transforms(fs_model, ligand_neighbourhood_transforms):
with open(fs_model.ligand_neighbourhood_transforms, 'w') as f:
dic = {}
Expand Down Expand Up @@ -1220,7 +1222,7 @@ def _update(
# logger.info(datasets[dtag].ligand_binding_events[(dtag, chain, residue)].dtag)
# logger.info(datasets[dtag].ligand_binding_events[(dtag, chain, residue)].chain)
# logger.info(datasets[dtag].ligand_binding_events[(dtag, chain, residue)].residue) # *
if xmap_path != "None":
if (xmap_path != "None") and (xmap_path is not None):
xmap = read_xmap(xmap_path)

__align_xmap(
Expand Down
3 changes: 3 additions & 0 deletions src/ligand_neighbourhood_alignment/dt.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,13 @@
import os
import re
from pathlib import Path
import sys

import pandas as pd
import yaml
from loguru import logger
logger.remove() # for someone not familiar with the lib, whats going on here?
logger.add(sys.stdout, level="INFO")

from ligand_neighbourhood_alignment import constants
from ligand_neighbourhood_alignment.make_data_json import (
Expand Down

0 comments on commit 9a68494

Please sign in to comment.