facebookresearch / InterHand2.6M
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 98 units with 1,297 lines of code in units (76.2% of code).
    • 0 very complex units (0 lines of code)
    • 1 complex units (99 lines of code)
    • 4 medium complex units (238 lines of code)
    • 14 simple units (334 lines of code)
    • 79 very simple units (626 lines of code)
0% | 7% | 18% | 25% | 48%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
py0% | 7% | 18% | 25% | 48%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
data/InterHand2.6M0% | 50% | 36% | 0% | 13%
data/RHD0% | 0% | 42% | 40% | 17%
data/STB0% | 0% | 43% | 38% | 18%
common/utils0% | 0% | 17% | 19% | 62%
common/nets0% | 0% | 0% | 40% | 60%
main0% | 0% | 0% | 42% | 57%
common0% | 0% | 0% | 9% | 90%
tool/MANO_world_to_camera0% | 0% | 0% | 0% | 100%
tool/MANO_render0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
def evaluate()
in data/InterHand2.6M/dataset.py
99 30 2
def get_keypoint_rgb()
in common/utils/vis.py
49 23 1
def evaluate()
in data/STB/dataset.py
59 17 2
def evaluate()
in data/RHD/dataset.py
59 17 2
def __init__()
in data/InterHand2.6M/dataset.py
71 14 3
def vis_keypoints()
in common/utils/vis.py
20 9 9
def vis_3d_keypoints()
in common/utils/vis.py
18 8 7
def __init__()
in data/RHD/dataset.py
56 8 3
def load_skeleton()
in common/utils/preprocessing.py
17 7 2
def make_conv_layers()
in common/nets/layer.py
15 7 5
def make_deconv_layers()
in common/nets/layer.py
16 7 2
def make_upsample_layers()
in common/nets/layer.py
17 7 2
def make_conv3d_layers()
in common/nets/layer.py
15 7 5
def make_deconv3d_layers()
in common/nets/layer.py
16 7 2
def set_lr()
in common/base.py
13 7 2
def forward()
in main/model.py
34 7 5
def main()
in main/train.py
37 7 0
def __init__()
in data/STB/dataset.py
53 7 3
def make_linear_layers()
in common/nets/layer.py
7 6 2
def flip()
in common/utils/transforms.py
13 5 2