tensorflow / tfx
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 2,079 units with 21,217 lines of code in units (52.6% of code).
    • 0 very complex units (0 lines of code)
    • 5 complex units (455 lines of code)
    • 52 medium complex units (2,632 lines of code)
    • 160 simple units (4,548 lines of code)
    • 1,862 very simple units (13,582 lines of code)
0% | 2% | 12% | 21% | 64%
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% | 2% | 12% | 21% | 64%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
tfx/orchestration0% | 2% | 11% | 21% | 64%
tfx/dsl0% | 3% | 11% | 12% | 72%
tfx/scripts0% | 50% | 0% | 19% | 29%
tfx/types0% | 6% | 18% | 16% | 59%
tfx/components0% | 0% | 17% | 26% | 55%
tfx/extensions0% | 0% | 28% | 20% | 51%
tfx/benchmarks0% | 0% | 7% | 21% | 70%
tfx/utils0% | 0% | 9% | 18% | 72%
tfx/experimental0% | 0% | 4% | 24% | 70%
tfx/tools0% | 0% | 0% | 23% | 76%
tfx0% | 0% | 0% | 20% | 79%
ROOT0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
def type_check()
in tfx/types/component_spec.py
63 31 3
def run_component()
in tfx/scripts/run_component.py
84 28 4
def build()
in tfx/orchestration/kubeflow/v2/step_builder.py
115 28 1
def _orchestrate_active_pipeline()
in tfx/orchestration/experimental/core/pipeline_ops.py
101 28 4
def debug_str()
in tfx/dsl/compiler/placeholder_utils.py
92 27 1
def _parse_parameters()
in tfx/types/component_spec.py
46 24 3
def Do()
in tfx/dsl/component/experimental/decorators.py
65 23 7
def _resolve_proto_operator()
in tfx/dsl/compiler/placeholder_utils.py
63 21 2
def __call__()
in tfx/orchestration/experimental/core/sync_pipeline_task_gen.py
60 20 1
def set_parameter_value()
in tfx/orchestration/data_types_utils.py
49 20 3
def topsorted_layers()
in tfx/utils/topsort.py
51 20 7
def Do()
in tfx/extensions/google_cloud_ai_platform/tuner/executor.py
75 19 7
def Transform()
in tfx/components/transform/executor.py
122 19 6
def generate_output_split_names()
in tfx/components/example_gen/utils.py
42 18 6
def _create_matching_glob_and_regex()
in tfx/components/example_gen/utils.py
51 18 6
def _parse_raw_artifact()
in tfx/orchestration/kubeflow/v2/container/kubeflow_v2_entrypoint_utils.py
42 18 3
def _dump_ui_metadata()
in tfx/orchestration/kubeflow/container_entrypoint.py
70 18 3
def _generate_tasks_for_node()
in tfx/orchestration/experimental/core/async_pipeline_task_gen.py
95 17 3
def _runMetricsPlotsAndValidationsEvaluatorManualActuation()
in tfx/benchmarks/tfma_v2_benchmark_base.py
87 17 5
def Do()
in tfx/extensions/google_cloud_ai_platform/bulk_inferrer/executor.py
97 16 7