Archive CIDM-v2 reproducible b2_r4_tangent_controllability.py
Browse files
cidm_v2/source/B2_R4_P0/b2_r4_tangent_controllability.py
ADDED
|
@@ -0,0 +1,270 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""CIDM-v2 B2-R4/P0: frozen decoder tangent/latent-operator controllability audit.
|
| 2 |
+
|
| 3 |
+
NO training; one-step label-informed ORACLE interventions are RETROSPECTIVE diagnostic
|
| 4 |
+
reference corrections and MUST NEVER be marketed as deployable forecasts. Official test
|
| 5 |
+
split is used ONLY to replay unchanged historical baseline checkpoints.
|
| 6 |
+
"""
|
| 7 |
+
from __future__ import annotations
|
| 8 |
+
import os, math, io, json, csv, zipfile, hashlib, random, time
|
| 9 |
+
from pathlib import Path
|
| 10 |
+
import numpy as np
|
| 11 |
+
import torch
|
| 12 |
+
from torch.nn import functional as F
|
| 13 |
+
from benchmark import Config, Windows, fetch_official, make_cache, make_synthetic_cache, UnifiedModel
|
| 14 |
+
from b2_r1_flux_control import check_zip, get_core, assess as baseline_assess
|
| 15 |
+
from b2_r3_readout_probe import original_parity
|
| 16 |
+
|
| 17 |
+
PARENT_SHA='69552b29e169ec22ee85d9c1b1a678fdb188f6f25dc18f33b927b88f4dddffd4'
|
| 18 |
+
TASKS=('burgers_1d','reacdiff_2d','swe_2d')
|
| 19 |
+
SEEDS=(17,41,73)
|
| 20 |
+
LEADS=(1,3,6,9,12)
|
| 21 |
+
WINDOWS_PER_SEED=8
|
| 22 |
+
BUDGETS=(.01,.05)
|
| 23 |
+
|
| 24 |
+
|
| 25 |
+
def file_sha(path):
|
| 26 |
+
h=hashlib.sha256()
|
| 27 |
+
with open(path,'rb') as f:
|
| 28 |
+
for x in iter(lambda:f.read(1<<21),b''):h.update(x)
|
| 29 |
+
return h.hexdigest()
|
| 30 |
+
|
| 31 |
+
|
| 32 |
+
def write_json(path,obj):
|
| 33 |
+
p=Path(path);p.parent.mkdir(parents=True,exist_ok=True)
|
| 34 |
+
p.write_text(json.dumps(obj,ensure_ascii=False,indent=2,allow_nan=False),encoding='utf8')
|
| 35 |
+
|
| 36 |
+
|
| 37 |
+
def write_csv(path,rows):
|
| 38 |
+
if not rows:return
|
| 39 |
+
p=Path(path);p.parent.mkdir(parents=True,exist_ok=True)
|
| 40 |
+
with open(p,'w',newline='',encoding='utf-8') as f:
|
| 41 |
+
w=csv.DictWriter(f,fieldnames=list(rows[0]));w.writeheader();w.writerows(rows)
|
| 42 |
+
|
| 43 |
+
|
| 44 |
+
def sample_rms(x):
|
| 45 |
+
return x.float().square().flatten(1).mean(1).clamp_min(1e-30).sqrt().view(-1,1,1,1)
|
| 46 |
+
|
| 47 |
+
|
| 48 |
+
def flatten_cos(a,b):
|
| 49 |
+
af=a.flatten(1);bf=b.flatten(1)
|
| 50 |
+
return (af*bf).sum(1)/(af.norm(dim=1)*bf.norm(dim=1)).clamp_min(1e-20)
|
| 51 |
+
|
| 52 |
+
|
| 53 |
+
def scalar_list(t):return [float(x) for x in t.detach().cpu().flatten()]
|
| 54 |
+
|
| 55 |
+
|
| 56 |
+
def span_project(grad,vectors):
|
| 57 |
+
# Numerical orthonormalization on individual samples (nonzero vectors only).
|
| 58 |
+
B=grad.shape[0];g=grad.flatten(1);result=torch.zeros_like(g);Q=[]
|
| 59 |
+
for vv in vectors:
|
| 60 |
+
v=vv.flatten(1).detach().float()
|
| 61 |
+
for q in Q: v=v-(v*q).sum(1,keepdim=True)*q
|
| 62 |
+
vnorm=v.norm(dim=1,keepdim=True)
|
| 63 |
+
valid=vnorm>1e-9
|
| 64 |
+
q=torch.where(valid,v/vnorm.clamp_min(1e-9),torch.zeros_like(v))
|
| 65 |
+
Q.append(q)
|
| 66 |
+
result=result+(g*q).sum(1,keepdim=True)*q
|
| 67 |
+
frac=(result.square().sum(1)/g.square().sum(1).clamp_min(1e-30)).clamp(min=0,max=1)
|
| 68 |
+
return result.reshape_as(grad),frac
|
| 69 |
+
|
| 70 |
+
|
| 71 |
+
@torch.no_grad()
|
| 72 |
+
def exact_rollout_states(core,history,leads=LEADS):
|
| 73 |
+
mm=core.model
|
| 74 |
+
h=history.unsqueeze(-2) if history.ndim==4 else history
|
| 75 |
+
B,L,C,H,W=h.shape
|
| 76 |
+
z=mm.encode(h.reshape(B,L*C,H,W));prev=h[:,-1];coeff=mm.coefficients();skew=mm.skew-mm.skew.T
|
| 77 |
+
states={}
|
| 78 |
+
for step in range(1,max(leads)+1):
|
| 79 |
+
flux=coeff['flux']*mm.flux(z)
|
| 80 |
+
local=coeff['local']*torch.tanh(mm.local(z))
|
| 81 |
+
skew_part=.035*torch.einsum('ij,bjhw->bihw',skew,z)
|
| 82 |
+
z=z+flux+local+skew_part
|
| 83 |
+
logit=mm.decode(z)
|
| 84 |
+
increment=coeff['out']*torch.tanh(logit)
|
| 85 |
+
current=prev+increment
|
| 86 |
+
if step in leads:
|
| 87 |
+
states[step]={'z':z.detach(),'prev':prev.detach(),'pred':current.detach(),
|
| 88 |
+
'flux':flux.detach(),'local':local.detach(),'skew':skew_part.detach(),
|
| 89 |
+
'logit':logit.detach()}
|
| 90 |
+
prev=current
|
| 91 |
+
return states
|
| 92 |
+
|
| 93 |
+
|
| 94 |
+
def oracle_batch(core,states,targets,sd,lead,seed=0):
|
| 95 |
+
"""Future truth is ONLY used to calculate diagnostic gradient and upper bounds.
|
| 96 |
+
This is NOT an issue-time deployable correction and never trains parameters."""
|
| 97 |
+
mm=core.model;coeff=mm.coefficients();z=states['z'].detach().float();pred=states['pred'].detach().float();prev=states['prev'].detach().float()
|
| 98 |
+
truth=targets[:,lead-1].detach().float()
|
| 99 |
+
sd=sd.float().to(z.device).reshape(1,-1,1,1)
|
| 100 |
+
with torch.enable_grad():
|
| 101 |
+
zvar=z.clone().requires_grad_(True)
|
| 102 |
+
predvar=prev+coeff['out']*torch.tanh(mm.decode(zvar))
|
| 103 |
+
reconstruction=float((predvar.detach()-pred).abs().max().item())
|
| 104 |
+
if reconstruction>2e-5:raise RuntimeError('EXACT_READOUT_MISMATCH:'+str(reconstruction))
|
| 105 |
+
loss_per=((predvar-truth)*sd).square().flatten(1).mean(1)
|
| 106 |
+
grad=torch.autograd.grad(loss_per.sum(),zvar,create_graph=False)[0].detach()
|
| 107 |
+
if not torch.isfinite(grad).all():raise RuntimeError('ORACLE_NONFINITE_GRAD')
|
| 108 |
+
base=loss_per.detach().float().clamp_min(1e-22)
|
| 109 |
+
span,frac=span_project(grad,[states[k] for k in ('flux','local','skew')])
|
| 110 |
+
gnorm=sample_rms(grad);snorm=sample_rms(span)
|
| 111 |
+
normal=grad/gnorm.clamp_min(1e-18)
|
| 112 |
+
span_normal=span/snorm.clamp_min(1e-18)
|
| 113 |
+
# Fixed seeded reference; no information from future labels in random control.
|
| 114 |
+
generator=torch.Generator(device='cpu').manual_seed(int(seed))
|
| 115 |
+
noise=torch.randn(z.shape,generator=generator,dtype=z.dtype,device='cpu').to(z.device)
|
| 116 |
+
noise_normal=noise/sample_rms(noise).clamp_min(1e-18)
|
| 117 |
+
zscale=sample_rms(z).clamp_min(1.0)
|
| 118 |
+
out={'tangent_oracle_future_truth_used':1,
|
| 119 |
+
'base_mse_physical':scalar_list(base),
|
| 120 |
+
'decoder_abslogit_gt2':scalar_list((states['logit'].abs()>2).float().flatten(1).mean(1)),
|
| 121 |
+
'grad_rms':scalar_list(gnorm),
|
| 122 |
+
'operator_grad_projection_fraction':scalar_list(frac),
|
| 123 |
+
'cos_descent_flux':scalar_list(flatten_cos(-grad,states['flux'])),
|
| 124 |
+
'cos_descent_local':scalar_list(flatten_cos(-grad,states['local'])),
|
| 125 |
+
'cos_descent_skew':scalar_list(flatten_cos(-grad,states['skew'])),
|
| 126 |
+
'latent_rms':scalar_list(sample_rms(z)),
|
| 127 |
+
'max_readout_reconstruction_error':reconstruction}
|
| 128 |
+
for budget in BUDGETS:
|
| 129 |
+
for name,move in [('full_gradient_oracle',normal),('operator_span_oracle',span_normal),('random_control',noise_normal)]:
|
| 130 |
+
shifted=z-budget*zscale*move if name!='random_control' else z+budget*zscale*move
|
| 131 |
+
with torch.no_grad():
|
| 132 |
+
estimate=prev+coeff['out']*torch.tanh(mm.decode(shifted))
|
| 133 |
+
after=((estimate-truth)*sd).square().flatten(1).mean(1)
|
| 134 |
+
out[f'{name}_mse_ratio_at_{budget:.2f}']=scalar_list(after/base)
|
| 135 |
+
return out
|
| 136 |
+
|
| 137 |
+
|
| 138 |
+
def calc(task,seed,core,cache,device,indices,smoke=False):
|
| 139 |
+
core.eval().requires_grad_(False)
|
| 140 |
+
val=Windows(cache['splits']['val']['h'],cache['splits']['val']['y'],cache['mean'],cache['std'])
|
| 141 |
+
sd=val.sd.to(device)
|
| 142 |
+
rows=[];batch=2 if not task.endswith('_1d') else 4
|
| 143 |
+
for start in range(0,len(indices),batch):
|
| 144 |
+
group=indices[start:start+batch]
|
| 145 |
+
samples=[val[i] for i in group]
|
| 146 |
+
h=torch.stack([x[0] for x in samples],0).to(device)
|
| 147 |
+
y=torch.stack([x[1] for x in samples],0).to(device)
|
| 148 |
+
if y.ndim==4:y=y.unsqueeze(-2)
|
| 149 |
+
states=exact_rollout_states(core,h)
|
| 150 |
+
for lead,s in states.items():
|
| 151 |
+
# Predictions and states are read-only; ground truth only in oracle_batch (diagnostics).
|
| 152 |
+
diag=oracle_batch(core,s,y,sd,lead,seed=seed*100003+lead*1009+start)
|
| 153 |
+
for ii,idx in enumerate(group):
|
| 154 |
+
row={'task':task,'seed':seed,'window_index':idx,'lead':lead,
|
| 155 |
+
'smoke_only':int(smoke)}
|
| 156 |
+
for key,v in diag.items():
|
| 157 |
+
row[key]=v[ii] if isinstance(v,list) else v
|
| 158 |
+
rows.append(row)
|
| 159 |
+
return rows
|
| 160 |
+
|
| 161 |
+
|
| 162 |
+
def aggregations(rows):
|
| 163 |
+
by={}
|
| 164 |
+
for r in rows:by.setdefault((r['task'],r['seed'],r['lead']),[]).append(r)
|
| 165 |
+
result=[]
|
| 166 |
+
for (task,seed,lead),xx in sorted(by.items()):
|
| 167 |
+
rr={'task':task,'seed':seed,'lead':lead,'windows':len(xx)}
|
| 168 |
+
for k in xx[0]:
|
| 169 |
+
if k in rr or k in ('window_index','smoke_only','task','seed','lead','tangent_oracle_future_truth_used'):continue
|
| 170 |
+
vv=np.asarray([v[k] for v in xx],dtype=float)
|
| 171 |
+
if not np.isfinite(vv).all():raise RuntimeError('NONFINITE_DIAGNOSTIC:'+k)
|
| 172 |
+
rr[k]=float(vv.mean())
|
| 173 |
+
result.append(rr)
|
| 174 |
+
return result
|
| 175 |
+
|
| 176 |
+
|
| 177 |
+
def interpret(rows):
|
| 178 |
+
"""Predeclared descriptive labels, NOT permission for formal training."""
|
| 179 |
+
a=aggregations(rows);out={}
|
| 180 |
+
for task in TASKS:
|
| 181 |
+
for lead in (1,12):
|
| 182 |
+
selected=[r for r in a if r['task']==task and r['lead']==lead]
|
| 183 |
+
if not selected:continue
|
| 184 |
+
avg=lambda k:sum(x[k] for x in selected)/len(selected)
|
| 185 |
+
out[f'{task}_lead{lead}']={
|
| 186 |
+
'grad_oracle_ratio_1pct':avg('full_gradient_oracle_mse_ratio_at_0.01'),
|
| 187 |
+
'grad_oracle_ratio_5pct':avg('full_gradient_oracle_mse_ratio_at_0.05'),
|
| 188 |
+
'operator_span_ratio_5pct':avg('operator_span_oracle_mse_ratio_at_0.05'),
|
| 189 |
+
'random_ratio_5pct':avg('random_control_mse_ratio_at_0.05'),
|
| 190 |
+
'operator_gradient_capture_fraction':avg('operator_grad_projection_fraction'),
|
| 191 |
+
'decoder_saturation_fraction':avg('decoder_abslogit_gt2')}
|
| 192 |
+
# Diagnostics never grants model training; mechanistic categories descriptive only.
|
| 193 |
+
return out
|
| 194 |
+
|
| 195 |
+
|
| 196 |
+
def run(parent,root,out,smoke=False):
|
| 197 |
+
out=Path(out);out.mkdir(parents=True,exist_ok=True)
|
| 198 |
+
if smoke:
|
| 199 |
+
cfg=Config(profile='smoke',history=4,train_horizon=6,eval_horizon=12)
|
| 200 |
+
cache=make_synthetic_cache(cfg)
|
| 201 |
+
# 1D and 2D synthetic each, run through exact original ported backbone
|
| 202 |
+
rows=[]
|
| 203 |
+
for task,one_dim in [('smoke_1d',True),('smoke_2d',False)]:
|
| 204 |
+
src=cache if not one_dim else {
|
| 205 |
+
**cache,'splits':{k:{'h':v['h'].mean(dim=-2) if v['h'].ndim==5 else v['h'],
|
| 206 |
+
'y':v['y'].mean(dim=-2) if v['y'].ndim==5 else v['y']}
|
| 207 |
+
for k,v in cache['splits'].items()}}
|
| 208 |
+
ch=int(src['splits']['train']['h'].shape[2]);core=UnifiedModel('V2_Ported_R5',ch,8,12,4).eval()
|
| 209 |
+
# For a 2D grid synthetic smoke, must keep channel and width matches expected.
|
| 210 |
+
r=calc(task,17,core,src,'cpu',[0,1],smoke=True)
|
| 211 |
+
rows.extend(r)
|
| 212 |
+
write_csv(out/'sample_oracle_diagnostics.csv',rows)
|
| 213 |
+
write_csv(out/'lead_seed_summary.csv',aggregations(rows))
|
| 214 |
+
result={'experiment':'B2-R4/P0','status':'PROGRAM_ONLY_SMOKE','sample_rows':len(rows),
|
| 215 |
+
'warning':'Synthetic smoke is NOT official PDEBench evidence; label-conditioned oracle is NOT deployable.'}
|
| 216 |
+
else:
|
| 217 |
+
if file_sha(parent)!=PARENT_SHA:raise RuntimeError('PARENT_SHA_MISMATCH')
|
| 218 |
+
allrows=[];replays=[];cfg=None
|
| 219 |
+
with zipfile.ZipFile(parent) as zp:
|
| 220 |
+
manifest,contract=check_zip(zp)
|
| 221 |
+
cfg=Config(**manifest['config'])
|
| 222 |
+
for task in TASKS:
|
| 223 |
+
datafile=fetch_official(Path(root)/'official_data',task)
|
| 224 |
+
cache=make_cache(task,datafile,cfg,Path(root)/'window_cache')
|
| 225 |
+
contract_row=next(v for v in contract['tasks'] if v['task']==task)
|
| 226 |
+
if cache['signature']['source_md5']!=contract_row['source_md5'] or cache['ids']!=contract_row['ids']:
|
| 227 |
+
raise RuntimeError('PDEBENCH_DATA_SIGNATURE_OR_SPLIT_MISMATCH:'+task)
|
| 228 |
+
if any(len(cache['splits'][s]['h'])!=contract_row['windows'][s] for s in ('train','val','test')):
|
| 229 |
+
raise RuntimeError('WINDOW_COUNT_MISMATCH:'+task)
|
| 230 |
+
for seed in SEEDS:
|
| 231 |
+
device='cuda' if torch.cuda.is_available() else 'cpu'
|
| 232 |
+
core,checkpoint_hash=get_core(zp,cache,task,seed,device)
|
| 233 |
+
batch=cfg.batch_1d if task.endswith('_1d') else cfg.batch_2d
|
| 234 |
+
original=float(json.loads(zp.read(f'{task}__V2_Ported_R5__seed{seed}.json'))['test']['model_12'])
|
| 235 |
+
test=baseline_assess(core,'baseline',cache,'test',device,batch=batch)['rmse12']
|
| 236 |
+
if abs(test-original)>max(1e-5,original*.001):
|
| 237 |
+
raise RuntimeError(f'FAIL_CLOSED_BASELINE_REPLAY {task} {seed}: {test} vs {original}')
|
| 238 |
+
tset=Windows(cache['splits']['val']['h'],cache['splits']['val']['y'],cache['mean'],cache['std'])
|
| 239 |
+
h=torch.stack([tset[i][0] for i in range(min(2,len(tset)))],0).to(device)
|
| 240 |
+
parity=original_parity(core,h)
|
| 241 |
+
if parity>2e-6:raise RuntimeError('OFFICIAL_PARITY_MISMATCH')
|
| 242 |
+
replays.append({'task':task,'seed':seed,'checkpoint_sha256':checkpoint_hash,
|
| 243 |
+
'expected_test_rmse12':original,'replay_test_rmse12':test,'max_forward_difference':parity})
|
| 244 |
+
indices=list(range(min(WINDOWS_PER_SEED,len(tset))))
|
| 245 |
+
if len(indices)!=WINDOWS_PER_SEED:raise RuntimeError('VAL_WINDOWS_TOO_FEW')
|
| 246 |
+
part=calc(task,seed,core,cache,device,indices,smoke=False)
|
| 247 |
+
allrows.extend(part)
|
| 248 |
+
write_csv(out/'sample_oracle_diagnostics.csv',allrows)
|
| 249 |
+
write_csv(out/'exact_replay.csv',replays)
|
| 250 |
+
print('[B2-R4]',task,'seed',seed,'rows',len(part),'test RMSE replay',test,flush=True)
|
| 251 |
+
summary=aggregations(allrows)
|
| 252 |
+
write_csv(out/'lead_seed_summary.csv',summary)
|
| 253 |
+
missing=sorted(set((t,s,l) for t in TASKS for s in SEEDS for l in LEADS)-set((r['task'],r['seed'],r['lead']) for r in summary))
|
| 254 |
+
if missing or len(replays)!=9 or len(summary)!=45 or len(allrows)!=9*5*WINDOWS_PER_SEED:
|
| 255 |
+
raise RuntimeError('INCOMPLETE_MECHANISM_COVERAGE:'+repr(missing))
|
| 256 |
+
result={'experiment':'CIDM-v2 B2-R4/P0 Decoder Tangent and Operator Span Audit',
|
| 257 |
+
'status':'FROZEN_TANGENT_DIAGNOSTIC_COMPLETED_NO_TRAINING',
|
| 258 |
+
'parent_sha256':PARENT_SHA,'official_baseline_replays':len(replays),
|
| 259 |
+
'task_seed_lead_groups':len(summary),'diagnostic_sample_rows':len(allrows),
|
| 260 |
+
'interventions':'ORACLE_FUTURE_TRUTH_DIAGNOSTIC_ONLY',
|
| 261 |
+
'source_of_oracle_information':'Future truth on validation used ONLY to compute gradients and numerical diagnostic reference values, never as a forecast input.',
|
| 262 |
+
'summary':interpret(allrows),
|
| 263 |
+
'qualification':'DIAGNOSTIC_ONLY_DOES_NOT_AUTHORIZE_TRAINING',
|
| 264 |
+
'limits':['Oracle label-conditioned latent shifts are not deployable and must not be compared to AI Weather Quest models.',
|
| 265 |
+
'Decoder tangent controllability is local to learned latent coordinates and fixed perturbation budgets.',
|
| 266 |
+
'Operator-span projection is only three global latent update directions per sample; low dimension limits raw captured fraction.',
|
| 267 |
+
'Previous B0 checkpoint selection used validation; this is not fresh holdout science.',
|
| 268 |
+
'No optimizers, no finetuning, no future truth entered model rollout.']}
|
| 269 |
+
write_json(out/'report.json',result)
|
| 270 |
+
return result
|