aws-samples / amazon-rekognition-ppe
Unit Size

The distribution of size of units (measured in lines of code).

Intro
  • Unit size measurements show the distribution of size of units of code (methods, functions...).
  • Units are classified in four categories based on their size (lines of code): 1-20 (small units), 20-50 (medium size units), 51-100 (long units), 101+ (very long units).
  • You should aim at keeping units small (< 20 lines). Long units may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
Unit Size Overall
  • There are 15 units with 110 lines of code in units (49.3% of code).
    • 0 very long units (0 lines of code)
    • 0 long units (0 lines of code)
    • 1 medium size units (27 lines of code)
    • 2 small units (35 lines of code)
    • 12 very small units (48 lines of code)
0% | 0% | 24% | 31% | 43%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 0% | 24% | 31% | 43%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
stored-video0% | 0% | 100% | 0% | 0%
frame-extraction0% | 0% | 0% | 29% | 70%
stream-processing0% | 0% | 0% | 100% | 0%
Alternative Visuals
Longest Units
Top 15 longest units
Unit# linesMcCabe index# params
def analyzeVideo()
in stored-video/frame_analysis.py
27 6 0
def pushFrame()
in frame-extraction/fextractor.py
20 4 1
def processFrame()
in stream-processing/ppe-stream.py
15 3 1
def run()
in frame-extraction/fextractor.py
9 3 1
def getCameras()
in frame-extraction/fextractor.py
9 2 0
def __init__()
in frame-extraction/fextractor.py
7 1 2
def start()
in frame-extraction/fextractor.py
6 3 0
def __init__()
in frame-extraction/fextractor.py
3 1 2
def area()
in frame-extraction/fextractor.py
2 1 1
def subarea()
in frame-extraction/fextractor.py
2 1 1
def videoStreamUrl()
in frame-extraction/fextractor.py
2 1 1
def s3Bucket()
in frame-extraction/fextractor.py
2 1 1
def isFisheye()
in frame-extraction/fextractor.py
2 1 1
def frameCaptureThreshold()
in frame-extraction/fextractor.py
2 1 1
def cameraSettings()
in frame-extraction/fextractor.py
2 1 1