title: Multiply all elements of PyTorch tensor
body: <p>I wanted to do something like this <a href="https://stackoverflow.com/questions/44064753/multiply-all-elements-of-tensor-in-tensorflow">question</a> in PyTorch i.e. multiply all elements with each other keeping a certain axis constant. Does PyTorch has any pre-defined function for this?</p>