aws / to-smote-or-not
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 58 units with 461 lines of code in units (50.8% of code).
    • 0 very long units (0 lines of code)
    • 2 long units (115 lines of code)
    • 1 medium size units (29 lines of code)
    • 3 small units (44 lines of code)
    • 52 very small units (273 lines of code)
0% | 24% | 6% | 9% | 59%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 24% | 6% | 9% | 59%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
src0% | 24% | 6% | 9% | 59%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def sample()
in src/smote_variants.py
60 18 3
def avg_plots()
in src/analyze.py
55 8 3
def filter_optimal_hps()
in src/analyze.py
29 12 3
def _process_dataset()
in src/utils.py
18 4 3
def set_random_state()
in src/smote_variants.py
14 5 2
def _encode_target()
in src/utils.py
12 5 1
def __init__()
in src/smote_variants.py
10 2 4
def experiment()
in src/experiment.py
10 1 0
def check_less_or_equal_par()
in src/smote_variants.py
8 2 5
def check_less()
in src/smote_variants.py
8 2 4
def check_less_par()
in src/smote_variants.py
8 2 5
def check_greater_or_equal_par()
in src/smote_variants.py
8 2 5
def check_greater_par()
in src/smote_variants.py
8 2 5
def check_equal()
in src/smote_variants.py
8 2 4
def check_equal_par()
in src/smote_variants.py
8 2 5
def class_label_statistics()
in src/smote_variants.py
7 3 3
7 2 2
7 4 3
def sample_with_timing()
in src/smote_variants.py
7 1 3
def _fit_xgboost()
in src/classifiers.py
7 1 0