I'm trying to initialize dlib.cnn_face_detection_model_v1 using dlib_face_recognition_resnet_model_v1.dat (or mmod_human_face_detector.dat to double-check).
Current Behavior
When using dlib_face_recognition_resnet_model_v1.dat, dlib reports deserialization error. Trying the same with mmod_human_face_detector.dat yields no such error.
2) Try to initialize dlib.cnn_face_detection_model_v1:
$ python
Python 3.6.7 |Anaconda custom (64-bit)| (default, Oct 23 2018, 19:16:44)
[GCC 7.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import dlib
>>> dlib.cnn_face_detection_model_v1('dlib_face_recognition_resnet_model_v1.dat')
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
RuntimeError: An error occurred while trying to read the first object from the file dlib_face_recognition_resnet_model_v1.dat.
ERROR: Unexpected version found while deserializing dlib::loss_mmod_.
>>> dlib.cnn_face_detection_model_v1('mmod_human_face_detector.dat')
<dlib.cnn_face_detection_model_v1 object at 0x7f963a0348f0>
Information
Version: 19.17.0 (19.16.0 compiled with Clang 7.0.1 on Arch Linux fails, too)
Expected Behavior
I'm trying to initialize
dlib.cnn_face_detection_model_v1
usingdlib_face_recognition_resnet_model_v1.dat
(ormmod_human_face_detector.dat
to double-check).Current Behavior
When using
dlib_face_recognition_resnet_model_v1.dat
, dlib reports deserialization error. Trying the same withmmod_human_face_detector.dat
yields no such error.Steps to Reproduce
1) Download pre-trained models:
2) Try to initialize
dlib.cnn_face_detection_model_v1
:Information
pip
, from Arch Linux's AUR (https://aur.archlinux.org/packages/python-dlib/), installing frompip
inside Anaconda environment.2) Ubuntu 18.04 + dlib from pip within Anaconda environment (with Python 3.6.7)