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

运行报错,求大神指导。代码有web交互的演示吗,我只找到了命令行运行 #8

Open
smokeshawn opened this issue Jun 12, 2023 · 0 comments

Comments

@smokeshawn
Copy link

PS D:\DragGAN_pytorch-main> python draggan_stylegan2_human.py
Traceback (most recent call last):
File "D:\DragGAN_pytorch-main\draggan_stylegan2_human.py", line 165, in
draggan = DragGAN("stylegan2-human-1024x1024.pt", device="cuda")
File "D:\DragGAN_pytorch-main\draggan_stylegan2_human.py", line 101, in init
self.G.load_state_dict(torch.load(ckpt))
with _open_file_like(f, 'rb') as opened_file:
File "d:\anaconda3\lib\site-packages\torch\serialization.py", line 321, in _open_file_like
return _open_file(name_or_buffer, mode)
File "d:\anaconda3\lib\site-packages\torch\serialization.py", line 302, in init
super().init(open(name, mode))
FileNotFoundError: [Errno 2] No such file or directory: 'stylegan2-human-1024x1024.pt'
PS D:\DragGAN_pytorch-main> python draggan_stylegan2_human.py
Setting up PyTorch plugin "bias_act_plugin"... Failed!
Traceback (most recent call last):
File "D:\DragGAN_pytorch-main\draggan_stylegan2_human.py", line 166, in
init_img = draggan.gen_image(seed=seed)
File "D:\DragGAN_pytorch-main\draggan_stylegan2_human.py", line 107, in gen_image
latent = self.G.mapping(z, label, truncation_psi=1.0, truncation_cutoff=None)
File "d:\anaconda3\lib\site-packages\torch\nn\modules\module.py", line 1502, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "d:\anaconda3\lib\site-packages\torch\nn\modules\module.py", line 1511, in _call_impl
return forward_call(*args, **kwargs)
File "D:\DragGAN_pytorch-main\training\networks_stylegan2_human.py", line 231, in forward
x = layer(x)
File "d:\anaconda3\lib\site-packages\torch\nn\modules\module.py", line 1502, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File "d:\anaconda3\lib\site-packages\torch\nn\modules\module.py", line 1511, in _call_impl
return forward_call(*args, **kwargs)
File "D:\DragGAN_pytorch-main\training\networks_stylegan2_human.py", line 119, in forward
x = bias_act.bias_act(x, b, act=self.activation)
File "D:\DragGAN_pytorch-main\torch_utils\ops\bias_act.py", line 84, in bias_act
if impl == 'cuda' and x.device.type == 'cuda' and _init():
File "D:\DragGAN_pytorch-main\torch_utils\ops\bias_act.py", line 41, in _init
_plugin = custom_ops.get_plugin(
File "D:\DragGAN_pytorch-main\torch_utils\custom_ops.py", line 84, in get_plugin
raise RuntimeError(f'Could not find MSVC/GCC/CLANG installation on this computer. Check _find_compiler_bindir() in "{file}".')
RuntimeError: Could not find MSVC/GCC/CLANG installation on this computer. Check find_compiler_bindir() in "D:\DragGAN_pytorch-main\torch_utils\custom
ops.py".

机器学习小白一名,跑大神的包出了各种错,建了个学友们的交流学习互助群,答疑解惑交流提高,欢迎各位大神加入
微信图片_20230612092519

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

1 participant