braintools.cogtask.execute_phase_packed#
- braintools.cogtask.execute_phase_packed(phase, ctx)[source]#
Variable-length / packed-mode dispatch for a single phase.
Unlike
execute_phase()the phase’s actual length is a tracedint32scalar; the buffer slot reserved for it is sized by the Python-intmax_steps. Leaf phases are run against a phase-local block of shape(max_dur, …), the block is gated to zero for positions beyond the traced actual length, and the block is then written into the trial-level buffers atctx.t_cursorviajax.lax.dynamic_update_slice. Compound phases dispatch to their ownexecute_packedimplementation; the runtime swap/gate/write happens at each leaf.- Return type: