ogkalu2 / comic-translate

Desktop app for automatically translating comics - BDs, Manga, Manhwa, Fumetti and more in a variety of formats (Image, Pdf, Epub, cbr, cbz, etc) and in multiple languages.
Apache License 2.0
964 stars 87 forks source link

No module named "modules.utils" #7

Closed Dioskard closed 8 months ago

Dioskard commented 8 months ago

Traceback (most recent call last): File "C:\Users\vladi\Desktop\comic-translate\comic.py", line 3, in from modules.utils.download import get_models, models_data ModuleNotFoundError: No module named 'modules.utils'; 'modules' is not a package

Already downloaded all req, downloaded utils but not working

ogkalu2 commented 8 months ago

I think python may not be installed to path.

Uninstall python. Run the installer again but make sure to tick "Add python.exe to PATH" during the setup

Let me know if that works

Dioskard commented 8 months ago

Using python before for study, kind of prog and for stable diffusion (python 3.10 installed for it). Because of that path is confirmed (also add some kind of it to path myself with windows)

ogkalu2 commented 8 months ago

are you running "python comic.py" directly in the same folder or from some other folder (e.g "python comic-translate\comic.py") ?

Dioskard commented 8 months ago

directly from folder

ogkalu2 commented 8 months ago

in the comic.py file, after line 2 (import os), add

import sys print(f'Running from {os.getcwd()}') sys.path.insert(0, os.getcwd())

See if this works.

Look at what gets printed. If it's "Running from C:\Users\vladi\Desktop\comic-translate" then you can remove the print line. If it's not that then replace sys.path.insert(0, os.getcwd()) with sys.path.insert(0, "C:\Users\vladi\Desktop\comic-translate")

Dioskard commented 8 months ago

move folder from desktop to disk

PS C:\comic-translate> python comic.py Traceback (most recent call last): File "C:\comic-translate\comic.py", line 5, in from modules.utils.download import get_models, models_data ModuleNotFoundError: No module named 'modules.utils'; 'modules' is not a package

Print correctly writing location of folder sys.path.insert not helped

Dioskard commented 8 months ago

BTW, found something. when i renamed folder modules to modls and change it also in comic.py and pipeline.py it's work... I think my python was trying to find real modules.py from python folder in appdata

Dioskard commented 8 months ago

And now it's error responses... image

ogkalu2 commented 8 months ago

Okay so the Gui loads now?

What progress does the error start at ? i.e 'forming textblocks', 'Translating' etc

Also what options did you select on the main page of the UI ?

Dioskard commented 8 months ago

image Gui working. This settings and now it's translate i t hink somehow? But it's translate to [] and some text is not translated 10_translated

ogkalu2 commented 8 months ago

Change your Font to Notosans-Medium.tff. animeace2_reg does not support Russian.