Function posthoc_refine
has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring. Open
def posthoc_refine(self,
scaffold: Chem.Mol,
indices: Optional[List[int]] = None) -> Chem.Mol:
"""
Given a scaffold and a list of indices, refine the scaffold.
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function propagate_alternatives
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def propagate_alternatives(self, fewer: List[Chem.Mol]) -> int:
"""
Given the alt atoms strored in the Chem.Atom property ``_AltSymbol`` try those
"""
pt = Chem.GetPeriodicTable()
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function sample_new_conformation
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def sample_new_conformation(self, random_seed=None):
"""This method is intended for Multivictor.
It generates a new conformation based on different random seeds.
"""
scaffold = self.modifications["chimera"]
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"