Skip to main content

Interface for Northern Digital (NDI) Trackers with data to NumPy arrays

Project description

Logo

GitHub CI test status Test coverage Documentation Status The SciKit-Surgery paper Follow scikit_surgery on twitter

scikit-surgerynditracker is a python interface for Northern Digital (NDI) trackers. It should work with Polaris Vicra, Spectra, and Vega optical trackers and Aurora electromagnetic trackers. Tracking data is output as NumPy arrays.

Author: Stephen Thompson

scikit-surgerynditracker is part of the SciKit-Surgery software project, developed at the Wellcome EPSRC Centre for Interventional and Surgical Sciences, part of University College London (UCL).

Installing

pip install scikit-surgerynditracker

Using

Configuration is done using Python libraries at instantiation. Invalid configuration should raise exceptions. Tracking data is returned in a set of lists, containing the port handles, timestamps, framenumbers, the tracking data and a tracking quality metric. By default tracking data is returned as a 4x4 NumPy array, though can be returned as a quaternion by changing the configuration.

from sksurgerynditracker.nditracker import NDITracker
SETTINGS = {
    "tracker type": "polaris",
    "romfiles" : ["../data/8700339.rom"]
        }
TRACKER = NDITracker(SETTINGS)

TRACKER.start_tracking()
port_handles, timestamps, framenumbers, tracking, quality = TRACKER.get_frame()
for t in tracking:
  print (t)
TRACKER.stop_tracking()
TRACKER.close()

See demo.py for a full example

Developing

Cloning

You can clone the repository using the following command:

git clone https://github.com/SciKit-Surgery/scikit-surgerynditracker

Running the tests

You can run the unit tests by installing and running tox:

pip install tox
tox

Contributing

Please see the contributing guidelines.

Acknowledgements

Supported by Wellcome and EPSRC.

Project details


Download files

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

Source Distribution

scikit-surgerynditracker-1.0.1.tar.gz (27.5 kB view details)

Uploaded Source

File details

Details for the file scikit-surgerynditracker-1.0.1.tar.gz.

File metadata

File hashes

Hashes for scikit-surgerynditracker-1.0.1.tar.gz
Algorithm Hash digest
SHA256 98b89d6cc10f52fc5991f4c021b7b24529e1816e486f9878d8fd69d473c2c613
MD5 da502c392679d36465a2b1b2137f68e2
BLAKE2b-256 72ca5080a5506001bd69d512b3719b128aea420fb9daff7485ef3fd09147138e

See more details on using hashes here.

Supported by

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