Skip to content

TomographicImaging/CILViewer

Repository files navigation

Master Development Anaconda binaries
Build Status Build Status conda version conda last release conda platforms conda downloads

CILViewer

A simple interactive viewer based on VTK classes and written in Python.

  • The classes in viewer define generic viewers that can be embedded in Qt or other user interfaces. CILviewer2D is a 2D viewer and CILviewer is a 3D viewer.
  • The classes in web viewer define a viewer embedded in trame.

Examples of QApplications are the iviewer and the standalone viewer. An example of use in an external software is iDVC.

Installation instructions

To install via conda, create a minimal environment using:

conda create --name cilviewer ccpi-viewer=24.0.1 -c ccpi -c conda-forge

UI requirements

To use the extra UI utilities the environment needs to be updated to include the extra requirements eqt and pyside2. The UI examples require cil-data as well. The environment can be updated to include these dependencies as follows:

conda env update --name cilviewer --file Wrappers/Python/conda-recipe/ui_env.yml

Run the standalone viewer QApplication

  • Activate your environment using: conda activate cilviewer.
  • Launch by typing: cilviewer
  • Load a dataset using the File menu. Currently supported data formats:
    • HDF5, including Nexus
    • Raw
    • Tiff
    • Numpy
    • Metaimage (mha and mhd)

Your image title

Data shown is [1].

Install and run the trame web viewer

Follow the instructions to install and run the web viewer.

Your image title

Data shown is [2].

Documentation

More information on how to use the viewer can be found in Documentation.md.

Developer Contribution Guide

We welcome contributions. Please see CONTRIBUTING.md for guidance.

Notice

The CIL Viewer code took initial inspiration from a previous project of Edoardo Pasca and Lukas Batteau PyVE, the license of which we report here:

Copyright (c) 2012, Edoardo Pasca and Lukas Batteau
All rights reserved.

Redistribution and use in source and binary forms, with or without modification, 
are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice, this list
of conditions and the following disclaimer.

* Redistributions in binary form must reproduce the above copyright notice, this 
list of conditions and the following disclaimer in the documentation and/or other
materials provided with the distribution.

* Neither the name of Edoardo Pasca or Lukas Batteau nor the names of any 
contributors may be used to endorse or promote products derived from this 
software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY
EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT 
SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED 
TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR 
BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

References

[1] The chocolate egg dataset shown in above examples is dataset egg2:

Jakob Sauer Jørgensen, Martin Skovgaard Andersen, & Carsten Gundlach. (2021). HDTomo TXRM micro-CT datasets [Data set]. Zenodo. https://doi.org/10.5281/zenodo.4822516

[2] The head dataset is avaiable in CIL-Data as 'head.mha' along with its license.

About

A simple Viewer for 3D data built with VTK

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages