aws-solutions / media2cloud
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 1,649 units with 17,702 lines of code in units (56.0% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 25 medium complex units (1,026 lines of code)
    • 102 simple units (3,142 lines of code)
    • 1,522 very simple units (13,534 lines of code)
0% | 0% | 5% | 17% | 76%
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
js0% | 0% | 5% | 17% | 76%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
source/analysis-monitor0% | 0% | 31% | 17% | 51%
source/api0% | 0% | 15% | 28% | 55%
source/webapp0% | 0% | 2% | 13% | 83%
source/layers0% | 0% | 9% | 8% | 82%
source/ingest0% | 0% | 4% | 34% | 60%
source/custom-resources0% | 0% | 3% | 13% | 83%
source/s3event0% | 0% | 24% | 31% | 44%
source/video-analysis0% | 0% | 4% | 17% | 77%
source/error-handler0% | 0% | 52% | 0% | 47%
source/audio-analysis0% | 0% | 0% | 36% | 63%
source/gt-labeling0% | 0% | 0% | 37% | 62%
source/document-analysis0% | 0% | 0% | 28% | 71%
source/image-analysis0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
async readFromJsonFile()
in source/s3event/lib/index.js
42 25 2
async onPOST()
in source/api/lib/operations/assetOp.js
50 19 0
toggleTrack()
in source/webapp/src/lib/js/imagePreview.js
82 18 2
async startAnalysis()
in source/analysis-monitor/lib/index.js
51 17 0
async deleteResource()
in source/custom-resources/lib/groundTruth/workTeam.js
48 16 0
async getExecutionError()
in source/analysis-monitor/lib/index.js
41 16 1
validatePostRequest()
in source/api/lib/operations/editLabelOp.js
44 15 1
async checkRestoreStatus()
in source/ingest/lib/s3restore/index.js
34 14 0
async onPostQueuedFaces()
in source/api/lib/operations/faceCollectionOp.js
29 14 0
async startImageAnalysis()
in source/analysis-monitor/lib/index.js
29 14 2
async findMd5()
in source/ingest/lib/index.js
20 13 1
getProcessor()
in source/api/lib/apiRequest.js
26 13 0
domCreateMediaInfoData()
in source/webapp/src/lib/js/videoPreview.js
50 12 1
function parseExecutionError()
in source/error-handler/index.js
23 12 2
async onPostIndexedFaces()
in source/api/lib/operations/faceCollectionOp.js
26 12 0
createCollection()
in source/video-analysis/lib/rekognition/base.js
39 12 2
async update()
in source/layers/core-lib/lib/db.js
64 12 4
constructor()
in source/layers/core-lib/lib/faceCollection.js
43 12 2
async parseRekogImageOutput()
in source/analysis-monitor/lib/indexer/index.js
51 12 2
async onModify()
in source/webapp/src/lib/js/labelEditor.js
64 11 2