ρCATNIP / OUTLIER STUDY
baseline27FPS · 576 Linear · 13.690B weights · 63,360 activation calls

Catnip Tensorwise FP8 Outlier Statistics

极端权重确实会使更多小权重落入 E4M3 的 subnormal/zero 区,但它们并不是 Catnip 当前约 2.65% weight relative-L2 的主要来源。相比之下,真实 activation tail 与局部量化误差的关系更明确,因此工程重点应由“全局处理 weight outlier”转向“heldout 验证下的定向 activation intervention”。

Read the conclusions → View all figures Embedded paper Embedded metrics
最重要的统计结论Weight outlier 主要增加 underflow count,而非 total error energyChannel skew → underflow:ρ=0.812;weight tail → E4M3 RelL2:ρ=-0.046。
更值得研究的方向Activation tail 对 local error 的解释力更强Tail → tensorwise error:ρ=0.380;tail → rowwise gain:ρ=0.442。
Production claim boundary尚不支持任何端到端质量修改仅两个 prompts、同一 seed;local reconstruction 不是 video/audio quality causality。
Plain-language statistical conclusions

先给出可理解、可引用的结论

“Outlier 有影响”本身并不足够;必须说明影响发生在哪里、效应多大,以及它是否足以改变 production decision。本研究得到的是一个分层结论。

01 · COUNT

Outlier 会让更多小权重变成零

Tensorwise scale 由最大值决定。不同 output channels 的最大值越不均衡,小权重发生 nonzero-to-zero underflow 的比例越高;Spearman ρ=0.812,95% CI [0.773, 0.846],属于稳定的强单调关系。

02 · ENERGY

但这些零值携带的能量很小

Weight amax/p99.99 与 E4M3 relative-L2 的 ρ=-0.046,95% CI [-0.129, 0.037],统计上不支持单调关系。全局 underflow 仅约 0.00960%,且主要位于低能量区。

03 · FORMAT

E4M3 与 uniform INT8 的 outlier 机制不同

INT8 使用全 tensor 共享的固定步长,极值会线性放大主体分布的步长;其 tail-error ρ=0.817。E4M3 具有 exponent,各数量级保留近似相对精度,因此 outlier 代价更多转移到动态范围底部。

04 · ACTION

Activation outlier 是更有价值的后续方向

真实 activation tail 与 tensorwise local error 的 ρ=0.380,与 rowwise MSE gain 的 ρ=0.442。该效应为中等强度,且有显著 family structure,但必须经过更广 heldout 与端到端配对实验。

2.6497%
Production weight RelL2

13.690B 权重上的 exact global relative-L2;逐层高度集中。

93.89%
Underflow reduction

Output-channel weight scale 减少的 underflow count;MSE 仅改善 0.476%。

0.442
Activation tail → rowwise gain

95% bootstrap CI [0.390, 0.493],比 weight-tail effect 更明确。

2 prompts
Generalization boundary

两个 calibration prompts 使用相同 seed,不能代表 population-level quality。

Interpretation boundary

本研究测量 weight reconstruction、sampled activation reconstruction 与 descriptive risk ranking。它不证明某一层导致最终视频或音频质量下降,也不批准 rowwise、clipping、sparse residual 或其他 production quantization modification。

ρ / Spearman correlation

衡量两个变量排名是否共同升降。ρ 接近 1 为强正关系,接近 0 表示没有稳定单调关系;它不是“解释了多少百分比”。

95% bootstrap CI

按 12 个 Linear families 分层重采样 4,000 次。区间跨 0 时,不将观察到的方向视为稳定关联。

Count ≠ energy

Underflow 统计丢失了多少非零元素;relative-L2 按平方能量加权。大量极小值变零,仍可能只贡献很小总能量。

Visual abstract

四张图概括主要发现

Scatter plot 回答关联强弱,heatmap 回答风险集中在哪里,temporal map 回答 streaming 过程中何时发生,joint-risk map 用于选择下一轮实验层。

