aws-samples / amazon-rekognition-video-analyzer
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 646 units with 9,349 lines of code in units (82.1% of code).
    • 1 very complex units (825 lines of code)
    • 4 complex units (306 lines of code)
    • 49 medium complex units (2,105 lines of code)
    • 96 simple units (2,159 lines of code)
    • 496 very simple units (3,954 lines of code)
8% | 3% | 22% | 23% | 42%
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
js9% | 3% | 22% | 23% | 41%
py0% | 0% | 16% | 22% | 60%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
web-ui/src/js9% | 3% | 22% | 23% | 40%
lambda/imageprocessor0% | 0% | 87% | 0% | 12%
ROOT0% | 0% | 0% | 16% | 83%
client0% | 0% | 0% | 42% | 57%
lambda/framefetcher0% | 0% | 0% | 61% | 38%
web-ui/src0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
(function (global, factory)()
in web-ui/src/js/vue.js
825 91 2
function()
in web-ui/src/js/axios.js
117 42 3
function parseFilters()
in web-ui/src/js/vue.js
66 38 1
function enter()
in web-ui/src/js/vue.js
81 32 2
function patchVnode()
in web-ui/src/js/vue.js
42 27 4
function utf8Slice()
in web-ui/src/js/axios.js
66 24 3
render: function render()
in web-ui/src/js/vue.js
59 24 1
def process_image()
in lambda/imageprocessor/imageprocessor.py
101 24 2
function byteLength()
in web-ui/src/js/axios.js
40 22 2
function slowToString()
in web-ui/src/js/axios.js
46 22 3
function utf8ToBytes()
in web-ui/src/js/axios.js
60 22 2
function updateChildren()
in web-ui/src/js/vue.js
67 21 5
function hydrate()
in web-ui/src/js/vue.js
56 21 3
start: function start()
in web-ui/src/js/vue.js
44 21 3
function addHandler()
in web-ui/src/js/vue.js
46 20 6
function handleStartTag()
in web-ui/src/js/vue.js
38 20 1
function parseEndTag()
in web-ui/src/js/vue.js
44 20 3
56 20 2
function bidirectionalIndexOf()
in web-ui/src/js/axios.js
44 19 5
chars: function chars()
in web-ui/src/js/vue.js
40 19 1