diff --git a/actions/ost-compare-ligand-structures b/actions/ost-compare-ligand-structures index ee7575218cf7638617f91c89a07870463f1fcb7f..abe20e8495e945042dfd6d6f8d2e141bc519a367 100644 --- a/actions/ost-compare-ligand-structures +++ b/actions/ost-compare-ligand-structures @@ -60,8 +60,6 @@ import ost from ost import conop from ost import io from ost.mol.alg import ligand_scoring -from ost.mol.alg import Molck, MolckSettings - def _ParseArgs(): @@ -234,8 +232,6 @@ def _LoadStructure(structure_path, format="auto", fault_tolerant=False): f"{structure_path}.") format = ext[-1].lower() - # increase loglevel, as we would pollute the info log with weird stuff - ost.PushVerbosityLevel(ost.LogLevel.Error) # Load the structure if format in ["mmcif", "cif"]: entity, seqres = io.LoadMMCIF(structure_path, seqres=True, @@ -250,22 +246,11 @@ def _LoadStructure(structure_path, format="auto", fault_tolerant=False): raise Exception(f"Unknown/ unsupported file extension found for " f"file {structure_path}.") - # Molck it - molck_settings = MolckSettings(rm_unk_atoms=True, - rm_non_std=False, - rm_hyd_atoms=True, - rm_oxt_atoms=False, - rm_zero_occ_atoms=False, - colored=False, - map_nonstd_res=False, - assign_elem=True) - # Cleanup a copy of the structures - Molck(entity, conop.GetDefaultLib(), molck_settings) - - # restore old loglevel and return - ost.PopVerbosityLevel() - entity.SetName(structure_path) - return entity + # Remove hydrogens + cleaned_entity = ost.mol.CreateEntityFromView(entity.Select("ele != H"), + include_exlusive_atoms=False) + cleaned_entity.SetName(structure_path) + return cleaned_entity def _LoadLigands(ligands):