tensorflow / runtime
File Size

The distribution of size of files (measured in lines of code).

Intro
  • File size measurements show the distribution of size of files.
  • Files are classified in four categories based on their size (lines of code): 1-100 (very small files), 101-200 (small files), 201-500 (medium size files), 501-1000 (long files), 1001+(very long files).
  • It is a good practice to keep files small. Long files may become "bloaters", code that have increased to such gargantuan proportions that they are hard to work with.
Learn more...
File Size Overall
  • There are 835 files with 149,770 lines of code.
    • 10 very long files (74,040 lines of code)
    • 17 long files (11,125 lines of code)
    • 73 medium size files (22,191 lines of codeclsfd_ftr_w_mp_ins)
    • 118 small files (16,356 lines of code)
    • 617 very small files (26,058 lines of code)
49% | 7% | 14% | 10% | 17%
Legend:
1001+
501-1000
201-500
101-200
1-100


explore: zoomable circles | sunburst | 3D view
File Size per Extension
1001+
501-1000
201-500
101-200
1-100
mlir83% | <1% | 3% | 4% | 8%
cc11% | 20% | 28% | 19% | 21%
h5% | 9% | 29% | 17% | 37%
bzl0% | 0% | 0% | 81% | 18%
proto0% | 0% | 0% | 54% | 45%
py0% | 0% | 0% | 0% | 100%
File Size per Logical Decomposition
primary
1001+
501-1000
201-500
101-200
1-100
backends/common93% | 0% | 2% | 2% | 2%
backends/gpu12% | 16% | 30% | 20% | 19%
integrationtest/resnet100% | 0% | 0% | 0% | 0%
lib/distributed_runtime36% | 20% | 10% | 16% | 17%
include/tfrt0% | 15% | 20% | 17% | 46%
lib/bef_converter0% | 53% | 21% | 5% | 19%
backends/jitrt0% | 26% | 29% | 14% | 28%
lib/core_runtime0% | 44% | 37% | 10% | 7%
lib/data0% | 0% | 32% | 31% | 35%
lib/bef_executor0% | 0% | 69% | 30% | 0%
lib/basic_kernels0% | 0% | 66% | 0% | 33%
mlir_tests/core_runtime0% | 0% | 60% | 0% | 39%
backends/cpu0% | 0% | 10% | 21% | 67%
lib/tensor0% | 0% | 27% | 22% | 50%
mlir_tests/bef_executor0% | 0% | 24% | 37% | 37%
mlir_tests/bef_to_mlir0% | 0% | 45% | 27% | 26%
lib/compiler0% | 0% | 81% | 0% | 18%
lib/bef_executor_driver0% | 0% | 100% | 0% | 0%
mlir_tests/basic_kernels0% | 0% | 41% | 18% | 39%
lib/support0% | 0% | 32% | 28% | 39%
mlir_tests/tensor0% | 0% | 40% | 34% | 24%
integrationtest/mnist0% | 0% | 0% | 100% | 0%
ROOT0% | 0% | 0% | 100% | 0%
lib/host_context0% | 0% | 0% | 20% | 79%
tools/btf_info_tool0% | 0% | 0% | 100% | 0%
lib/bef0% | 0% | 0% | 100% | 0%
mlir_tests/compiler0% | 0% | 0% | 72% | 27%
mlir_tests0% | 0% | 0% | 73% | 26%
cpp_tests/core_runtime0% | 0% | 0% | 71% | 28%
mlir_tests/bef_perf0% | 0% | 0% | 0% | 100%
lib/io0% | 0% | 0% | 0% | 100%
lib/tracing0% | 0% | 0% | 0% | 100%
lib/utils0% | 0% | 0% | 0% | 100%
mlir_tests/mlir_to_bef0% | 0% | 0% | 0% | 100%
integrationtest/fizzbuzz0% | 0% | 0% | 0% | 100%
tools/code_size_test_app0% | 0% | 0% | 0% | 100%
cpp_tests/tracing0% | 0% | 0% | 0% | 100%
tools0% | 0% | 0% | 0% | 100%
tools/bef_executor0% | 0% | 0% | 0% | 100%
mlir_tests/tracing0% | 0% | 0% | 0% | 100%
cpp_tests/include0% | 0% | 0% | 0% | 100%
mlir_tests/code_size_test_app0% | 0% | 0% | 0% | 100%
lib0% | 0% | 0% | 0% | 100%
lib/metrics0% | 0% | 0% | 0% | 100%
lib/dtype0% | 0% | 0% | 0% | 100%
tools/tfrt_opt0% | 0% | 0% | 0% | 100%
Longest Files (Top 50)
File# lines# units
mlir
conv2d.bias.mlir
in backends/common/mlir_tests/compat/eigen
17871 -
mlir
conv2d.batch_norm.mlir
in backends/common/mlir_tests/compat/eigen
16531 -
mlir
conv2d_grad_input.mlir
in backends/common/mlir_tests/compat/eigen
16147 -
mlir
conv2d_grad_filter.mlir
in backends/common/mlir_tests/compat/eigen
16147 -
mlir
resnet50_graph_inference.mlir
in integrationtest/resnet
1525 -
spatial_convolution_data_mapper.h
in backends/common/include/tfrt/common/compat/eigen
1344 60
cudnn_wrapper.cc
in backends/gpu/lib/wrapper
1215 109
driver_wrapper.cc
in backends/gpu/lib/wrapper
1159 98
kernels.cc
in lib/distributed_runtime
1062 34
gpu_to_tfrt_passes.cc
in backends/gpu/lib/passes
1039 59
dnn_wrapper.cc
in backends/gpu/lib/wrapper
838 59
jitrt.cc
in backends/jitrt/lib
798 50
kernel_utils.h
in include/tfrt/host_context
737 75
mlir_to_bef.cc
in lib/bef_converter/mlir_to_bef
732 42
kernels.cc
in lib/core_runtime
723 42
bef_to_mlir.cc
in lib/bef_converter/bef_to_mlir
711 34
op_utils.h
in include/tfrt/core_runtime
668 37
cuda_wrapper.cc
in backends/gpu/lib/wrapper
656 88
op_attrs.cc
in lib/core_runtime
639 27
dnn_ops.cc
in backends/gpu/lib/ops/tf
628 13
dnn_kernels.cc
in backends/gpu/lib/kernels
612 19
cudnn_wrapper.h
in backends/gpu/include/tfrt/gpu/wrapper
606 -
request_handler_impl.cc
in lib/distributed_runtime
591 16
mlir
math_optimization.mlir
in backends/jitrt/mlir_tests/codegen
568 -
async_value.h
in include/tfrt/host_context
555 59
hip_wrapper.cc
in backends/gpu/lib/wrapper
554 75
dnn_ops.cu.cc
in backends/gpu/lib/ops/tf
509 30
cufft_wrapper.cc
in backends/gpu/lib/wrapper
491 42
bef_file.cc
in lib/bef_executor
481 16
contraction_kernel.h
in backends/common/include/tfrt/common/compat/eigen
467 13
jitrt.h
in backends/jitrt/include/tfrt/jitrt
456 18
mlir
basic_ops.mlir
in mlir_tests/core_runtime
432 -
basic_kernels.cc
in lib/basic_kernels/opdefs
420 21
op_attrs.h
in include/tfrt/core_runtime
417 50
metadata_functions.cc
in backends/common/lib/ops/tf
416 22
bias_add_f16_kernel.h
in backends/gpu/include/tfrt/gpu/ops/tf
412 -
bias_add_f64_kernel.h
in backends/gpu/include/tfrt/gpu/ops/tf
412 -
bias_add_f32_kernel.h
in backends/gpu/include/tfrt/gpu/ops/tf
411 -
cublas_enums.cc
in backends/gpu/lib/wrapper
394 9
reduction_ops.cu.cc
in backends/gpu/lib/ops/tf
382 20
control_flow_kernels.cc
in lib/basic_kernels
375 12
dispatch_utils.h
in include/tfrt/core_runtime
366 8
bef_executor.cc
in lib/bef_executor
366 21
bef_attr_emitter.cc
in lib/bef_converter/mlir_to_bef
359 15
dnn_wrapper.h
in backends/gpu/include/tfrt/gpu/wrapper
352 1
batch_dataset.h
in lib/data
350 19
mlir
basics.mlir
in mlir_tests/bef_executor
349 -
attribute_utils.h
in include/tfrt/host_context
343 54
driver_kernels.cc
in backends/gpu/lib/kernels
337 25
miopen_wrapper.cc
in backends/gpu/lib/wrapper
326 30
Files With Most Units (Top 20)
File# lines# units
cudnn_wrapper.cc
in backends/gpu/lib/wrapper
1215 109
driver_wrapper.cc
in backends/gpu/lib/wrapper
1159 98
cuda_wrapper.cc
in backends/gpu/lib/wrapper
656 88
kernel_utils.h
in include/tfrt/host_context
737 75
hip_wrapper.cc
in backends/gpu/lib/wrapper
554 75
spatial_convolution_data_mapper.h
in backends/common/include/tfrt/common/compat/eigen
1344 60
async_value.h
in include/tfrt/host_context
555 59
gpu_to_tfrt_passes.cc
in backends/gpu/lib/passes
1039 59
dnn_wrapper.cc
in backends/gpu/lib/wrapper
838 59
attribute_utils.h
in include/tfrt/host_context
343 54
op_attrs.h
in include/tfrt/core_runtime
417 50
jitrt.cc
in backends/jitrt/lib
798 50
async_value_ref.h
in include/tfrt/host_context
226 48
mlir_to_bef.cc
in lib/bef_converter/mlir_to_bef
732 42
kernels.cc
in lib/core_runtime
723 42
cufft_wrapper.cc
in backends/gpu/lib/wrapper
491 42
kernel_frame.h
in include/tfrt/host_context
217 39
op_utils.h
in include/tfrt/core_runtime
668 37
bef_to_mlir.cc
in lib/bef_converter/bef_to_mlir
711 34
kernels.cc
in lib/distributed_runtime
1062 34
Files With Long Lines (Top 20)