Figure 1 · Weight outlier consequences. 左图为强关系(ρ=0.812);右图接近无关系(ρ=-0.046)。这一区分构成全文核心结论。
Figure 2 · Weight underflow heatmap. 48 blocks × 12 families。晚层 S2-O 形成清晰热点;颜色为 log10(fraction + 10⁻⁷)。
Figure 3 · Streaming temporal structure. Activation tail 在 nfe0 最大、commit 最小;relative-L2 仍位于窄区间,说明 tail 变化不会一比一映射为总误差。
Figure 4 · Joint descriptive risk. 晚层 S2-O 与 S2-Q 是最稳定的联合风险区域。该分数用于实验选层,不是 failure probability。
Step-by-step analysis

从数据定义到工程决策的五步证据链

分析遵循 Data provenance → weight mechanism → counterfactual interventions → activation dynamics → joint-risk localization 的顺序,避免由单一相关系数直接跳到 production action。

1
Data provenance & measurement contract

冻结 baseline27FPS 的 576-layer production manifest

实现来源唯一锁定为 /workspace/week2-improved-fp8_scaled。后续 week 的代码候选不被采纳;week4 observer bundle 仅作为 measurement input,并与 week2 manifest 逐层交集验证。

576
Linear modules

48 Transformer blocks × 12 Linear families。

13.690B
Exact weight elements

FP8 errors、underflow 与 scale counterfactuals 全元素计算。

63,360
Activation call records

2 cells × 576 modules × 55 forwards。

4,000
Bootstrap replicates

每个主相关按 12 families 分层重采样。

Figure 5 · Production mechanism. BF16 source → tensorwise E4M3FN weight;per-call dynamic tensorwise activation;native aten._scaled_mm 输出 BF16。研究分别观测 scale、rounding、underflow 与 local error。

Exact measurements

  • Weight amax/channel amaxall elements
  • FP8 error & underflowall elements
  • Scale grid errorsall elements
  • Activation amaxfull call

Bounded deterministic probes

  • Weight quantiles/kurtosis≤262,144/layer
  • Activation p50/p99.9≤8,192/call
  • Activation quant error≤64 rows/call
  • INT8 control≤262,144/layer
Input

Two 20 s requests: person-car and person-ceramics, seed 12345。

Invariant

832×480、489 frames、11 chunks、55 forwards,与 576-layer manifest 一致。

Boundary

模块数 n=576 不等于 576 个独立内容实验;activation population 只有两个 cells。

2
Weight-space mechanism

区分 weight tail、channel skew、underflow 与 energy-weighted error

Tensor tail T(w)=amax/p99.99 衡量单 tensor 极端值;channel skew S(w)=max channel amax / median channel amax 衡量通道间不均衡。两者对应不同的统计后果。

RelL2(W, Ŵ) = √[ Σᵢ(Wᵢ − Ŵᵢ)² / ΣᵢWᵢ² ]
Figure 6 · Weight family distributions. Family 对 channel skew 与 underflow 具有中到大效应:Kruskal–Wallis ε² 分别为 0.338 与 0.477。
Relationshipρ95% CIpInterpretation
Weight channel skew → underflow0.812[0.773, 0.846]1.62e-136Strong
Weight amax/p99.99 → E4M3 RelL2−0.046[−0.129, 0.037]0.271Not supported
Channel skew → channelwise MSE gain0.200[0.122, 0.280]1.30e-6Small engineering effect
Weight tail → dense clipping gain−0.065[−0.144, 0.013]0.121Not supported
Figure 7 · INT8 mechanism control. 相同 tail metric 在 sampled uniform INT8 下与 error 强相关(ρ=0.817),而在 exact E4M3 下为 −0.046。差异来自 fixed step 与 exponent-based relative precision。
FormatMedian RelL2Tail ρ95% CIEvidence scope
E4M32.648%−0.046[−0.128, 0.040]Exact all weights
Uniform INT84.849%0.817[0.784, 0.847]Deterministic sampled control
Observation

