aws-samples / cvat-on-aws-china
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 20 units with 218 lines of code in units (7.4% of code).
    • 0 very long units (0 lines of code)
    • 0 long units (0 lines of code)
    • 2 medium size units (46 lines of code)
    • 6 small units (88 lines of code)
    • 12 very small units (84 lines of code)
0% | 0% | 21% | 40% | 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% | 21% | 40% | 38%
Unit Size per Logical Component
primary logical decomposition
101+
51-100
21-50
11-20
1-10
cvat-serverless/functions/endpoints0% | 0% | 28% | 35% | 35%
cvat-serverless/functions0% | 0% | 0% | 42% | 57%
cvat-serverless0% | 0% | 0% | 100% | 0%
Alternative Visuals
Longest Units
Top 20 longest units
Unit# linesMcCabe index# params
def _compute_similarity_matrix()
in cvat-serverless/functions/endpoints/openvino_reidentification.py
24 4 5
def call()
in cvat-serverless/functions/endpoints/tf_rcnn.py
22 3 1
def function_invoke()
in cvat-serverless/functions/views.py
20 8 1
def infer()
in cvat-serverless/functions/endpoints/tf_rcnn.py
17 3 1
def call()
in cvat-serverless/functions/endpoints/pth_rcnn.py
15 3 1
def sagemaker_call()
in cvat-serverless/functions/endpoints/openvino_reidentification.py
14 1 1
def main()
in cvat-serverless/manage.py
11 2 0
def call()
in cvat-serverless/functions/endpoints/openvino_reidentification.py
11 1 1
def function_list()
in cvat-serverless/functions/views.py
10 3 1
def function_detail()
in cvat-serverless/functions/views.py
10 3 2
def call()
in cvat-serverless/functions/endpoints/foolwood_siammask.py
9 1 1
def infer()
in cvat-serverless/functions/endpoints/pth_rcnn.py
9 1 1
def call()
in cvat-serverless/functions/endpoints/shiyinzhang_iog.py
9 1 1
def infer()
in cvat-serverless/functions/endpoints/openvino_reidentification.py
8 3 6
def _match_boxes()
in cvat-serverless/functions/endpoints/openvino_reidentification.py
8 2 3
def get_label()
in cvat-serverless/functions/endpoints/tf_rcnn.py
8 4 1
def _match_crops()
in cvat-serverless/functions/endpoints/openvino_reidentification.py
6 1 2
def get_result_dict()
in cvat-serverless/functions/views.py
4 1 1
def create()
in cvat-serverless/functions/serializers.py
2 1 2
def update()
in cvat-serverless/functions/serializers.py
1 1 3