File Complexity Overall
  • There are 126 files with units, with 16,102 lines of code.
    • 0 very complex files (McCabe index sum 251+; 0 lines of code)
    • 1 complex files (McCabe index sum 126-250; 656 lines of code)
    • 4 medium complex files (McCabe index sum 51-125; 1,289 lines of code)
    • 8 slightly complex files (McCabe index sum 26-50; 1,843 lines of code)
    • 113 simple files (McCabe index sum 1-25; 12,314 lines of code)
  • 14 main files have no units (e.g. languages without unit analysis, or files without functions) and are not classified.
system0% | 4% | 8% | 11% | 76%
Legend:
251+
126-250
51-125
26-50
1-25


explore: grouped by folders | grouped by complexity
File Complexity per Extension
251+
126-250
51-125
26-50
1-25
py0% | 4% | 8% | 11% | 76%
File Complexity per Logical Decomposition
primary
251+
126-250
51-125
26-50
1-25
tile_kernels0% | 4% | 8% | 11% | 76%
Most Complex Files (Top 50)

The McCabe index of a file grows with its size: per 100 lines tells a large but plain file from a dense one, and most complex unit whether the complexity sits in one unit or is spread over many.

File# lines# unitsMcCabe index
(sum)
per 100
lines
most complex
unit
benchmark.py
in tile_kernels/testing/pytest
656 45 244 37 58
gpu_mem.py
in tile_kernels/testing/pytest
319 21 111 35 18
330 17 66 20 8
common.py
in tile_kernels/quant
261 24 55 21 7
norm_forward_asc.py
in tile_kernels/quant
379 11 52 14 16
swiglu_forward_asc.py
in tile_kernels/quant
347 12 49 14 22
generator.py
in tile_kernels/testing
131 11 47 36 11
per_token_cast_asc.py
in tile_kernels/quant
336 11 43 13 11
per_channel_cast_asc.py
in tile_kernels/quant
262 5 35 13 27
cast_back_asc.py
in tile_kernels/quant
190 6 35 18 15
per_block_cast_asc.py
in tile_kernels/quant
195 8 33 17 21
post_asc.py
in tile_kernels/mhc
164 2 30 18 19
per_block_cast_lossless_asc.py
in tile_kernels/quant
218 11 27 12 7
config.py
in tile_kernels
90 18 23 26 2
xdist_failfast.py
in tile_kernels/testing/pytest
59 6 23 39 9
topk_gate_asc.py
in tile_kernels/moe
117 1 23 20 23
bench.py
in tile_kernels/testing
84 9 22 26 6
norm_backward_asc.py
in tile_kernels/quant
172 5 20 12 10
engram_gate_bwd_cuda.py
in tile_kernels/engram
274 8 18 7 5
148 1 18 12 18
cast.py
in tile_kernels/torch
255 8 17 7 6
precompile.py
in tile_kernels/testing/pytest
27 2 15 56 9
norm_fn_cuda.py
in tile_kernels/mhc
131 4 15 11 7
swiglu_backward_asc.py
in tile_kernels/quant
445 8 14 3 3
tilelang_warning.py
in tile_kernels/testing/pytest
35 3 14 40 6
pre_apply_mix_asc.py
in tile_kernels/mhc
99 2 14 14 8
expand_cuda.py
in tile_kernels/mhc
45 2 14 31 7
topk_gate_cuda.py
in tile_kernels/moe
56 1 14 25 14
engram_sinkhorn_cuda.py
in tile_kernels/engram
213 11 13 6 3
common.py
in tile_kernels/testing/pytest
25 4 13 52 6
numeric.py
in tile_kernels/testing
52 4 12 23 5
expand_kernel.py
in tile_kernels/mhc
36 4 12 33 5
cast_cuda.py
in tile_kernels/quant
70 1 11 16 11
cast_asc.py
in tile_kernels/quant
107 7 11 10 3
sqrt_softplus.py
in tile_kernels/moe
106 10 10 9 1
normalize_weight_cuda.py
in tile_kernels/moe
41 1 10 24 10
102 1 9 9 9
mhc.py
in tile_kernels/torch
86 8 9 10 2
engram_gate.py
in tile_kernels/modeling/engram
61 2 9 15 7
utils.py
in tile_kernels
24 6 9 38 2
78 1 8 10 8
engram_sinkhorn_asc.py
in tile_kernels/engram
252 8 8 3 1
swiglu.py
in tile_kernels/torch
143 5 8 6 3
head_compute_mix_kernel.py
in tile_kernels/mhc
94 3 8 9 6
expand_asc.py
in tile_kernels/mhc
62 2 8 13 4
rstd.py
in tile_kernels/quant
65 5 7 11 3
engram_gate_fwd_cuda.py
in tile_kernels/engram
163 4 7 4 4
engram.py
in tile_kernels/torch
108 6 7 6 2
norm_fn_asc.py
in tile_kernels/mhc
369 5 7 2 3
norm_forward_kernel.py
in tile_kernels/quant
194 4 6 3 3
About This Analysis
  • File complexity is the sum of the McCabe indexes (conditional complexity) of the units (methods, functions...) in a file.
  • Files are classified in five categories based on that sum: 1-25 (simple files), 26-50 (slightly complex files), 51-125 (medium complex files), 126-250 (complex files), 251+ (very complex files). The default bands are five times the unit complexity bands, as a file is a group of units.
  • Only main code files with units are classified. Files without units (languages without unit analysis, or files without functions) have no complexity to measure and are left out rather than counted as simple.
  • A very complex file holds many decisions, which often means it has too many responsibilities: a candidate to split, and a place where changes need more testing.
Learn more...