pub fn forward_train_pipeline(
stages: &[TrainStage<'_>],
input_ids: &Tensor,
delta: Option<&TenantDelta>,
) -> Result<Tensor, Error>Expand description
Run the TTT/training forward across pipeline stages and return logits with the autograd graph intact across device boundaries.
input_ids is [batch, seq] and must already live on the first stage’s
device. Stages must be contiguous, gap-free, and cover 0..num_layers in
order (validated). The caller is responsible for wrapping this in
tch::with_grad and computing/backpropagating the loss.