dectrfov / Wavelet-U-net-Dehazing

WAVELET U-NET AND THE CHROMATIC ADAPTATION TRANSFORM FOR SINGLE IMAGE DEHAZING - ICIP 2019
45 stars 6 forks source link

a problem with the backpropagation process #2

Open cloudyliy opened 3 years ago

cloudyliy commented 3 years ago

The following error occurred when running the code:

File "/home/xxx/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/tensor.py", line 102, in backward torch.autograd.backward(self, gradient, retain_graph, create_graph) File "/home/xxx/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/autograd/init.py", line 90, in backward allow_unreachable=True) # allow_unreachable flag RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation

It seems that there is a problem with the backpropagation process. Has the author encountered such a problem? My pytorch version is 1.1.0, thank you!

dectrfov commented 3 years ago

Thanks for your interest. Can you show the detailed error message? In our machine, I don't encounter this condition.

Best Regards

luoxiaodou commented 3 years ago

The following error occurred when running the code:

File "/home/xxx/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/tensor.py", line 102, in backward torch.autograd.backward(self, gradient, retain_graph, create_graph) File "/home/xxx/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/autograd/init.py", line 90, in backward allow_unreachable=True) # allow_unreachable flag RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation

It seems that there is a problem with the backpropagation process. Has the author encountered such a problem? My pytorch version is 1.1.0, thank you!

I also encounter the problem, do you solve it? Could you tell me the solutions?

zj1010 commented 1 year ago

The following error occurred when running the code: File "/home/xxx/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/tensor.py", line 102, in backward torch.autograd.backward(self, gradient, retain_graph, create_graph) File "/home/xxx/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/autograd/init.py", line 90, in backward allow_unreachable=True) # allow_unreachable flag RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation It seems that there is a problem with the backpropagation process. Has the author encountered such a problem? My pytorch version is 1.1.0, thank you!

I also encounter the problem, do you solve it? Could you tell me the solutions?

I met the same problem,do you solve it?

Ypigeon commented 7 months ago

运行代码时出现以下错误:文件“/home/xxx/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/tensor.py”第102行,向后torch.autograd.backward(自我,渐变,保留_graph,create_graph)文件“/home/xxx/anaconda3/envs/pytorch/lib/python3.6/site-packages/torch/autograd/init.py”,第90行,向后allow_unreachable=True) # allow_unreachable标志RuntimeError:梯度计算所需的一个变量就就地修改反向传播过程似乎存在问题。作者遇到过这样的问题吗?我的pytorch版本是1.1.0,谢谢!> >> >> > 我也遇到了这个问题,你解决了吗?你能告诉我解决方案吗?>> 我遇到了同样的问题,你解决了吗?

xiaowowwwww commented 6 months ago

Hello, I also have the above problem, I would like to ask if there is any solution? Thank you! Traceback (most recent call last): File "D:\Wavelet-U-net-Dehazing-master\train.py", line 130, in main(config_args) File "D:\Wavelet-U-net-Dehazing-master\train.py", line 96, in main loss.backward() File "D:\anaconda\envs\pytorch\lib\site-packages\torch_tensor.py", line 488, in backward torch.autograd.backward( File "D:\anaconda\envs\pytorch\lib\site-packages\torch\autograd__init__.py", line 197, in backward Variable._execution_engine.run_backward( # Calls into the C++ engine to run the backward pass RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation: [torch.cuda.FloatTensor [16, 4, 64, 64]], which is output 0 of AsStridedBackward0, is at version 16; expected version 15 instead. Hint: the backtrace further above shows the operation that failed to compute its gradient. The variable in question was changed in there or anywhere later. Good luck!