Closed Athospd closed 5 years ago
This PR implements tch_prod and its method.
Just a note: torch::Tensor::prod() shows 5 ways to pass parameters. The 3rd and 5th differs only by keepdim type: NULL or bool.
keepdim
I chose to check it at R side and always pass keepdim as bool when dim is not null.
dim
I checked the outputs with pytorch.
This PR implements tch_prod and its method.
Just a note: torch::Tensor::prod() shows 5 ways to pass parameters. The 3rd and 5th differs only by
keepdim
type: NULL or bool.I chose to check it at R side and always pass
keepdim
as bool whendim
is not null.I checked the outputs with pytorch.