aws-samples / amazon-sagemaker-feature-store-end-to-end-workshop
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 139 units with 2,382 lines of code in units (89.5% of code).
    • 0 very long units (0 lines of code)
    • 3 long units (250 lines of code)
    • 37 medium size units (1,176 lines of code)
    • 37 small units (551 lines of code)
    • 62 very small units (405 lines of code)
0% | 10% | 49% | 23% | 17%
Legend:
101+
51-100
21-50
11-20
1-10
Unit Size per Extension
101+
51-100
21-50
11-20
1-10
py0% | 10% | 49% | 23% | 17%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
utilities0% | 16% | 43% | 23% | 17%
07-module-feature-monitoring0% | 0% | 71% | 23% | 4%
06-module-automated-pipeline0% | 0% | 58% | 24% | 16%
04-module-working-with-online-store/custom_library0% | 0% | 48% | 41% | 9%
05-module-scalable-batch-ingestion/scripts0% | 0% | 23% | 0% | 77%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def schedule_feature_pipeline()
in utilities/feature_store_helper.py
98 3 5
def get_features()
in utilities/feature_store_helper.py
91 6 6
def update_feature_pipeline()
in utilities/feature_store_helper.py
61 4 11
def ingest_with_dw()
in utilities/Utils.py
49 6 8
def get_latest_featureset_values()
in 04-module-working-with-online-store/custom_library/helper.py
48 15 3
def ingest_with_dw()
in utilities/feature_store_helper.py
47 6 9
def feature_databrew_profile()
in 07-module-feature-monitoring/feature_monitoring_utils.py
45 6 4
def get_latest_featureset_values()
in utilities/feature_store_helper.py
44 14 6
def _run_query()
in utilities/feature_store_helper.py
44 11 5
def _row_level_time_travel()
in utilities/feature_store_helper.py
38 4 8
def create_crawler()
in 07-module-feature-monitoring/feature_monitoring_utils.py
36 5 3
def run_crawler()
in 07-module-feature-monitoring/feature_monitoring_utils.py
35 9 5
def delete_fg_snapshot_ctas()
in 07-module-feature-monitoring/feature_monitoring_utils.py
34 1 3
def feature_monitoring_run()
in 07-module-feature-monitoring/feature_monitoring_utils.py
34 6 2
def _update_flow()
in utilities/Utils.py
34 1 3
def _update_flow()
in utilities/feature_store_helper.py
34 1 4
def _run_query()
in 06-module-automated-pipeline/pipeline_utils.py
32 7 4
def lambda_handler()
in 06-module-automated-pipeline/lambda_function.py
32 4 2
def create_fg_from_df()
in utilities/feature_store_helper.py
32 8 9
def create_fg_snapshot_ctas()
in 07-module-feature-monitoring/feature_monitoring_utils.py
31 2 2