awslabs / aws-customer-churn-pipeline
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 229 lines of code in units (7.0% of code).
    • 0 very long units (0 lines of code)
    • 1 long units (80 lines of code)
    • 2 medium size units (79 lines of code)
    • 2 small units (35 lines of code)
    • 7 very small units (35 lines of code)
0% | 34% | 34% | 15% | 15%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 34% | 34% | 15% | 15%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
scripts0% | 34% | 34% | 15% | 15%
Alternative Visuals
Longest Units
Top 12 longest units
Unit# linesMcCabe index# params
def main()
in scripts/coxph_evaluation.py
80 2 1
def main()
in scripts/evaluation.py
44 1 1
def main()
in scripts/inferpreprocessing.py
35 5 1
def main()
in scripts/coxph_preprocessing.py
19 1 1
def main()
in scripts/preprocessing.py
16 1 1
def split_col_dtype()
in scripts/preprocessing.py
10 4 2
def survival_y_cox()
in scripts/coxph_preprocessing.py
8 3 1
def install()
in scripts/coxph_preprocessing.py
6 1 1
def install()
in scripts/preprocessing.py
5 1 1
def install()
in scripts/coxph_evaluation.py
2 1 1
def install()
in scripts/inferpreprocessing.py
2 1 1
def install()
in scripts/evaluation.py
2 1 1