Global nonzero-to-zero rate 为 9.601×10⁻⁵,即 0.00960%。

Mechanism

E4M3 exponent 缓冲 max outlier 对 normal-range relative precision 的影响。

Decision

不依据 weight tail severity 单独批准 clipping 或更细 scale。

3
Counterfactual interventions

量化每一种 outlier treatment 的误差—存储代价

对十个 scale multipliers 计算 exact dense clipping 与 optimistic exact-FP32 sparse residual。Sparse 结果仅是离线上界,不包含真实索引布局、alignment、kernel overhead 或端到端质量。

Figure 8 · Scale counterfactual. Dense clipping 随 α 降低迅速恶化;sparse residual 以额外 bytes 换取误差下降。α=.25 是首个仍接近 2× compression 的 Pareto reference。
StrategyRelL2MSE reductionBytes/WBF16 compression
Production tensorwise FP82.6497%0%1.00002.000×
Output-channel FP82.6434%0.476%1.00081.998×
Per-layer best dense clip2.6478%0.148%1.00002.000×
Sparse residual α=.52.6479%0.135%1.00031.999×
Sparse residual α=.252.6097%2.995%1.02141.958×
Sparse residual α=.1252.3477%21.495%1.24631.605×
Sparse residual α=.06251.7045%58.619%2.14080.934×
Figure 9 · Layer-gain ECDF. Output-channel scale 为广泛但很小的改善;best dense grid 大量位于零附近;α=.25 sparse residual 多数层为正,但仍缺少 runtime evidence。

Dense clipping result

即使使用“每层看完结果后选最佳 α”的 optimistic oracle,全局 MSE 也仅改善 0.1479%,且 57.47% layers 仍选择 α=1。α=.25/.125/.0625 分别使 dense MSE 变为 production 的 3.71×/34.88×/175.25×。

Channelwise

Underflow count −93.89%,但 global MSE 仅 −0.476%。

Dense clipping

现有 E4M3 不形成有意义的全局收益。

Sparse residual

仅保留 α=.25 作为未来 kernel prototype 的 reference point。

4
Real streaming activations

Activation tail 与局部误差关系更强,但存在 prompt dependence

每个模块先在每个 cell 内聚合 55 calls,再跨两个 cells 合并。该层级避免单次峰值支配模块排序,同时保留 NFE、chunk 与 family 的 streaming structure。

Figure 10 · Activation family distributions. Activation tail family effect ε²=0.658;rowwise gain effect ε²=0.687。S2-Q median rowwise gain 49.13%,A2V-Q 31.98%,但均为 local sampled metrics。
Complete 12-family statistical summary
FamilyW skew medianW underflow p95Channel MSE gainAct tail p95Rowwise gainTop-1% Jaccard
S1-Q4.5850.0107%0.493%4.1516.491%0.547
S1-K4.7390.0101%0.788%4.1516.491%0.547
S1-V3.1210.0052%0.510%4.1516.491%0.547
S1-O3.9990.0050%0.496%3.3501.216%0.180
S2-Q8.5750.0151%0.619%11.94749.129%0.783
S2-K6.5800.0073%0.417%4.3206.965%0.673
S2-V4.4470.0080%0.518%4.3206.965%0.673
S2-O7.3250.1325%0.780%22.8219.011%0.180
A2V-Q3.5880.0119%0.550%7.96031.978%0.708
A2V-O2.4950.0015%0.534%8.2865.720%0.183
FF-Up5.8340.0167%0.620%4.1032.299%0.426
FF-Down4.6560.0260%0.244%6.2181.261%0.176
Relationshipρ95% CIpInterpretation
Activation tail → tensorwise local RelL20.380[0.317, 0.446]3.29e-21Moderate
Activation tail → rowwise MSE gain0.442[0.390, 0.493]6.67e-29Moderate
Weight tail ↔ activation tail0.085[0.014, 0.159]0.0415Weak; fails Holm
Figure 11 · Cross-cell stability. Channel log-amax rank median ρ=0.913;top-1% channel Jaccard median 0.547;exact argmax 相同 62.5%。模块 error 排序跨 cell 仅 ρ=0.436。

