aws-samples / rekognition-distance-calculation
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 7 units with 93 lines of code in units (37.3% of code).
    • 0 very long units (0 lines of code)
    • 1 long units (52 lines of code)
    • 0 medium size units (0 lines of code)
    • 1 small units (14 lines of code)
    • 5 very small units (27 lines of code)
0% | 55% | 0% | 15% | 29%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 55% | 0% | 15% | 29%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
process_distance0% | 76% | 0% | 0% | 23%
lambda_sns_notify0% | 0% | 0% | 56% | 44%
Alternative Visuals
Longest Units
Top 7 longest units
Unit# linesMcCabe index# params
def detect_person_label()
in process_distance/lambda_function.py
52 8 3
def lambda_handler()
in lambda_sns_notify/lambda_function.py
14 2 2
def publish_to_sns()
in lambda_sns_notify/lambda_function.py
8 1 3
def upload_image_to_s3()
in process_distance/lambda_function.py
7 1 2
def lambda_handler()
in process_distance/lambda_function.py
6 1 2
def calculateDistance()
in process_distance/lambda_function.py
3 1 4
def connect_to_aws()
in lambda_sns_notify/lambda_function.py
3 1 2