sajjjadayobi / FaceLib

Face Analysis: Detection, Age Gender Estimation & Recognition
MIT License
294 stars 52 forks source link

Issue with EasyDict #28

Closed padmalcom closed 1 year ago

padmalcom commented 1 year ago

Hi, your requirements say EasyDict > 1.7.0 is required. I have 1.10.0 installed and get the following error:

File "C:\Users\admin\anaconda3\envs\myproj\lib\site-packages\facelib\InsightFace\models\utils.py", line 11, in faces_preprocessing faces = faces.permute(0, 3, 1, 2).float() AttributeError: 'EasyDict' object has no attribute 'permute'

Do you have any idea if the function has been renamed?

sajjjadayobi commented 1 year ago

faces must be PyTorch tensor I think you have passed the wrong object as faces into this function

padmalcom commented 1 year ago

Yes thank you, I figured it out. I passed an empty list of faces, so I just had to check the length before.