awslabs / genomics-tertiary-analysis-and-machine-learning-using-amazon-sagemaker
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 47 units with 390 lines of code in units (23.5% of code).
    • 0 very long units (0 lines of code)
    • 0 long units (0 lines of code)
    • 5 medium size units (135 lines of code)
    • 7 small units (104 lines of code)
    • 35 very small units (151 lines of code)
0% | 0% | 34% | 26% | 38%
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% | 34% | 26% | 38%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
source/GenomicsLearningCode/setup/crhelper0% | 0% | 40% | 22% | 37%
source/GenomicsLearningCode/setup0% | 0% | 0% | 60% | 40%
source/GenomicsLearningCode/resources/scripts0% | 0% | 0% | 0% | 100%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def __init__()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
39 4 6
def format()
in source/GenomicsLearningCode/setup/crhelper/log_helper.py
25 8 2
def __call__()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
24 10 3
def _send_response()
in source/GenomicsLearningCode/setup/crhelper/utils.py
24 4 2
def _crhelper_init()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
23 4 3
def check_build_job_status()
in source/GenomicsLearningCode/setup/lambda.py
19 4 2
def _send()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
17 4 4
def _remove_polling()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
17 6 1
def _put_targets()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
16 1 2
def _polling_init()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
13 7 2
def setup()
in source/GenomicsLearningCode/setup/crhelper/log_helper.py
11 4 4
def start_build_job()
in source/GenomicsLearningCode/setup/lambda.py
11 1 3
def _add_permission()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
10 1 2
def __init__()
in source/GenomicsLearningCode/setup/crhelper/log_helper.py
10 1 2
def _cfn_response()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
8 5 2
def _wait_for_cwlogs()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
7 3 2
def _log_setup()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
7 2 3
def _wrap_function()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
7 3 2
def _put_rule()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
7 1 1
def generate_physical_id()
in source/GenomicsLearningCode/setup/crhelper/resource_helper.py
6 1 2