Showing 113 of 113 total issues
Function call
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
def call(func):
"""
Decorator for the calculator call method.
This decorator provides a unified approach for handling run_computation and
- 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 run_calculator
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
def run_calculator(self):
"""
Run analysis.
Returns
- 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 get_dimensionality
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
def get_dimensionality(box: list) -> int:
"""
Calculate the dimensionality of the experiment box.
Parameters
- 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 run_calculator
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
def run_calculator(self):
"""Run analysis."""
self._run_dependency_check()
for species in self.args.species:
# Here for now to avoid issues. Should be moved out when calculators become
- 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 _get_box_l
has a Cognitive Complexity of 11 (exceeds 5 allowed). Consider refactoring. Open
def _get_box_l(header: str) -> list:
"""
Get the box lengths from the Lattice property in the header.
Parameters
- 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 __call__
has 10 arguments (exceeds 4 allowed). Consider refactoring. Open
def __call__(
Function golden_section_search
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def golden_section_search(
Function __call__
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def __call__(
Function add_experiment
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def add_experiment(
Function golden_section_search
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
def golden_section_search(
data: np.array,
a: float,
b: float,
tol: float = 1e-5,
- 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 ensemble_generator
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
def ensemble_generator(self, system: bool = False, glob_data: dict = None) -> tuple:
"""
Build a generator for the ensemble loop.
Parameters
- 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 _get_property_to_column_idx_dict
has a Cognitive Complexity of 10 (exceeds 5 allowed). Consider refactoring. Open
def _get_property_to_column_idx_dict(
header: str, var_names: dict
) -> typing.Tuple[int, typing.Dict[str, typing.List[int]]]:
"""
Get the property summary from the header data.
- 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 __call__
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
def __call__(
Function __call__
has 8 arguments (exceeds 4 allowed). Consider refactoring. Open
def __call__(
Function check_input
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
def check_input(self):
"""
Check the input of the call method and store defaults if needed.
Returns
- 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 extract_properties_from_header
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
def extract_properties_from_header(
header_property_names: list, database_correspondence_dict: dict
) -> dict:
"""
Takes the property names from a file header, sees if there is a corresponding
- 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 _get_metadata
has a Cognitive Complexity of 9 (exceeds 5 allowed). Consider refactoring. Open
def _get_metadata(self) -> TrajectoryMetadata:
"""Get the necessary metadata out of chemfiles.
Trajectory and the first chemfiles.Frame
"""
- 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 __init__
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
def __init__(
Function __init__
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
def __init__(
Function bin_minibatch
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
def bin_minibatch(