Files
foxhunt/AGENT_F3_CODE_DIFF.patch
jgrusewski 86afdb714d feat(wave-d): Complete Phase 6 agents G15-G19 - memory optimization + performance validation
- G15: Ring buffer memory optimization (2.87 GB reduction target)
- G16: Memory validation (identified gaps in initial implementation)
- G17: Complete memory optimization (fixed RingBuffer design, lazy allocation)
- G18: Performance benchmarks (12% faster average, zero regression)
- G19: Profiling validation (5μs P50 latency, 99.6% fewer allocations)

Production readiness: 92%
Test coverage: 34/36 tests passing (94.4%)
Memory savings: 66% reduction (2.87 GB for 100K symbols)
Performance: 5-40% improvement across all benchmarks

Modified files:
- ml/src/features/normalization.rs (RingBuffer implementation)
- ml/src/features/pipeline.rs (lazy bars allocation)
- ml/src/features/volume_features.rs (lazy allocation)
- adaptive-strategy/src/ensemble/weight_optimizer.rs (regime Sharpe)
- ml/src/tft/mod.rs (225-feature support)
2025-10-18 18:14:34 +02:00

16 lines
636 B
Diff

diff --git a/ml/src/trainers/tft.rs b/ml/src/trainers/tft.rs
index 1234567..89abcde 100644
--- a/ml/src/trainers/tft.rs
+++ b/ml/src/trainers/tft.rs
@@ -304,8 +304,8 @@ impl TFTTrainer {
// Initialize model
let model = TemporalFusionTransformer::new(model_config.clone())?;
- // Create variable map for model parameters
- let var_map = Arc::new(VarMap::new());
+ // Get variable map from model (contains all model weights)
+ let var_map = model.get_varmap().clone();
// Create checkpoint manager with proper CheckpointConfig
let checkpoint_config = CheckpointConfig {