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

dcp_dir is not defined (ESRGAN) #11

Open
Eidenz opened this issue Jun 25, 2020 · 5 comments
Open

dcp_dir is not defined (ESRGAN) #11

Eidenz opened this issue Jun 25, 2020 · 5 comments

Comments

@Eidenz
Copy link

Eidenz commented Jun 25, 2020

Hi, when running the code on a CUDA compatible GPU and choosing the ESRGAN option (both mosaic and video), I get this error:

File "main.py", line 313, in <lambda>
    go_button = Button(mos_win, text="Go!", command = lambda: hentAI_TGAN(in_path=o_entry.get(), is_video=False))
File "main.py", line 174, in hentAI_TGAN
    hconfig['USER']['dcpdir'] = dcp_dir
NameError: name 'dcp_dir' is not defined

It seems that the code is still trying to locate the DCP folder in ESRGAN mode, and crashes since you don't get a prompt to put the path to it..

@13579resu
Copy link

Here's a workaround:
In main.py on line 167 change this
def hentAI_TGAN(in_path=None, is_video=False, force_jpg=True):
to this (insert the correct path to ESRGAN folder):
def hentAI_TGAN(in_path="INSERT PATH HERE", is_video=False, force_jpg=True, dilation=0):

@natethegreate
Copy link
Owner

Hello,

Have you used one of the other options before? This should populate the dcp entry on the cfg, this can happen if you use esrgan with the cfg uninitiated.
Another workaround should be just commenting out line 174.

@13579resu
Copy link

13579resu commented Jun 29, 2020

Hi,

I have used the Bar and Mosaic (DCP) methods before, but none of the ESRGAN methods worked without changing the code.

Also, that workaround just eliminates the file path requirement, while not dealing with the missing dilation value

@natethegreate
Copy link
Owner

Try out the latest version 1.6.9 hotfix

@13579resu
Copy link

Seems to work. I am even able to run two instances of the program without any issues:
Screenshot (1322)

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

3 participants