Stable evidence

  • Within-module channel rankmedian ρ=.913
  • Top-1% channel overlapJaccard=.547
  • Same argmax channel62.5%

Generalization warning

  • Module-risk rank across cellsρ=.436
  • Median error location shiftWilcoxon p=.741
  • Independent seeds0

Why local rowwise gain is not a production decision

Week4 历史证据显示 full-rowwise activation 可在局部 MSE 上改善,但六格 trajectory/media gate 存在明显 tail regression;SmoothQuant 亦在 calibration 改善而 heldout 失败。因此本研究只支持缩小 candidate scope,不支持重新启用 global rowwise。

5
Joint risk localization

联合 weight 与 activation symptoms,选择可归因实验层

Joint score 是四个 percentile ranks 的平均:weight tail、weight underflow、activation tail 与 rowwise local gain。它仅用于 experimental selection,不能解释为质量失败概率。

Rℓ = ¼ [rank(Twℓ) + rank(Uwℓ) + rank(Txℓ) + rank(Gxℓ)]

完整 top-15 joint-risk result table:以下结果同时覆盖 late S2-O 与 S2-Q,用于构造下一轮 high-risk intervention set。

Top joint-risk moduleRisk pct.W tailUnderflowAct tailRow gain
transformer_blocks.36.attn2.to_out.097.9656.620.112%110.1240.63%
transformer_blocks.41.attn2.to_out.096.0152.090.079%47.6934.04%
transformer_blocks.38.attn2.to_out.095.0160.590.104%31.1027.92%
transformer_blocks.37.attn2.to_out.094.9258.820.143%45.9621.52%
transformer_blocks.40.attn2.to_out.094.3164.000.113%57.4413.69%
transformer_blocks.35.attn2.to_out.093.7545.400.087%72.9113.30%
transformer_blocks.32.attn2.to_q93.587.140.012%16.6767.10%
transformer_blocks.47.attn2.to_q92.884.500.013%49.7278.52%
transformer_blocks.42.attn2.to_out.092.8052.220.101%19.6714.49%
transformer_blocks.45.attn2.to_out.092.4539.170.079%13.7628.92%
transformer_blocks.34.attn2.to_q92.064.770.016%17.3269.64%
transformer_blocks.44.attn2.to_out.092.0152.400.081%16.6418.46%
transformer_blocks.35.attn2.to_q91.935.090.016%15.9565.44%
transformer_blocks.39.attn2.to_q91.864.840.016%17.1066.19%
transformer_blocks.38.attn2.to_q91.364.950.014%15.8262.42%
Hot families

Late S2-O combines weight underflow and activation tail;S2-Q primarily exposes activation rowwise gain。

Selection use

固定 block 35–45 的 high-risk set,并构造 family/block-matched low-risk controls。

Non-claim

Risk percentile 不等于 failure probability,也不代表 media importance。

Engineering decision

当前允许做什么,不允许做什么

统计证据支持 candidate selection,而不支持直接修改 production quantization policy。

Evidence-supported actions

  • 保留 production tensorwise E4M3 作为 paired baseline。
  • 优先研究 late S2-O/S2-Q activation-side interventions。
  • 使用 family/block-matched low-risk layers 作为 negative control。
  • 若因果 lane 成立,再评估 α=.25 sparse residual kernel prototype。
  • 以 heldout cells 和最差 cell 作为 production gate。

Not supported by current evidence

  • Global dense clipping。
  • 仅因 weight outlier 高就全局改 output-channel weight scales。
  • 把 sparse-residual offline upper bound 当成可部署方案。
  • 由两个 calibration prompts 重新启用 global rowwise activation。
  • 将 local RelL2/MSE improvement 表述为 media quality improvement。
