tensorflow / serving
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 820 units with 12,503 lines of code in units (56.2% of code).
    • 0 very complex units (0 lines of code)
    • 3 complex units (444 lines of code)
    • 31 medium complex units (1,934 lines of code)
    • 65 simple units (2,597 lines of code)
    • 721 very simple units (7,528 lines of code)
0% | 3% | 15% | 20% | 60%
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
cc0% | 4% | 18% | 21% | 56%
py0% | 0% | 0% | 34% | 65%
h0% | 0% | 0% | 10% | 89%
Conditional Complexity per Logical Component
primary logical decomposition
51+
26-50
11-25
6-10
1-5
tensorflow_serving/model_servers0% | 12% | 8% | 27% | 51%
tensorflow_serving/util0% | 7% | 18% | 19% | 54%
tensorflow_serving/servables0% | 0% | 24% | 22% | 52%
tensorflow_serving/batching0% | 0% | 31% | 26% | 41%
tensorflow_serving/core0% | 0% | 6% | 11% | 81%
tensorflow_serving/resources0% | 0% | 9% | 6% | 83%
tensorflow_serving/example0% | 0% | 0% | 35% | 64%
tensorflow_serving/sources0% | 0% | 0% | 31% | 68%
tensorflow_serving/experimental0% | 0% | 0% | 17% | 82%
tensorflow_serving/apis0% | 0% | 0% | 0% | 100%
tensorflow_serving/session_bundle0% | 0% | 0% | 0% | 100%
Most Complex Units
Top 20 most complex units
Unit# linesMcCabe index# params
Status Server::BuildAndStart()
in tensorflow_serving/model_servers/server.cc
225 35 1
GZipHeader::Status GZipHeader::ReadMore()
in tensorflow_serving/util/net_http/compression/gzip_zlib.cc
131 32 3
int ZLib::UncompressAtMostOrAll()
in tensorflow_serving/util/net_http/compression/gzip_zlib.cc
88 29 5
Status PostProcessClassificationResult()
in tensorflow_serving/servables/tensorflow/classifier.cc
90 24 5
net_http::HTTPStatusCode ToHTTPStatusCode()
in tensorflow_serving/model_servers/http_server.cc
45 21 1
Status ServerCore::ReloadConfig()
in tensorflow_serving/model_servers/server_core.cc
55 21 1
Status AddValueToTensor()
in tensorflow_serving/util/json_tensor.cc
45 20 3
Status AddValueToFeature()
in tensorflow_serving/util/json_tensor.cc
58 18 3
int ZLib::CompressAtMostOrAll()
in tensorflow_serving/util/net_http/compression/gzip_zlib.cc
35 17 5
int main()
in tensorflow_serving/util/net_http/socket/testing/ev_fetch_client.cc
83 17 2
void request_cb()
in tensorflow_serving/util/net_http/socket/testing/ev_print_req_server.cc
100 17 2
Status SplitInputTask()
in tensorflow_serving/batching/batching_session.cc
118 17 4
Status TensorFlowMultiInferenceRunner::Infer()
in tensorflow_serving/servables/tensorflow/multi_inference.cc
87 16 3
Status TfLiteSession::Create()
in tensorflow_serving/servables/tensorflow/tflite_session.cc
101 15 6
Status FillTensorMapFromInstancesList()
in tensorflow_serving/util/json_tensor.cc
73 15 3
Status BatchingSession::MergeInputTensors()
in tensorflow_serving/batching/batching_session.cc
85 15 3
Status SetInputAndInvokeMiniBatch()
in tensorflow_serving/servables/tensorflow/tflite_session.cc
65 14 5
std::vector BasicManager::GetLoadersCurrentlyUsingResources()
in tensorflow_serving/core/basic_manager.cc
47 14 0
Status AddSingleValueAndAdvance()
in tensorflow_serving/util/json_tensor.cc
54 14 4
bool ParsedEvRequest::decode()
in tensorflow_serving/util/net_http/server/internal/evhttp_request.cc
55 14 0