fix(sp13): B0 cascade gap — 5 unaudited insert_batch call sites
The B0 audit (commit 62ab8ed85) under-counted insert_batch test
callers as 2 (1 production + 1 in-file unit test). Surfaced during
B1.0 implementation when cargo check --workspace --tests failed
with 5 arity-mismatch errors after B0's signature change.
Root cause: B0 audit's grep filter was `grep -v test` and didn't
enumerate crates/ml/src/trainers/dqn/smoke_tests/ (compiled as
part of the lib's test binary, not behind #[cfg(test)]) nor
crates/ml/tests/.
Sites fixed (zero-init i32 alloc, threaded through):
- crates/ml/src/trainers/dqn/smoke_tests/training_stability.rs:152, 196
- crates/ml/src/trainers/dqn/smoke_tests/performance.rs:142
- crates/ml/src/trainers/dqn/smoke_tests/gpu_residency.rs:75
- crates/ml/tests/gpu_per_integration_test.rs:125
No behavior change — the column carries zero data and no consumer
reads it pre-B1.1. B1.1 lands the producer kernel that fills with
-1/0/1 from the 30-bar price trajectory.
Process correction documented in docs/dqn-wire-up-audit.md
"B0.1 cascade-gap fix-up" subsection: future B-series audits must
run cargo check --workspace --tests before claiming cardinality
completeness.
Build: cargo check --workspace --tests clean.
Tests: cargo test -p ml --lib compiles + passes (GPU tests
#[ignore]-gated).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -139,7 +139,8 @@ fn test_per_sample_latency() -> anyhow::Result<()> {
|
||||
let actions = stream.alloc_zeros::<u32>(batch_insert).map_err(|e| anyhow::anyhow!("{e}"))?;
|
||||
let rewards = stream.clone_htod(&host_rewards).map_err(|e| anyhow::anyhow!("{e}"))?;
|
||||
let dones = stream.alloc_zeros::<f32>(batch_insert).map_err(|e| anyhow::anyhow!("{e}"))?;
|
||||
buf.insert_batch(&states, &next_states, &actions, &rewards, &dones, batch_insert)?;
|
||||
let aux_sign = stream.alloc_zeros::<i32>(batch_insert).map_err(|e| anyhow::anyhow!("aux_sign alloc: {e}"))?;
|
||||
buf.insert_batch(&states, &next_states, &actions, &rewards, &dones, &aux_sign, batch_insert)?;
|
||||
}
|
||||
assert_eq!(buf.len(), fill_count);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user