问题定量结果工程含义
Weight underflowρ=.812;channelwise underflow −93.89%Count-level effect 大且稳定。
Weight energy errorρ=−.046;global RelL2 2.6497%Extreme tail 不是当前 E4M3 total error 的主导因素。
Output-channel weight scaleGlobal MSE −0.476%修复大量低能量 underflow,但 energy gain 很小。
Dense clippingOptimistic oracle MSE −0.148%不构成有意义 production candidate。
Sparse α=.25MSE −2.995%;compression 1.958×仅为最早可考虑的 counterfactual Pareto reference。
Activation local errorρ=.380 / .442;family ε²=.658 / .687值得做定向 causal lanes,但不能全局推广。
Pre-registered next experiment

下一轮:从 descriptive statistics 进入 causal validation

优先固定 block 35–45 的 S2-O/S2-Q high-risk layers,并构造 family/block-matched low-risk controls。每个 lane 只改变一个因素。

B

Baseline

576 层 production tensorwise FP8。

W15

Weight rescue

仅 top-15 layers 使用 output-channel weight scale。

A15

Activation rescue

仅 top-15 layers 使用 dynamic rowwise activation。

BF15

Oracle

仅 top-15 layers 恢复 BF16 Linear,估计可恢复上限。

R15

Negative control

对 15 个 matched low-risk layers 做同样处理。

Minimum data matrix

至少 6 content prompts × 3 seeds = 18 paired cells。Calibration 仅用于固定 layer set 与 policy;最终结论只使用未参与选择的 heldout cells。Cell 是独立重采样单元,module calls 是嵌套观测;推荐 mixed-effects model 或 cluster bootstrap。

Required quality evidence

  • 逐层 output RelL2/cosine 与首次分叉位置
  • Video/audio latent 与 velocity paired error
  • Decoded video/audio quality 与 worst cell
  • AV consistency / perceptual review

Required systems evidence

  • DiT generated FPS 与 formal wall
  • Peak allocated/reserved memory
  • Fallback/upcast/scale bytes
  • 每 cell paired delta 与 determinism
local error ~ log activation-tail + family + NFE + chunk + (1 | module) + (1 | cell)
Limitations, provenance & embedded artifacts

证据边界与复现资产

Sampling boundary

Weight error、underflow 与 scale-grid 为全量精确值;weight quantiles 与 INT8 control 每层最多 262,144 samples。Activation amax 为 full call,percentiles 与 quant-error 为 bounded deterministic samples。

Population boundary

仅两个 prompts 且共享 seed,无法独立估计 prompt、seed 及交互。Family-stratified bootstrap 描述 layer-level association,不提供 system-quality approval。

Metric boundary

Weight-space isotropic L2 对 task importance 一视同仁;低能量 weight 仍可能被高幅 activation 放大。Local reconstruction 不可替代 end-to-end media metrics。

Counterfactual boundary

Sparse residual 假设 exact FP32 values + uint32 indices,不含 row pointers、alignment、kernel overhead 或 runtime;INT8 是 mechanism control,不是 production candidate。

Provenance summary

Experiment: catnip_fp8_outlier_statistics_v1
Checkpoint SHA256: d09adb8c85c1ae9681958e4c45b4f6bdcfc3e596d3782ab2f76bd9cd9824734c
Manifest SHA256: c085f53dbdac584a6f53b000ba5efb59892d512dcd9b42a4a8f8f53eb87acdf9
Raw JSONL SHA256: 9346a7013b56ba49724e1b7372756057ccdee4ff8f8ae7f225903a2be5a1add5
Random seed: 20260721

Embedded reproducibility artifacts

Technical PDF 与 primary analysis summary 可由页面顶部下载;以下附件同样直接内嵌于本 HTML。