Closed manonreau closed 3 years ago
I'm afraid one test is failing :(
I'm afraid one test is failing :(
This is the test that checks if an error is raised if 2 interfaces are not strictly identical. Pretty logical !
Well I'm thinking those tests were here for a reason. We do use pdb2sql in a few projects so I don't really want to modify the default behavior of the methods. What we could do is to make the error raising optional. For example with a keyword argument of the routines or an attribute of the class.
Class StructureSimilarity(self, decoy, ref, verbose=False, enforce_residue_matching=True):
...
self.enforce_residue_matching = enfore_residue_matching
and in the methods
if self.enforce_residue_mathcing:
raise ValueError(....)
That way you can in your case turn the residue matching option off but the default behaviour doesn't change. Of course we introduce one argument in a bit of a adhoc fashion but I would prefer that at the moment
now:
self.enforce_residue_matching == True
: an error is raised if the residues from the ref differ from those of the decoy (no matter the value of check
)check == True
: checks if residues ref == residues decoys, if not, raises an error (self.enforce_residue_matching == True
) or a warning (self.enforce_residue_matching == False
)I would delete the check
, is that dangerous ?
Computes the irmsd and lrmsd despite missing atoms/residues at the interface. A warning is raised instead of an error.