This is unofficial implementation (inference only) of FaceBoxes: A CPU Real-time Face Detector with High Accuracy, in libtorch (pythorch C++ API). The original caffe implementation can be found here
Move anchor.pt and face.pt from this repo to /usr/models/
- Download libtorch from pytroch.org extract and put it at
/usr/lib/ cd faceboxes_libtorch/ && mkdir buildcd build && cmake -DCMAKE_PREFIX_PATH=/usr/lib/libtorch ..make -j$(nproc)- put sample.jpg in build folder
- run
./faceboxesresult will be saved inbuild/result.jpg
Tested on Ubuntu 20.04, libtorch 1.7.1 the weight is traced from the weight published here https://github.com/zisianw/FaceBoxes.PyTorch. So the performance is expected to be the same
- Deploy on android
- Use half-precision model
- Libtorch