facebook / FAI-PEP
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 641 units with 8,606 lines of code in units (70.1% of code).
    • 1 very complex units (306 lines of code)
    • 4 complex units (422 lines of code)
    • 37 medium complex units (1,703 lines of code)
    • 86 simple units (2,193 lines of code)
    • 513 very simple units (3,982 lines of code)
3% | 4% | 19% | 25% | 46%
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
py3% | 4% | 19% | 25% | 46%
js0% | 0% | 0% | 0% | 100%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
benchmarking/frameworks24% | 0% | 20% | 30% | 23%
ailab/benchmark0% | 54% | 17% | 0% | 28%
benchmarking0% | 7% | 29% | 25% | 37%
benchmarking/utils0% | 5% | 20% | 22% | 50%
benchmarking/platforms0% | 0% | 19% | 23% | 56%
libraries/python0% | 0% | 12% | 23% | 63%
benchmarking/remote0% | 0% | 22% | 15% | 62%
benchmarking/data_converters0% | 0% | 45% | 26% | 28%
benchmarking/reporters0% | 0% | 19% | 44% | 36%
benchmarking/download_benchmarks0% | 0% | 26% | 40% | 33%
benchmarking/driver0% | 0% | 12% | 52% | 34%
benchmarking/regression_detectors0% | 0% | 17% | 13% | 68%
benchmarking/benchmarks0% | 0% | 9% | 52% | 38%
benchmarking/profilers0% | 0% | 0% | 39% | 60%
specifications/models0% | 0% | 0% | 56% | 43%
benchmarking/bridge0% | 0% | 0% | 0% | 100%
benchmarking/repos0% | 0% | 0% | 0% | 100%
benchmarking/degrade0% | 0% | 0% | 0% | 100%
ailab/file_storage0% | 0% | 0% | 0% | 100%
ailab/ailab0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 50 most complex units
Unit# linesMcCabe index# params
306 74 4
123 37 1
112 29 1
127 28 1
60 27 2
53 23 1
105 20 1
47 19 4
47 19 2
62 18 4
53 18 4
93 18 4
37 18 2
59 17 2
32 15 6
37 15 2
83 15 4
88 15 3
25 14 3
34 14 2
23 14 4
53 14 3
50 14 3
35 14 5
53 13 4
42 13 2
43 13 2
35 13 2
31 13 2
45 12 3
37 12 1
26 12 1
28 12 3
31 12 1
24 12 2
43 12 2
42 11 1
41 11 1
48 11 1
37 11 3
55 11 1
26 11 2
19 10 2
26 10 3
20 10 2
35 10 6
23 10 1
30 10 2
26 10 2
20 10 2