Comments (4)
It seems that the code cannot locate the input folder. Have you tried to use absolute path?
from bringing-old-photos-back-to-life.
After checking the error information, I suggest you could use the absolute path. Besides, it seems that the dlib library is not installed correctly which is used for face detection. I have not met this problem before.
from bringing-old-photos-back-to-life.
Having the absolute path (the full file path) works. But still can't solve the dlib problem. Any tips?
Also is there a way to bypass the CUDA out of memory? Should I like use the CPU or make the input image smaller?
Running Stage 1: Overall restoration
initializing the dataloader
model weights loaded
directory of testing image: G:\Bringing-Old-Photos-Back-to-Life\input
processing 31e3reott1i51.jpg
Traceback (most recent call last):
File "detection.py", line 151, in <module>
main(config)
File "detection.py", line 123, in main
P = torch.sigmoid(model(scratch_image))
File "E:\Anaconda3\envs\restore\lib\site-packages\torch\nn\modules\module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "G:\Bringing-Old-Photos-Back-to-Life\Global\detection_models\networks.py", line 119, in forward
x = up(x, blocks[-i - 1])
File "E:\Anaconda3\envs\restore\lib\site-packages\torch\nn\modules\module.py", line 722, in _call_impl
result = self.forward(*input, **kwargs)
File "G:\Bringing-Old-Photos-Back-to-Life\Global\detection_models\networks.py", line 167, in forward
out = torch.cat([up, crop1], 1)
RuntimeError: CUDA out of memory. Tried to allocate 368.00 MiB (GPU 0; 8.00 GiB total capacity; 5.66 GiB already allocated; 71.71 MiB free; 5.77 GiB reserved in total by PyTorch)
You are using NL + Res
Finish Stage 1 ...
Running Stage 2: Face Detection
Traceback (most recent call last):
File "detect_all_dlib.py", line 24, in <module>
import dlib
File "E:\Anaconda3\envs\restore\lib\site-packages\dlib\__init__.py", line 19, in <module>
from _dlib_pybind11 import *
ImportError: DLL load failed: The specified module could not be found.
Finish Stage 2 ...
Running Stage 3: Face Enhancement
The main GPU is
0
dataset [FaceTestDataset] of size 0 was created
The size of the latent vector size is [8,8]
Network [SPADEGenerator] was created. Total number of parameters: 92.1 million. To see the architecture, do print(network).
hi :)
Finish Stage 3 ...
Running Stage 4: Blending
Traceback (most recent call last):
File "align_warp_back_multiple_dlib.py", line 23, in <module>
import dlib
File "E:\Anaconda3\envs\restore\lib\site-packages\dlib\__init__.py", line 19, in <module>
from _dlib_pybind11 import *
ImportError: DLL load failed: The specified module could not be found.
Finish Stage 4 ...
All the processing is done. Please check the results.
Some screenshots that might help:
from bringing-old-photos-back-to-life.
Having the absolute path (the full file path) works. But still can't solve the dlib problem. Any tips?
Also is there a way to bypass the CUDA out of memory? Should I like use the CPU or make the input image smaller?
Sorry that this work requires the CUDA to work. If code runs out of memory, you can resize the image a little bit. For the dlib installation issue, maybe you can try to use WSL2 on windows.
For convenient usage, you can also try our Colab demo which allows uploading your own photos.
from bringing-old-photos-back-to-life.
Related Issues (20)
- Why do I get this error when I add my own photo
- MemoryError
- 代码里好多错误,pix2pixHD_model_DA.py里面的netE是什么了?
- how can I use my own model
- 很多很多问题,应该是没有再维护了
- 尝试从google.protobuf.internal模块导入名为'builder'的子模块时出现了问题
- Not working (conda with env) HOT 5
- Not working HOT 2
- Out of memory error
- : unrecognized arguments HOT 1
- Deprecated dependencies detected
- refined dockerfile HOT 2
- How can I use the GPU on the macbook(m1) ?
- No errors, but output images are blank/white
- IndexError: list index out of range (model on replicate.com) HOT 2
- cast error - line 219 in align_warp_back_multiple_dlib.py, using Python 3.10.12 HOT 1
- GUI warns it has gone commercial and a licence will be required
- Dlib dir
- Global and Face_Enhancement weights: Public access is not permitted on this storage account. HOT 1
- "Restore the photos with scratches" section fails with **"FileNotFoundError: [Errno 2] No such file or directory: '/content/photo_restoration/Global/checkpoints/detection/FT_Epoch_latest.pt'"** HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bringing-old-photos-back-to-life.