Showing 17 of 17 total issues
Function __init__
has 23 arguments (exceeds 4 allowed). Consider refactoring. Open
def __init__(
Function rnn_model_func
has 19 arguments (exceeds 4 allowed). Consider refactoring. Open
def rnn_model_func(
Function run
has 14 arguments (exceeds 4 allowed). Consider refactoring. Open
def run(
Function __init__
has 11 arguments (exceeds 4 allowed). Consider refactoring. Open
def __init__(
Function __init__
has 30 lines of code (exceeds 25 allowed). Consider refactoring. Open
def __init__(
self,
n_categories: int = len(CATEGORY_COLS),
n_features: int = None,
n_steps: int = 2,
Function __init__
has 9 arguments (exceeds 4 allowed). Consider refactoring. Open
def __init__(
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def __init__(
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def __init__(
Function autodoc_process_docstring
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def autodoc_process_docstring(app, what, name, obj, options, lines):
Function skip
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def skip(app, what, name, obj, skip, options):
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def __init__(
Function _predict_with_team_model
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def _predict_with_team_model(
Function register_catalog
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def register_catalog(
Function score_model
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def score_model(
Function fit
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
def fit(self, X: pd.DataFrame, y: Union[pd.Series, np.ndarray]) -> Type[R]:
"""Fit estimator to the data."""
X_filtered, y_filtered = (
self._filter_by_min_year(X),
self._filter_by_min_year(y),
- 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 fit
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def fit(
self, X: pd.DataFrame, y: Optional[Union[pd.Series, np.ndarray]] = None
) -> Type[T]:
"""Calculate feature/label correlations and save high-correlation features."""
if not any(self.labels) and y is not None:
- 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 reload_kedro
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def reload_kedro(path, line=None):
"""Line magic which reloads all Kedro default variables."""
global startup_error
global context
global catalog
- 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"