alievk / avatarify-python

Avatars for Zoom, Skype and other video-conferencing apps.
Other
16.29k stars 4.09k forks source link

OSERROR Failed to open file b'C:\\Users\\...\\AppData\\Local\\Temp\\scipy-ikn1w3ak' #138

Closed ExcaliburEX closed 4 years ago

ExcaliburEX commented 4 years ago

Describe the bug

after load checkpoints,it raises below error message:

AttributeError: 'NoneType' object has no attribute 'close'
Exception ignored in: 'scipy.spatial.qhull._Qhull.__dealloc__'
AttributeError: 'NoneType' object has no attribute 'close'
Traceback (most recent call last):

To Reproduce

Info (please complete the following information):

Screenshots

微信截图_20200427022026.png Logs

AttributeError: 'NoneType' object has no attribute 'close'
Exception ignored in: 'scipy.spatial.qhull._Qhull.__dealloc__'
AttributeError: 'NoneType' object has no attribute 'close'
Traceback (most recent call last):
  File "cam_fomm.py", line 242, in <module>
    change_avatar(fa, avatars[cur_ava])
  File "cam_fomm.py", line 169, in change_avatar
    avatar_kp = get_frame_kp(fa, new_avatar)
  File "cam_fomm.py", line 64, in get_frame_kp
    kp_image = normalize_alignment_kp(kp_image)
  File "cam_fomm.py", line 55, in normalize_alignment_kp
    area = ConvexHull(kp[:, :2]).volume
  File "qhull.pyx", line 2335, in scipy.spatial.qhull.ConvexHull.__init__
  File "qhull.pyx", line 266, in scipy.spatial.qhull._Qhull.__init__
  File "messagestream.pyx", line 36, in scipy._lib.messagestream.MessageStream.__init__
OSError: Failed to open file b'C:\\Users\\\xe6\x9f\xaf\xe6\x91\xa9\\AppData\\Local\\Temp\\scipy-ikn1w3ak'
ExcaliburEX commented 4 years ago

Is there anyone have experienced this question?

alievk commented 4 years ago

Hi @ExcaliburEX , my guess is that something goes wrong 'cause the path contains non-latin characters.

E3V3A commented 4 years ago

Please post the output of the following commands: (And for privacy remove your home directory username, if necessary.) Enclose your output in triple back-ticks (```) on separate lines.

# conda activate avatarify
conda info
conda list
pip list

PS. It looks like you have a funny username possibly in a language character set that is not recognized by conda. Try using a simple ASCII username...

E3V3A commented 4 years ago

@ExcaliburEX

To check charset please use post the powershell output from:

(Get-CimInstance Win32_OperatingSystem) | Select-Object Caption,Version,OSArchitecture | Format-Table -hideTableHeader
(Get-Variable OutputEncoding).Value.EncodingName
Get-Host

and since you're at it, the output from a CMD when typing: chcp.com

alievk commented 4 years ago

@ExcaliburEX please let us know if you have resolved this issue.

ExcaliburEX commented 4 years ago

Please post the output of the following commands: (And for privacy remove your home directory username, if necessary.) Enclose your output in triple back-ticks (```) on separate lines.

# conda activate avatarify
conda info
conda list
pip list

PS. It looks like you have a funny username possibly in a language character set that is not recognized by conda. Try using a simple ASCII username...

Thank for all your help! These commands help me find the reason for the problem which is the pathname of the conda dir. Then I used administrator rights to change the user dir name into Latin characters so avatarify can work without any mistake!

ExcaliburEX commented 4 years ago

@ExcaliburEX please let us know if you have resolved this issue.

Thanks a lot for your suggestion and I am sorry that I am a bit slow to reply. After changing the pathname of user dir, I solved the problem.