Giter VIP home page Giter VIP logo

erasenet's People

Contributors

lcy0604 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

erasenet's Issues

测试结果异常

下载模型测试结果怎么会是这样的呢? StrOuput 的结果
118

RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation

Getting below error under pytorch version >1.4 . but it's good at pytorch 1.4.

RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation: [torch.FloatTensor [1, 512, 4, 4]] is at version 2; expected version 1 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!

tried to found and solve all inplace operation I can locate, but CANNOT get around still. Any ideas?

训练报错,根pytorch的版本有关

pytorch 1.13.1
cuda11.6

Traceback (most recent call last):
File "/EraseNet/train_STE.py", line 109, in
G_loss.backward()
File /.conda/envs/paddle_env/lib/python3.9/site-packages/torch/_tensor.py", line 488, in backward
torch.autograd.backward(
File ".conda/envs/paddle_env/lib/python3.9/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.FloatTensor [1, 512, 4, 4]] is at version 2; expected version 1 instead. Hint: enable anomaly detection to find the operation that failed to compute its gradient, with torch.autograd.set_detect_anomaly(True).

Multi GPU training error

Has anyone encountered such a mistake? When I replace a single GPU with multiple GPUs, I can't run.

THCudaCheck FAIL file=/tmp/pip-req-build-4baxydiv/aten/src/THCUNN/generic/LeakyReLU.cu line=56 error=77 : an illegal memory access was encountered
Traceback (most recent call last):
File "/lustre/home/phe/windows_pycharmProjects/EraseNet-master/train_STE.py", line 106, in
G_loss = criterion(imgs, masks, x_o1, x_o2, x_o3, fake_images, mm, gt, count, i)
File "/lustre/home/phe/miniconda3/envs/erasenet/lib/python3.7/site-packages/torch/nn/modules/module.py", line 541, in call
result = self.forward(*input, **kwargs)
File "/lustre/home/phe/miniconda3/envs/erasenet/lib/python3.7/site-packages/torch/nn/parallel/data_parallel.py", line 152, in forward
outputs = self.parallel_apply(replicas, inputs, kwargs)
File "/lustre/home/phe/miniconda3/envs/erasenet/lib/python3.7/site-packages/torch/nn/parallel/data_parallel.py", line 162, in parallel_apply
return parallel_apply(replicas, inputs, kwargs, self.device_ids[:len(replicas)])
File "/lustre/home/phe/miniconda3/envs/erasenet/lib/python3.7/site-packages/torch/nn/parallel/parallel_apply.py", line 85, in parallel_apply
output.reraise()
File "/lustre/home/phe/miniconda3/envs/erasenet/lib/python3.7/site-packages/torch/_utils.py", line 385, in reraise
raise self.exc_type(msg)
RuntimeError: Caught RuntimeError in replica 0 on device 0.
Original Traceback (most recent call last):
File "/lustre/home/phe/miniconda3/envs/erasenet/lib/python3.7/site-packages/torch/nn/parallel/parallel_apply.py", line 60, in _worker
output = module(*input, **kwargs)
File "/lustre/home/phe/miniconda3/envs/erasenet/lib/python3.7/site-packages/torch/nn/modules/module.py", line 541, in call
result = self.forward(*input, **kwargs)
File "/lustre/home/phe/windows_pycharmProjects/EraseNet-master/loss/Loss.py", line 60, in forward
D_loss.backward(retain_graph=True)
File "/lustre/home/phe/miniconda3/envs/erasenet/lib/python3.7/site-packages/torch/tensor.py", line 166, in backward
torch.autograd.backward(self, gradient, retain_graph, create_graph)
File "/lustre/home/phe/miniconda3/envs/erasenet/lib/python3.7/site-packages/torch/autograd/init.py", line 99, in backward
allow_unreachable=True) # allow_unreachable flag
RuntimeError: CUDA error: an illegal memory access was encountered

请问一下,擦除的效果是否会受到语言类型、图片背景的影响

你好,请问一下擦除效果会受到哪些因素影响,我使用你开源的模型进行文字擦除,效果不好,文本mask使用的文本检测模型,不知道是我代码问题,还是说受到训练数据的影响,导致我的预测结果不佳,图片的大小和非文本区域的数据分布会影响擦除效果吗,以下是我的原始图片ori和预测图片result
ori
result

pretrain model

Hi,thank u for your wonderful work and the open source code. do u have the plan to provide the pretrain model?

Inplace operation error

Any one met the same problem?
warnings.warn('Was asked to gather along dimension 0, but all ' Traceback (most recent call last): File "train_STE.py", line 109, in <module> G_loss.backward() File "/data1/xing_zhao/anaconda3/lib/python3.7/site-packages/torch/tensor.py", line 245, in backward torch.autograd.backward(self, gradient, retain_graph, create_graph, inputs=inputs) File "/data1/xing_zhao/anaconda3/lib/python3.7/site-packages/torch/autograd/__init__.py", line 147, in backward allow_unreachable=True, accumulate_grad=True) # allow_unreachable flag RuntimeError: one of the variables needed for gradient computation has been modified by an inplace operation: [torch.cuda.FloatTensor [1, 512, 4, 4]], which is output 38 of BroadcastBackward, is at version 2; expected version 1 instead. Hint: enable anomaly detection to find the operation that failed to compute its gradient, with torch.autograd.set_detect_anomaly(True).

Size mismatch error

Anyone met the same problem?
Traceback (most recent call last): File "train_STE.py", line 105, in <module> x_o1,x_o2,x_o3,fake_images,mm = netG(imgs) File "/data1/xing_zhao/anaconda3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 889, in _call_impl result = self.forward(*input, **kwargs) File "/data1/xing_zhao/anaconda3/lib/python3.7/site-packages/torch/nn/parallel/data_parallel.py", line 167, in forward outputs = self.parallel_apply(replicas, inputs, kwargs) File "/data1/xing_zhao/anaconda3/lib/python3.7/site-packages/torch/nn/parallel/data_parallel.py", line 177, in parallel_apply return parallel_apply(replicas, inputs, kwargs, self.device_ids[:len(replicas)]) File "/data1/xing_zhao/anaconda3/lib/python3.7/site-packages/torch/nn/parallel/parallel_apply.py", line 86, in parallel_apply output.reraise() File "/data1/xing_zhao/anaconda3/lib/python3.7/site-packages/torch/_utils.py", line 429, in reraise raise self.exc_type(msg) RuntimeError: Caught RuntimeError in replica 0 on device 0. Original Traceback (most recent call last): File "/data1/xing_zhao/anaconda3/lib/python3.7/site-packages/torch/nn/parallel/parallel_apply.py", line 61, in _worker output = module(*input, **kwargs) File "/data1/xing_zhao/anaconda3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 889, in _call_impl result = self.forward(*input, **kwargs) File "/DeepLearning/xing_zhao/inpainting/EraseNet-master/models/sa_gan.py", line 203, in forward x = torch.cat([self.lateral_connection3(con_x2), x], dim=1) RuntimeError: Sizes of tensors must match except in dimension 2. Got 32 and 31 (The offending index is 0)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.