Gaze estimation using MPIIGaze and MPIIFaceGaze
Project description
A demo program of MPIIGaze and MPIIFaceGaze
With this program, you can runs gaze estimation on images and videos. By default, the video from a webcam is used.
(The original video is from this public domain.)
(The original image is from this public domain.)
To train a model, use this repository.
Quick start
Installation
pip install ptgaze
Run demo
ptgaze --mode eye
Usage
usage: ptgaze [-h] [--config CONFIG] [--mode {eye,face}]
[--face-detector {dlib,face_alignment_dlib,face_alignement_sfd}]
[--device {cpu,cuda}] [--image IMAGE] [--video VIDEO]
[--camera CAMERA] [--output-dir OUTPUT_DIR] [--ext {avi,mp4}]
[--no-screen] [--debug]
optional arguments:
-h, --help show this help message and exit
--config CONFIG Config file for YACS. When using a config file, all
the other commandline arguments are ignored. See https
://github.com/hysts/pytorch_mpiigaze_demo/configs/demo
_mpiigaze.yaml
--mode {eye,face} With 'eye', MPIIGaze model will be used. With 'face',
MPIIFaceGaze model will be used. (default: 'eye')
--face-detector {dlib,face_alignment_dlib,face_alignement_sfd}
The method used to detect faces and find face
landmarks (default: 'dlib')
--device {cpu,cuda} Device used for model inference.
--image IMAGE Path to an input image file.
--video VIDEO Path to an input video file.
--camera CAMERA Camera calibration file. See https://github.com/hysts/
pytorch_mpiigaze_demo/ptgaze/data/calib/sample_params.
yaml
--output-dir OUTPUT_DIR, -o OUTPUT_DIR
If specified, the overlaid video will be saved to this
directory.
--ext {avi,mp4}, -e {avi,mp4}
Output video file extension.
--no-screen If specified, the video is not displayed on screen,
and saved to the output directory.
--debug
While processing an image or video, press the following keys on the window to show or hide intermediate results:
l
: landmarksh
: head poset
: projected points of 3D face modelb
: face bounding box
References
- Zhang, Xucong, Yusuke Sugano, Mario Fritz, and Andreas Bulling. "Appearance-based Gaze Estimation in the Wild." Proc. of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2015. arXiv:1504.02863, Project Page
- Zhang, Xucong, Yusuke Sugano, Mario Fritz, and Andreas Bulling. "It's Written All Over Your Face: Full-Face Appearance-Based Gaze Estimation." Proc. of the IEEE Conference on Computer Vision and Pattern Recognition Workshops(CVPRW), 2017. arXiv:1611.08860, Project Page
- Zhang, Xucong, Yusuke Sugano, Mario Fritz, and Andreas Bulling. "MPIIGaze: Real-World Dataset and Deep Appearance-Based Gaze Estimation." IEEE transactions on pattern analysis and machine intelligence 41 (2017). arXiv:1711.09017
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ptgaze-0.0.4.tar.gz
(20.6 kB
view details)
Built Distribution
ptgaze-0.0.4-py3-none-any.whl
(26.3 kB
view details)
File details
Details for the file ptgaze-0.0.4.tar.gz
.
File metadata
- Download URL: ptgaze-0.0.4.tar.gz
- Upload date:
- Size: 20.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8d630c2b507783ab702f50dca38283c09af156f635a0e54b3750a65a3cdcffee |
|
MD5 | f4ba13b33b4c735b5f27f9522484c3c7 |
|
BLAKE2b-256 | 916d53d100ac75f7e22dfbed8643d9842ed2dfe069f1c975739a6bbcb863745a |
File details
Details for the file ptgaze-0.0.4-py3-none-any.whl
.
File metadata
- Download URL: ptgaze-0.0.4-py3-none-any.whl
- Upload date:
- Size: 26.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.59.0 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 16023f8b36945d00efd6159a252410eea00c64c536934cbd88fe19bf454835de |
|
MD5 | 26b8d1f56bb6e3df655f458ffb62d4b7 |
|
BLAKE2b-256 | 4a4e5a787aa8801a7e1de800e3bb2f717281c73f7b46c6ffb0c0f7c329e3b063 |