PyFaceDet
PyFaceDet copied to clipboard
Win10下使用32-bit python出现ctypes错误
调用cfacedetect_cnn时出现:
ValueError: Procedure probably called with too many arguments (20 bytes in excess)
参考了https://stackoverflow.com/questions/41760830/ctypes-procedure-probably-called-with-too-many-arguments-92-bytes-in-excess 后
将下面代码中的ctypes.WinDLL改为ctypes.cdll.LoadLibrary可以正常运行
if platform.system() == 'Windows':
# load .dll for Windows
LoadDLL = ctypes.WinDLL
else:
# load lib for Linux, Darwin, etc
LoadDLL = ctypes.cdll.LoadLibrary
建议增加一个对python环境的检查