Skip to main content

Toolkit to build SGRT applications

Project description

SpyGRT

SpyGRT, or Surface Guided Radiotherapy Toolkit in Python is a toolkit that allows fast development of novel surface guidance applications for radiotherapy.

SpyGRT allows easy:

  • Operation of the depth camera (current model is Intel Realsense D415)
  • Calibration of multiple cameras into the same external frame of reference
  • Tracking of motion using an ICP workflow

Getting Started

Installing SpyGRT using pip

The preferred method for installing SpyGRT is to use pip. This will download all the required packages, however a list of prerequisites and where to find them are listed in the next section in case you prefer to build them from source.

Steps to installing SpyGRT with pip

  1. Clone the SpyGRT GitHub repo
  2. Open a command prompt
  3. Navigate to the SpyGRT folder (not the embedded spygrt folder)
  4. Enter the following pip command
pip install -e . 
  1. You should now be able to run SpyGRT

Prerequesites

1. Intel RealSense SDK2.0

If you want to build from source, installation instructions available here. The code has currently only been tested up to release version 2.5.0 but should work with more recent releases.

2. Open3D library v.0.15.0 or later

If you want to build it from source, full release available here and instructions to compile it yourself are available here.

3. OpenCV

Full release available here, if you prefer to build it from source.

4. Numpy

More Information available here

Working Examples

The example folder contain three examples that illustrate how to use the basic functions of SpyGRT. More instructions are located in that folder.

Depth Sensor

SpyGRT is currently built to use Intel RealSense D415 stereo depth sensors for capturing depth data. However, it should be possible to modify the stream module to work with any commercial depth sensors that have a python API.

Intel RealSense Viewer

While SpyGRT contains the required code for real-time SGRT and analysis of prior recordings, it cannot currently be used to create new recordings. We suggest installing the free realsense-viewer app available here if you want to create your own recordings.

Calibrations Boards

Default SpyGRT Calibration Board

SpyGRT uses a checkerboard to calibrate multiple cameras. By default, it assumes that the checkboard has 5 rows, 8 columns, and that the length of the sides of each square is 4.3 centimeters. If you want to print the default checkerboard, you can find it in a powerpoint file located in the SampleData folder. This file should be printed on an A3 paper to get the accurate dimensions.

Custom Calibration Board

Any checkerboard can be use to calibrate cameras with SpyGRT. If you want to use a custom checkerboard, you will need to change the following default variables in calibration.py

  1. DEFAULT_ROW: Number of rows in the custom calibration board.
  2. DEFAULT_COLUMN: Number of columns in the custom calibration board
  3. DEFAULT_SQUARE_SIZE: Length in meters of the sides of a square in the custom calibration board

Tracking with SpyGRT

Calibration files are necessary to use the SpyGRT for tracking. By default, SpyGRT will look for calibration files ../Calibrations/. If you want to change this path, you must change the following constant in tracker.py

  • CALIBRATION_FOLDER

Author

Youssef Ben Bouchta

Email: youssef.benbouchta@sydney.edu.au

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

spygrt-1.0.0.tar.gz (21.9 kB view details)

Uploaded Source

Built Distribution

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

spygrt-1.0.0-py3-none-any.whl (25.5 kB view details)

Uploaded Python 3

File details

Details for the file spygrt-1.0.0.tar.gz.

File metadata

  • Download URL: spygrt-1.0.0.tar.gz
  • Upload date:
  • Size: 21.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-httpx/0.27.2

File hashes

Hashes for spygrt-1.0.0.tar.gz
Algorithm Hash digest
SHA256 389a5c5cfc717a8091c08b029daabd0c49b0b2b67d2b4989de59c4ad9c86945c
MD5 0478dd4ba828b938314514250a1ca7be
BLAKE2b-256 33ce029f4b8c150cade93e07523d6897c3bf5c5cfdb3d41cb057c97e07a14ad9

See more details on using hashes here.

File details

Details for the file spygrt-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: spygrt-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 25.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-httpx/0.27.2

File hashes

Hashes for spygrt-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ea634613a2b9375c444253164dd2eb53f803d3594e867134956075ed06fc2948
MD5 060675af8a4e3e81856615f99d0f88d2
BLAKE2b-256 57b1741753d2bfbb14db04deecc75902f71b8ce644214d7d985e3f3461559863

See more details on using hashes here.

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