Skip to content

Commit

Permalink
fix bug on prediction
Browse files Browse the repository at this point in the history
  • Loading branch information
Mamba413 committed Jul 15, 2024
1 parent 3b15aa5 commit 2520211
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion d3rlpy/algos/qlearning/torch/ddpg_impl.py
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ def compute_target(self, batch: TorchMiniBatch) -> torch.Tensor:
pass

def inner_predict_best_action(self, x: TorchObservation) -> torch.Tensor:
return torch.argmax(self._modules.policy(x).mean).unsqueeze(0)
return torch.argmax(self._modules.policy(x).probs).unsqueeze(0)

@abstractmethod
def inner_sample_action(self, x: TorchObservation) -> torch.Tensor:
Expand Down

0 comments on commit 2520211

Please sign in to comment.