aws-samples / aim317-uncover-insights-customer-conversations
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 12 units with 381 lines of code in units (41.5% of code).
    • 0 very long units (0 lines of code)
    • 1 long units (53 lines of code)
    • 10 medium size units (309 lines of code)
    • 1 small units (19 lines of code)
    • 0 very small units (0 lines of code)
0% | 13% | 81% | 4% | 0%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 13% | 81% | 4% | 0%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
src0% | 13% | 81% | 4% | 0%
Alternative Visuals
Longest Units
Top 12 longest units
Unit# linesMcCabe index# params
def lambda_handler()
in src/translateText.py
53 7 2
def lambda_handler()
in src/buildTrainTest.py
43 1 2
def lambda_handler()
in src/createVocabulary.py
35 3 2
def lambda_handler()
in src/createEntityRecognizer.py
35 1 2
def lambda_handler()
in src/detectEntities.py
35 7 2
def lambda_handler()
in src/classifyDocument.py
33 6 2
def lambda_handler()
in src/createEndpoint.py
32 5 2
def lambda_handler()
in src/startTranscriptionJob.py
31 3 2
def lambda_handler()
in src/createDocumentClassifier.py
22 1 2
def lambda_handler()
in src/importTerminology.py
22 1 2
def lambda_handler()
in src/startSentimentDetection.py
21 3 2
def lambda_handler()
in src/paginateProcessDataTrainTestFiles.py
19 1 2