Skip to main content

AraViQ6 - NDArray-based Video processing with Qt6

PyPI version Python Version Build Status Documentation Status License

AraViQ6 is a Python package which integrates NDArray-based image processing with video pipeline of Qt6.

It provides:

  • QVideoFrame processor based on array processing
  • Converters between NDArray and QVideoFrame
  • Convenience classes and widgets for array displaying

The following Qt bindings are supported:

How to use

There are two ways to use AraViQ6; using QVideoFrame-based pipeline, or using NDArray-based pipeline.

Frame-based pipeline

Frame-based pipeline is a high-level approach that works well with Qt Multimedia scheme.


QVideoFrame pipeline with AraViQ6

Frame-based pipeline consists of:

  1. VideoFrameWorker
  2. VideoFrameProcessor

QVideoFrame comes from and goes to Qt6's QVideoSink. AraViQ6's VideoFrameWorker converts QVideoFrame to numpy array, performs processing, and sends the results to downstream in both QVideoFrame and NDArray. User may subclass the worker to define own processing.

VideoFrameProcessor wraps the worker and provides API around it. Worker is mulithreaded in the processor.

Array-based pipeline

Array-based pipeline is a low-level approach. It can be useful when third-party package provides video frame in numpy array format.


NDArray pipeline with AraViQ6

Array-based pipeline consists of:

  1. FrameToArrayConverter
  2. ArrayWorker
  3. ArrayProcessor
  4. ArrayToFrameConverter

FrameToArrayConverter and ArrayToFrameConverter performs conversion between frame pipeline and array pipeline. To retain the metadata (e.g., timestamp) of QVideoFrame, these classes includes the original frame for the array.

ArrayWorker performs processing on incoming array and sends the result to downstream in NDArray. User may subclass the worker to define own processing.

ArrayProcessor wraps the worker and provides API around it. Worker is mulithreaded in the processor.

Convenicence classes

AraViQ6 also provides various convenience classes to make building the pipeline easier.

The following classes help setting array pipeline with the video source and the display.

  • NDArrayVideoPlayer
  • NDArrayMediaCaptureSession
  • NDArrayLabel

The following classes are plug-and-play widgets where user can process the video with minimal boilerplate.

  • PlayerProcessWidget
  • CameraProcessWidget

Examples

Use cases are provided in examples directory. They can be found in documentation as well.

Installation

Before you install, be careful for other Qt-dependent packages installed in your environment. For example, non-headless OpenCV-Python modifies the Qt dependency thus can make other Qt bindings unavailable.

araviq6 can be installed using pip.

$ pip install araviq6

Documentation

AraViQ6 is documented with Sphinx. Documentation can be found on Read the Docs:

https://araviq6.readthedocs.io/

If you want to build the document yourself, clone the source code and install with [doc] option. Go to doc directory and build the document.

$ pip install araviq6[doc]
$ cd doc
$ make html

Document will be generated in build/html directory. Open index.html to see the central page.

Metadata

Release files for araviq6 2.1.1

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

Source distribution (sdist)

Source distribution for araviq6 2.1.1
File Size Uploaded
araviq6-2.1.1.tar.gz 183.5 kB Details

Built distribution (wheel)

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

Total release size: 367.6 kB

Release files / araviq6-2.1.1.tar.gz

Download URL araviq6-2.1.1.tar.gz
Size 183.5 kB
Tags Source
SHA-256 checksum
How to use checksums
b44540c19d1105c7aa15a3c5f851f8475ab8f44d8e96db895640d758257e64d5
BLAKE2b-256 checksum
How to use checksums
eb65064e37923057129b11249846404f93ed71f9b53eee9c2499b865c6c18539
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.1

Release files / araviq6-2.1.1-py3-none-any.whl

Download URL araviq6-2.1.1-py3-none-any.whl
Size 184.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b46b7d2dc2d0929cbb5f2519105152c2300986ce4e2e96be717f9947a8e4a728
BLAKE2b-256 checksum
How to use checksums
8c5cdccaa212971f49e0873455177acb0e61096a3da096762aed2aee74443f6b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.11.1

Release history Release notifications | RSS feed

This release

2.1.1 This release

2 release files

2.1.0

2 release files

2.0.0

2 release files

1.0.1

2 release files

1.0.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