## diag_ppo_fullbuffer.nim — run ppoUpdate on a FULL 8192-transition buffer. ## Verifies whether the round-10 death (first ppoUpdate at buffer capacity) ## is a real crash in ppoUpdate or purely the saveAdamStates empty-shape bug. import std/[math, random] import arraymancer import PPO_Bot/network import PPO_Bot/training var ac = initActorCritic() var adam: ACAdamStates # uninitialised → ppoUpdate must reinit (fresh-process path) var buf = initTrajectoryBuffer() randomize(1) while buf.len < MAX_TRANSITIONS: var t: Transition for i in 0..