RuntimeError: min(): Expected reduction dim to be specified for input.numel() == 0. Specify the reduction dim with the 'dim' argument. #302
wangji0420
started this conversation in
General
Replies: 1 comment
-
any solutions? met with the same error, not sure if any packages's vesion is not suitable. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Traceback (most recent call last):
File "/workspace/train_ms.py", line 839, in
run()
File "/workspace/train_ms.py", line 374, in run
train_and_evaluate(
File "/workspace/train_ms.py", line 469, in train_and_evaluate
) = net_g(
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1518, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1527, in _call_impl
return forward_call(*args, **kwargs)
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/parallel/distributed.py", line 1519, in forward
else self._run_ddp_forward(*inputs, **kwargs)
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/parallel/distributed.py", line 1355, in _run_ddp_forward
return self.module(*inputs, **kwargs) # type: ignore[index]
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1518, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1527, in _call_impl
return forward_call(*args, **kwargs)
File "/workspace/models.py", line 993, in forward
l_length_sdp = self.sdp(x, x_mask, w, g=g)
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1518, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1527, in _call_impl
return forward_call(*args, **kwargs)
File "/workspace/models.py", line 220, in forward
z_q, logdet_q = flow(z_q, x_mask, g=(x + h_w))
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1518, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "/home/vscode/venv/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1527, in _call_impl
return forward_call(*args, **kwargs)
File "/workspace/modules.py", line 501, in forward
x1, logabsdet = piecewise_rational_quadratic_transform(
File "/workspace/transforms.py", line 31, in piecewise_rational_quadratic_transform
outputs, logabsdet = spline_fn(
File "/workspace/transforms.py", line 82, in unconstrained_rational_quadratic_spline
) = rational_quadratic_spline(
File "/workspace/transforms.py", line 114, in rational_quadratic_spline
if torch.min(inputs) < left or torch.max(inputs) > right:
RuntimeError: min(): Expected reduction dim to be specified for input.numel() == 0. Specify the reduction dim with the 'dim' argument.
Beta Was this translation helpful? Give feedback.
All reactions