pkhungurn / talking-head-anime-demo

Demo for the "Talking Head Anime from a Single Image."
MIT License
1.99k stars 286 forks source link

I have new GPU driver,but..... #12

Open albbzmkh opened 4 years ago

albbzmkh commented 4 years ago

Exception in Tkinter callback Traceback (most recent call last): File "D:\PYTHON\anaconda\lib\tkinter__init.py", line 1705, in call__ return self.func(*args) File "D:/OneDrive/Python/aa/talking-head-anime-demo/app/puppeteer.py", line 94, in load_image self.load_image_from_file(file_name) File "D:/OneDrive/Python/aa/talking-head-anime-demo/app/puppeteer.py", line 106, in load_image_from_file self.source_image = extract_pytorch_image_from_filelike(file_name).to(self.torch_device).unsqueeze(dim=0) File "D:\PYTHON\anaconda\lib\site-packages\torch\cuda__init.py", line 196, in _lazy_init _check_driver() File "D:\PYTHON\anaconda\lib\site-packages\torch\cuda\init__.py", line 101, in _check_driver http://www.nvidia.com/Download/index.aspx""") AssertionError: Found no NVIDIA driver on your system. Please check that you have an NVIDIA GPU and installed a driver from http://www.nvidia.com/Download/index.aspx [ WARN:0] terminating async callback

dragonmeteor commented 4 years ago

Sorry for the late reply.

First, let us confirm one thing. Do you have an Nvidia GPU? You said you have a new driver, but you didn't say you have such a GPU.

sheiun commented 4 years ago

@albbzmkh You need to make sure torch.cuda.device_count() is greater than 0

drojf commented 4 years ago

@dragonmeteor you may want to explicitly add to the readme that you need a NVIDIA GPU/Cuda capable gpu to use this, as it's not stated there as a requirement.

I did try running in CPU-only mode, but since I don't really know what I'm doing, I'm unsure whether it's CPU-only is supported or if I was doing something else wrong. I assume it's just not supported.

edit: After changing the appropriate line to use CPU mode, it's definitely too slow to use in CPU mode, a GPU is required.

Exception in Tkinter callback
Traceback (most recent call last):
  File "C:\Users\drojf\AppData\Local\Programs\Python\Python37\lib\tkinter\__init__.py", line 1705, in __call__
    return self.func(*args)
  File "C:\Users\drojf\AppData\Local\Programs\Python\Python37\lib\tkinter\__init__.py", line 749, in callit
    func(*args)
  File "app/manual_poser.py", line 102, in update_image
    self.update_pose()
  File "app/manual_poser.py", line 96, in update_pose
    self.current_pose = torch.zeros(self.pose_size, device=self.torch_device)
  File "C:\Users\drojf\AppData\Local\Programs\Python\Python37\lib\site-packages\torch\cuda\__init__.py", line 196, in _lazy_init
    _check_driver()
  File "C:\Users\drojf\AppData\Local\Programs\Python\Python37\lib\site-packages\torch\cuda\__init__.py", line 94, in _check_driver
    raise AssertionError("Torch not compiled with CUDA enabled")
AssertionError: Torch not compiled with CUDA enabled
dragonmeteor commented 4 years ago

I've updated the README to say that a GPU is required.

You can definitely run the code with only a CPU, but it is hopelessly slow.