Showing 14 of 14 total issues
Function rrc3d
has a Cognitive Complexity of 28 (exceeds 5 allowed). Consider refactoring. Open
def rrc3d(
c3d_file: str,
show_floor: bool = True,
show_force_plates: bool = True,
show_forces: bool = True,
- 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
BiorbdModelNoMesh
has 23 functions (exceeds 20 allowed). Consider refactoring. Open
class BiorbdModelNoMesh:
"""
A class to handle a biorbd model and its transformations
"""
Function read_vtp_file
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
def read_vtp_file(filename: str) -> dict:
"""
Reads a VTP file and extracts the mesh data.
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 rerun
has a Cognitive Complexity of 14 (exceeds 5 allowed). Consider refactoring. Open
def rerun(
self, name: str = "animation_phase", init: bool = True, clear_last_node: bool = False, notebook: bool = False
) -> None:
if self.nb_phases == 1:
self.phase_reruns[0].rerun(name, init, clear_last_node, notebook)
- 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 rrc3d
has 10 arguments (exceeds 4 allowed). Consider refactoring. Open
def rrc3d(
Function add_q
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def add_q(
Function crop_video
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def crop_video(
Function add_animated_model
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def add_animated_model(
Function add_force_data
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def add_force_data(
Function add_q
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def add_q(
Function rerun
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def rerun(
Function add_floor
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
def add_floor(
Function frame_t_span_idx
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def frame_t_span_idx(self) -> list[list[int]]:
"""
Get the index of the time spans for each frame.
"""
frame_t_span_idx = []
- 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 to_rerun
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def to_rerun(self, frame: int) -> None:
if self.properties.ranges is None:
for joint_idx in range(self.nb_q):
name = f"{self.properties.displayed_joint_names[joint_idx]}"
rr.log(
- 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"