Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RuntimeError: view size is not compatible with input tensor's size and stride (at least one dimension spans across two contiguous #31

Open
ghost opened this issue Jun 24, 2020 · 0 comments

Comments

@ghost
Copy link

ghost commented Jun 24, 2020

I followed all the instructions and get:

loading annotations into memory... loading annotations into memory... Done (t=0.43s) creating index... index created! Done (t=0.43s) creating index... index created! Traceback (most recent call last): File "./mmdetection/tools/train.py", line 108, in <module> main() File "./mmdetection/tools/train.py", line 104, in main logger=logger) File "/root/sharedfolder/production/2020/det/RepPoints/mmdetection/mmdet/apis/train.py", line 58, in train_detector _dist_train(model, dataset, cfg, validate=validate) File "/root/sharedfolder/production/2020/det/RepPoints/mmdetection/mmdet/apis/train.py", line 186, in _dist_train runner.run(data_loaders, cfg.workflow, cfg.total_epochs) File "/opt/conda/lib/python3.6/site-packages/mmcv/runner/runner.py", line 358, in run epoch_runner(data_loaders[i], **kwargs) File "/opt/conda/lib/python3.6/site-packages/mmcv/runner/runner.py", line 271, in train self.call_hook('after_train_iter') File "/opt/conda/lib/python3.6/site-packages/mmcv/runner/runner.py", line 229, in call_hook getattr(hook, fn_name)(self) File "/root/sharedfolder/production/2020/det/RepPoints/mmdetection/mmdet/core/utils/dist_utils.py", line 53, in after_train_iter runner.outputs['loss'].backward() File "/opt/conda/lib/python3.6/site-packages/torch/tensor.py", line 198, in backward torch.autograd.backward(self, gradient, retain_graph, create_graph) File "/opt/conda/lib/python3.6/site-packages/torch/autograd/__init__.py", line 99, in backward allow_unreachable=True) # allow_unreachable flag RuntimeError: view size is not compatible with input tensor's size and stride (at least one dimension spans across two contiguous subspaces). Use .reshape(...) instead.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

0 participants