Showing 376 of 433 total issues
Function forward
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def forward(
Function __init__
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function plot_data
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def plot_data(
Function forward
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def forward(
Function forward
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def forward(self, q, k, v, mask=None, input_mask=None, attn_bias=None, window_size=None):
Function __init__
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(self, seq_len, pred_len, top_k, d_model, d_ffn, num_kernels):
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(self, k, alpha, c=1, nl=1, initializer=None, **kwargs):
Function _update_context
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def _update_context(self, context_in, V, scores, index, L_Q, attn_mask):
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function sample_factor_u
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def sample_factor_u(tau_sparse_tensor, tau_ind, U, V, X, beta0=1):
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(self, B, H, L, index, scores, device="cpu"):
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function __init__
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def __init__(
Function _BTTF
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
Open
def _BTTF(
dense_tensor,
sparse_tensor,
init,
rank,
- 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"