joaen / maya-auto-lip-sync

A tool to automatically generate lip sync animations in Autodesk: Maya using Montreal Forced Aligner.
MIT License
29 stars 6 forks source link

Can't install #14

Closed Jasic17 closed 6 months ago

Jasic17 commented 6 months ago

I installed this tool mid september last year and worked perfectly but had a computer that made me change it and missed my files.

Tried to install it again, but been geeting this error log: "# Error: SyntaxError: file C:/Users/myUser/Documents/maya/2020/scripts\auto_lip_sync__init__.py line 2: invalid syntax #"

I'm on windows 11 and Maya 2020, previous install was on win 10 and Maya 2020. If that helps.

joaen commented 6 months ago

Hi, that's strange. There is no syntax error on line 2 in the init.py. Are there any more info to that error message?

It's not optimal but a workaround is to copy the whole content of the auto_lip_sync.py-file and paste that into the script editor in Maya and run it directly from within Maya.

Jasic17 commented 6 months ago

Hey there, thanks for your response. I ran it like you said and it was giving me a constant syntax error. Manage to trace back the syntax error to line 311 and 316 "print(line, end="")" As you said there was no syntax error in the init.py, it seems those lines where the issue. I just commented them with "#" for now as I don't know how those are supposed to be written. And now after that change I can run it normally without any issue the normal way with "import auto_lip_sync, auto_lip_sync.start()" line.

joaen commented 6 months ago

Ok, that's very strange. Thanks for sharing your findings! I'll take a look if I can reproduce this, but I might update these lines anyway, just in case.

joaen commented 6 months ago

Can you please run this in Maya and tell me what is printed in the log?

import sys
print(sys.version)
Jasic17 commented 6 months ago

sure, this is what I get import sys print(sys.version) 2.7.11 (default, Jul 1 2016, 02:08:48) [MSC v.1900 64 bit (AMD64)]

joaen commented 6 months ago

Ok, that explains it. The print(end="") is not supported by Python2. I'll update the code. Thanks for confirming