There are 52 files with lines longer than 120 characters. In total, there are 381 long lines.

File# lines# units# long lines
mlir
resnet50_graph_inference.mlir
in integrationtest/resnet
1525 - 184
mlir
mnist_training.mlir
in integrationtest/mnist
162 - 20
mlir
tf_addv2.mlir
in backends/gpu/mlir_tests/core_runtime
170 - 16
mlir
cost_driven_async_parallel_for.mlir
in backends/cpu/mlir_tests/rt
59 - 14
mlir
basic_ops.mlir
in mlir_tests/core_runtime
432 - 12
mlir
mnist.mlir
in integrationtest/mnist
124 - 10
mlir
tf_conv2d.mlir
in backends/gpu/mlir_tests/core_runtime
122 - 10
mlir
dnn.mlir
in backends/gpu/mlir_tests/cuda
163 - 9
mlir
tf_biasadd.mlir
in backends/cpu/mlir_tests/core_runtime
85 - 8
mlir
tf_conv2d.mlir
in backends/cpu/mlir_tests/core_runtime
76 - 8
mlir
tf_fusedbatchnorm.mlir
in backends/gpu/mlir_tests/core_runtime
85 - 7
mlir
composite_op.mlir
in mlir_tests/core_runtime
93 - 7
dependencies.bzl
in root
114 - 5
mlir
launch.mlir
in backends/gpu/mlir_tests/cuda
117 - 5
mlir
tf_softmax.mlir
in backends/cpu/mlir_tests/core_runtime
68 - 4
mlir
tf_cast.mlir
in backends/gpu/mlir_tests/core_runtime
59 - 4
mlir
current_context_lifetime.mlir
in backends/gpu/mlir_tests/core_runtime
69 - 4
mlir
tf_maxpool.mlir
in backends/gpu/mlir_tests/core_runtime
45 - 3
mlir
tf_relu.mlir
in backends/gpu/mlir_tests/core_runtime
52 - 3
mlir
tf_matmul.mlir
in backends/gpu/mlir_tests/core_runtime
138 - 3