combine_dueling_outputs
python
combine_dueling_outputs(*, advantage: torch.Tensor, value: torch.Tensor, action_shape: int, num_atoms: int, advantage_centering: DuelingAdvantageCentering | None, categorical: bool) -> torch.TensorCombine advantage and value streams for duelling DQN.
Parameters:
advantage(Tensor) – Advantage stream output.value(Tensor) – Value stream output.action_shape(int) – Number of actions.num_atoms(int) – Number of categorical atoms.advantage_centering(DuelingAdvantageCentering | None) – Optional masked-mean centring for the advantage stream.categorical(bool) – Whether categorical output is enabled.
Returns:
Tensor– Combined logits or Q-values.