Skip to content

UCL/fan-slicer

Repository files navigation

Fan-slicer

Logo

GitLab-CI test status

Author: João Ramalhinho

Fan-slicer is a python and Pycuda package that enables the sampling of arbitrarily positioned 2D Ultrasound-shaped (fan) planes from a 3D volume. CUDA kernels are used with Pycuda to enable the fast sampling of multiple images in one run. Fan-slicer samples images from both binary and non-binary volumes. Additionally, slicing of rectangular planes (linear probe case) is also supported. Fan-slicer is developed at the Wellcome EPSRC Centre for Interventional and Surgical Sciences on top of the Python Template from Scikit-Surgery.

Installing from Github

You can clone the repository using the following command:

git clone https://github.com/UCL/fan-slicer.git

Install dependencies preferably in a clean virtual environment by using the following commands:

cd fan-slicer
pip install -r requirements-pycuda.txt

To run tests, use the following command:

python -m pytest -v -s ./tests-pycuda

Installing with pip ^^^^^^^^^^

Alternatively, you can also pip install directly from the repository:

pip install git+https://github.com/UCL/fan-slicer

Tested environments

Operating systems

sudo apt-get install build-essential gcc libboost-all.dev

Tested on python 3.6, 3.7, 3.8.

Using

A complete use case example is provided in simulation_demo.py. This script contains code for the sampling of 10 evenly spaced fan-shaped planes from two volumes:

  • An abdominal contrast enhanced CT centered at the liver (a non-binary intensity volume).

* A vessel segmented volume of the same liver (binary volume) that is extracted from vessel tree vtk files. Further details on the parameterisation of the planes, pose formulation, and usage of functions are provided in the following guide.

Citing

If you use this software in your research, please cite:

Ramalhinho, J., Dowrick, T., Bonmati, E., Clarkson, M. J., 2023. Fan-Slicer: A Pycuda Package for Fast Reslicing of Ultrasound Shaped Planes " Journal of Open Research Software 11(1), p.3 DOI: http://doi.org/10.5334/jors.422

Contributing

Please see the contributing guidelines.

Copyright 2022 University College London. Fan-slicer is released under the BSD-3 license. Please see the license file for details.

Acknowledgements

Supported by Wellcome and EPSRC.