InsightFace_Pytorch
InsightFace_Pytorch copied to clipboard
list index out of range
这句话报错:warped_face = np.array(mtcnn.align(p))[...,::-1]
环境:
torch
numpy
matplotlib
tqdm
scipy
#bcolz==1.2.1
easydict
opencv_python==3.4.0.12
Pillow
mxnet==1.2.1.post1
scikit_learn
tensorboardX
torchvision
torchaudio
系统环境:Python3.6。
因为系统是CUDA12.1的所以没有安装mxnet_cu模块。 Python环境为Anaconda安装。
实际使用环境:
bcolz 1.2.1
easydict 1.10
matplotlib 3.2.2
mxnet 1.2.1.post1
numpy 1.14.6
opencv-python 3.4.0.12
Pillow 8.4.0
scikit-learn 0.24.2
scipy 1.5.4
tensorboardX 2.6
torch 1.10.2
torchaudio 0.10.2
torchvision 0.11.3
tqdm 4.64.1
具体错误:
Traceback (most recent call last):
File "take_pic.py", line 46, in <module>
warped_face = np.array(mtcnn.align(p))[...,::-1]
File "C:\Users\***\Documents\Projects\PycharmProjects\TreB1eN\InsightFace_Pytorch\mtcnn.py", line 24, in align
facial5points = [[landmarks[0][j],landmarks[0][j+5]] for j in range(5)]
File "C:\Users\***\Documents\Projects\PycharmProjects\TreB1eN\InsightFace_Pytorch\mtcnn.py", line 24, in <listcomp>
facial5points = [[landmarks[0][j],landmarks[0][j+5]] for j in range(5)]
IndexError: list index out of range
@erikaemma 你好,我也遇到相同的问题,请问你解决了吗?如果解决了,方便告知吗?打扰了。
我也遇到了这个问题,应该是未检测出来人脸的landmarks,我debug发现landmarks数组是空的。不知道怎么解决