-
Notifications
You must be signed in to change notification settings - Fork 25.7k
Closed
Description
🐛 Bug
>>> 4 ** torch.tensor(0.5)
torch.tensor([2.])To Reproduce
Here is a regression test:
def test_rpow_scalar_float_shape():
assert (4 ** torch.tensor(0.5)).shape == ()Expected behavior
Binary op of (scalar, number) should be a scalar.
Environment
PyTorch version: 1.0.0
Is debug build: No
CUDA used to build PyTorch: None
OS: Mac OSX 10.14.1
GCC version: Could not collect
CMake version: version 3.12.0
Python version: 2.7
Is CUDA available: No
CUDA runtime version: No CUDA
GPU models and configuration: No CUDA
Nvidia driver version: No CUDA
cuDNN version: No CUDA
Versions of relevant libraries:
[pip] Could not collect
[conda] mkl 2018.0.2 1
[conda] mkl_fft 1.0.1 py27h917ab60_0
[conda] mkl_random 1.0.1 py27h78cc56f_0
[conda] torch 1.0.0 <pip>
[conda] torch-nightly 1.0.0.dev20181206 <pip>
[conda] torchfile 0.1.0 <pip>
[conda] torchvision 0.2.1 <pip>
Metadata
Metadata
Assignees
Labels
No labels