awslabs / damo
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 125 units with 1,876 lines of code in units (89.0% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 12 medium complex units (537 lines of code)
    • 27 simple units (641 lines of code)
    • 86 very simple units (698 lines of code)
0% | 0% | 28% | 34% | 37%
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% | 0% | 28% | 34% | 37%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
ROOT0% | 0% | 28% | 34% | 37%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
def record_to_damon_result()
in _damon_result.py
53 15 4
52 15 3
def main()
in monitor.py
56 14 1
def debugfs_scheme()
in _convert_damos.py
78 13 4
def main()
in nr_regions.py
46 13 1
47 12 5
32 12 1
34 12 0
def run_damon()
in schemes.py
28 12 5
def main()
in heats.py
27 11 1
def do_record()
in record.py
37 11 6
def main()
in record.py
47 11 1
def main()
in bin2txt.py
50 10 1
32 10 4
def cleanup_exit()
in record.py
30 10 2
def main()
in schemes.py
46 10 1
def main()
in features.py
14 9 1
16 9 2
25 9 1
def main()
in validate.py
28 9 1