Skip to main content

pythorvision

pythorvision is a python package as client API for communicating with XDAQ video streaming subsystem -- ThorVision, designed to manage camera streams and recordings.

Features

pythorvision features High-level API with simple interface for managing camera streams and recordings.

  • Camera Discovery: List available cameras and their capabilities.
  • Flexible Stream Selection: Select stream capabilities:
    • media type (MJPEG)
    • format
    • resolution
    • framerate
  • GStreamer-based Recording: Record video streams into split .mkv files using GStreamer.

Requirements

  • Python: Python 3.6 or higher is required.
  • Dependencies:
    • GStreamer: Must be installed on the client machine, and gst-launch-1.0 must be available in the system's PATH.
      • You can download GStreamer from gstreamer.freedesktop.org/download.

      • Windows:

        1. Download and run the runtime installer.
        2. Add the bin directory of your GStreamer installation (e.g., C:\gstreamer\1.0\msvc_x86_64\bin) to your system's Path environment variable.
      • macOS:

        • The recommended way to install is using Homebrew:
          brew install gstreamer
          
        • Alternatively, you can download and run the runtime installer from the GStreamer website. If you use the installer, you may need to manually add GStreamer to your PATH:
          export PATH=/Library/Frameworks/GStreamer.framework/Versions/Current/bin:$PATH
          

Installation

To install pythorvision, you can use pip in project root directory:

pip install .

This will install the package and its required Python dependencies.

Tutorial

This tutorial demonstrates how to use ThorVisionClient to connect to the server, start and record streams from cameras, and then clean up the resources.

Run the Example Scripts

Record Video from Two Cameras

Run the following script to record from the first two available cameras for 10 seconds:

python ./examples/run_two_cams.py

The recorded .mkv video files will be saved in the recordings/ directory.

Extract Metadata from a Video File

If you have a pre-recorded video, you can extract its frame metadata using this script:

python ./examples/extract_video_metadata.py "path/to/your/video.mkv"

Record and Immediately Extract Metadata

This script provides a complete end-to-end example of recording a short video and then immediately parsing it to display its metadata.

python ./examples/record_and_extract.py

API Documentation

For complete API documentation, visit: https://kontex-neuro.github.io/pythorvision/

Release files for pythorvision 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pythorvision 0.3.0
File Size Uploaded
pythorvision-0.3.0.tar.gz 11.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pythorvision 0.3.0
File Interpreter ABI Platform
pythorvision-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 23.4 kB

Release files / pythorvision-0.3.0.tar.gz

Download URL pythorvision-0.3.0.tar.gz
Size 11.8 kB
Tags Source
SHA-256 checksum
How to use checksums
d80936d0538169249e88a08bc67c86cf18fafec47a6c679fa51b7d7b61fb4473
BLAKE2b-256 checksum
How to use checksums
cab99d21491f0d96b77189da7b2c4b8e8f1a6f8f68acfff81f56adc6249d47d2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 12, 2025.

Transparency log

Release files / pythorvision-0.3.0-py3-none-any.whl

Download URL pythorvision-0.3.0-py3-none-any.whl
Size 11.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b8eab07ca3118d6b6b76d58ff3a4c6e45141e7167e596ed447f244c31e188d86
BLAKE2b-256 checksum
How to use checksums
fd8347e829c067ed294ca264a7d1e05df0362d03cc7dfef2ff29edec9f64c1fb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 12, 2025.

Transparency log

Release history Release notifications | RSS feed

This release

0.3.0 This release

2 release files

0.2.0

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page