Skip to main content

PyPI version

PupilToolKit

A lightweight toolkit for pupil tracking and processing used by LIM Lab.

Overview

PupilToolKit provides utilities and pipelines for pupil extraction, processing, and inference. The repository includes two main components:

  • PupilProcessing: processing pipelines and utility functions.
  • PupilSense: integration with PupilSense inference tools and example scripts.

Example configuration files for experiments and devices are stored in the configs/ directory.

Features

  • Extract and process pupil data
  • Run inference with PupilSense models
  • Example scripts and test coverage

Requirements

  • Python 3.10+ (recommended)
  • Typical scientific packages: numpy, scipy, etc. (see pyproject.toml / setup.py)

Create and activate a virtual environment before installing:

conda create -n process_pupil python=3.10 -y
conda activate process_pupil
pip install -e .

Or using pip/venv:

python -m venv .venv
.venv\\Scripts\\activate
pip install -e .

Installation

Recommended: create and activate a virtual environment (conda or venv) before installing packages.

  • PyTorch & TorchVision (CUDA 12.1) — install the CUDA 12.1 builds of PyTorch 2.2 and TorchVision 0.17.0:
pip install torch==2.2.0+cu121 torchvision==0.17.0+cu121 -f https://download.pytorch.org/whl/torch_stable.html

If you do not have CUDA 12.1 or need a CPU-only build, install the matching CPU/compatible wheel instead (omit +cu121 or follow the official PyTorch install selector at https://pytorch.org).

  • Detectron2 — platform-specific instructions:

  • Windows (pre-built wheels):

pip install detectron2 --extra-index-url https://myhloli.github.io/wheels/
  • Linux (install from upstream):
pip install --no-build-isolation git+https://github.com/facebookresearch/detectron2.git
  • PupilLIMlab package — install the project package from PyPI (or your registry):
pip install PupilLIMlabSWC

After these steps you should be able to run the example scripts and the PupilSense inference tools.

Quick start

Run the example script:

python example/run_script.py

Run tests:

pytest -q

Repository structure

  • PupilProcessing/ — core processing modules and utilities
  • PupilSense/ — PupilSense integration and inference scripts
  • configs/ — YAML configuration files for experiments and devices
  • example/ — runnable example scripts
  • tests/ — unit tests

Contributing

Contributions welcome. Please open issues or pull requests and follow existing code style. Add tests for any behavior changes.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pupil_limlab-1.1.1.tar.gz (51.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pupil_limlab-1.1.1-py3-none-any.whl (51.3 kB view details)

Uploaded Python 3

File details

Details for the file pupil_limlab-1.1.1.tar.gz.

File metadata

  • Download URL: pupil_limlab-1.1.1.tar.gz
  • Upload date:
  • Size: 51.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for pupil_limlab-1.1.1.tar.gz
Algorithm Hash digest
SHA256 791e00690bfc1589f59ed532dbfee125d74e194ae857f005ce3954b252f779a6
MD5 06554881bee41ff59af254ab48d8d27b
BLAKE2b-256 d44192832dc7cce9c3f5d5646060bf40a0741bf871a7e84d796855f23a53ca25

See more details on using hashes here.

Provenance

The following attestation bundles were made for pupil_limlab-1.1.1.tar.gz:

Publisher: publish.yml on LIMLabSWC/PupilLIMLab

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pupil_limlab-1.1.1-py3-none-any.whl.

File metadata

  • Download URL: pupil_limlab-1.1.1-py3-none-any.whl
  • Upload date:
  • Size: 51.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for pupil_limlab-1.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 036dc01ab3574a98cd5feb1a23ba79e8856e196a849585b17500018231cc9526
MD5 85b98278fd67aa7de08a8355afb04ca4
BLAKE2b-256 fa891bc3deead05c2853e3bba349eacb75ee8fa9d157809b9f66ea314acc79ba

See more details on using hashes here.

Provenance

The following attestation bundles were made for pupil_limlab-1.1.1-py3-none-any.whl:

Publisher: publish.yml on LIMLabSWC/PupilLIMLab

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page