OpenViSTAI · Agents · Blockchain · Crypto
Menu
AI Models

L2Cs Net

L2Cs Net is a Python and PyTorch implementation of gaze estimation and tracking. It includes a frame-processing pipeline with rendering, pretrained webcam inference, and training and evaluation code for MPIIGaze and Gaze360.

Independent OpenViST project profile, based on linked sources.

L2Cs Net — Webcam gaze inference using pretrained weights
OpenViST project illustration. See the linked sources for product details.
Understand the project

Practical overview

When it fits

Use it when you need a Python/PyTorch gaze-estimation pipeline for camera frames or the repository's specific MPIIGaze and Gaze360 training and evaluation workflows.

Who it is for

  • Developers adding gaze-direction estimation to webcam-based applications.
  • Researchers or practitioners training and evaluating gaze models with MPIIGaze or Gaze360.

Documented uses

  • Estimate gaze from face images or webcam frames.
  • Render gaze results on processed camera frames.
  • Train and test on MPIIGaze using leave-one-person-out evaluation.
  • Train and test on Gaze360 using a train-validation-test workflow.
Before you choose

Requirements & limits

The repository is public and lists an MIT license. Its installation instructions use Python and PyTorch.

  • Webcam inference requires pretrained weights; the README directs users to download a checkpoint and place it in models/.
  • The inference example uses OpenCV to capture a frame and supports a CPU device option; the demo command specifies a GPU index.
  • Training and evaluation require prepared datasets, with separate workflows for MPIIGaze and Gaze360.

Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.

Source-based practical guide

Set up L2Cs Net and run the documented webcam demo

Install the package, place the pretrained Gaze360 weights in the expected folder, and launch the repository's webcam demo.

Before you start

  • Python and PyTorch, as identified by the repository.
  • The L2Cs Net repository, a webcam, and the pretrained model file L2CSNet_gaze360.pkl.
  • A GPU argument is used in the demo command; the usage example also shows a CPU device option.

Steps

  1. Install from the repository using its documented pip command, or clone the repository and install the local package.

  2. Download a pretrained model and store it in the models/ directory.

  3. Run demo.py with the snapshot path models/L2CSNet_gaze360.pkl, GPU index 0, and camera index 0.

Expected outcome

The repository's webcam demo is configured to use the Gaze360 pretrained model.

Guide limitations

  • The guide documents setup and the demo command, not a verified execution or compatibility result.
Source-based practical guide

Prepare an MPIIGaze training and evaluation workflow

Prepare the named dataset and follow the repository's documented leave-one-person-out training and testing stages.

Before you start

  • The MPIIFaceGaze dataset and the preprocessing referenced by the repository.
  • Prepared data stored at datasets/MPIIFaceGaze.
  • Python environment with the project installed.

Steps

  1. Download MPIIFaceGaze and apply the referenced dataset preprocessing.

  2. Store the prepared dataset at datasets/MPIIFaceGaze.

  3. Run train.py with dataset mpiigaze and a snapshot output path.

  4. Run test.py with the resulting snapshot folder and an evaluation output path.

  5. Run leave_one_out_eval.py with the evaluation and results paths to obtain average leave-one-out gaze accuracy.

Expected outcome

The documented workflow stores trained snapshots and test results, then calculates average leave-one-out gaze accuracy.

Guide limitations

  • The repository points to external dataset and preprocessing resources; this guide does not validate those resources or report a successful run.
Evidence and transparency

Sources & review

Source record details
Source availability
Active
Sources checked
11 November 2026
Original website title
Ahmednull/L2CS-Net · Official homepage title · retained in its source language