aws-samples / rekognition-identity-verification
Conditional Complexity

The distribution of complexity of units (measured with McCabe index).

Intro
  • Conditional complexity (also called cyclomatic complexity) is a term used to measure the complexity of software. The term refers to the number of possible paths through a program function. A higher value ofter means higher maintenance and testing costs (infosecinstitute.com).
  • Conditional complexity is calculated by counting all conditions in the program that can affect the execution path (e.g. if statement, loops, switches, and/or operators, try and catch blocks...).
  • Conditional complexity is measured at the unit level (methods, functions...).
  • Units are classified in four categories based on the measured McCabe index: 1-5 (simple units), 6-10 (medium complex units), 11-25 (complex units), 26+ (very complex units).
Learn more...
Conditional Complexity Overall
  • There are 292 units with 2,881 lines of code in units (71.8% of code).
    • 0 very complex units (0 lines of code)
    • 0 complex units (0 lines of code)
    • 0 medium complex units (0 lines of code)
    • 4 simple units (105 lines of code)
    • 288 very simple units (2,776 lines of code)
0% | 0% | 0% | 3% | 96%
Legend:
51+
26-50
11-25
6-10
1-5
Alternative Visuals
Conditional Complexity per Extension
51+
26-50
11-25
6-10
1-5
py0% | 0% | 0% | 3% | 96%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
src/rekognition0% | 0% | 0% | 6% | 93%
src/bulk-loader0% | 0% | 0% | 5% | 94%
src/textract0% | 0% | 0% | 9% | 90%
src/test-client0% | 0% | 0% | 17% | 82%
infra/userportal0% | 0% | 0% | 0% | 100%
infra0% | 0% | 0% | 0% | 100%
infra/services0% | 0% | 0% | 0% | 100%
infra/bulkloader0% | 0% | 0% | 0% | 100%
infra/storage0% | 0% | 0% | 0% | 100%
ROOT0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
def function_main()
in src/rekognition/detect-faces/handler.py
33 8 3
def print_response()
in src/test-client/app.py
22 7 1
def analyze_id()
in src/textract/extract-idcard/handler.py
25 6 1
def qualifies_for_processing()
in src/bulk-loader/batch-handler/lib/importhistory.py
25 6 3
def get_text()
in src/textract/extract-idcard/model.py
15 5 1
def create()
in src/textract/extract-idcard/model.py
10 5 2
def create_payload()
in src/test-client/app.py
25 5 5
def get_registration_data()
in src/bulk-loader/batch-handler/lib/registrationproviders.py
21 5 2
def process_message_record()
in src/bulk-loader/inventory-created-handler/handler.py
64 5 1
def __init__()
in infra/services/networking/vpc.py
14 5 6
def persist()
in src/rekognition/index-faces/storage.py
25 4 3
def get_faces()
in src/rekognition/compare-faces/ddb.py
20 4 2
def __get_image_from_uri()
in src/rekognition/compare-faces/ddb.py
20 4 2
def create_collections()
in src/rekognition/setup/app.py
29 4 0
def get_user_portal_url()
in src/bulk-loader/throttled-indexer/handler.py
18 4 0
def function_main()
in src/textract/extract-idcard/handler.py
25 3 3
def find_blocks()
in src/textract/extract-idcard/model.py
3 3 2
def blocks()
in src/textract/extract-idcard/model.py
6 3 1
def __init__()
in src/textract/extract-idcard/model.py
10 3 3
def __init__()
in src/textract/extract-idcard/model.py
12 3 2