Skip to content

Visualization and processing tools for 3D tensor fields

Notifications You must be signed in to change notification settings

helia77/tensorview3D

Repository files navigation

3D Tensorview and Tensorvoting with CUDA

This repository provides a tensor visualization tool to visualize 3D tensor fields with built-in functions and performs efficient 3D tensor voting using parallel computations with CUDA.

Table of Contents

  1. Overview
  2. Demo
  3. Dependencies
  4. Installation
  5. Usage
  6. Contributing

Overview

The repository focuses on:

  • Tools for generating, processing, and visualizing tensor fields and volumetric data.
  • Parallelized tensor voting computations using CUDA for GPU acceleration.
  • Efficient parallelized eigendecomposition of tensors for 3D data.
  • Synthetic dataset generation for validation and testing.

This project is designed for research in large-scale tensor voting frameworks, particularly for 3D data analysis and segmentation. For the complete repository (including the 2D version, image-to-tensor library, etc.) visit the STIM LAB Repository.

Demo

This demo shows the functionality of the TensorView3D program. A tensor field generated from Serial Block-Face Scanning Electron Microscopy (SBF-SEM) data is loaded into the program, where various tools and visualization techniques are applied to the tensor field.

Dependencies

  • Python 3.8+
  • Required Python packages:
    • numpy
    • scikit-image
    • scipy
  • C++ Libraries:
    • OpenGL
    • FreeGLUT
    • Boost Program Options
    • Eigen3
    • GLEW
    • ImGui
    • GLFW3
  • CUDA Toolkit (for GPU-accelerated computations)

Installation

Prerequisites

  • Windows OS (project does not currently support macOS)
  • CUDA Toolkit: Install from NVIDIA CUDA Toolkit.
  • CMake: Version 3.29 or higher.
  • vcpkg (for managing C++ dependencies).

Setting Up vcpkg

Install vcpkg to manage the required C++ packages:

git clone https://github.com/microsoft/vcpkg.git
cd vcpkg
bootstrap-vcpkg.bat

Install Dependencies with vcpkg

Run the following commands to install required libraries:

vcpkg install glfw3 glm imgui[core,glfw-binding,opengl3-binding] glew boost-program-options eigen3

These commands install:

  • glfw3 for window handling
  • glm for math operations
  • imgui for the GUI
  • GLEW for OpenGL extensions
  • Boost (Program Options) for argument parsing
  • Eigen3 for linear algebra

Note: Replace vcpkg paths in CMake if necessary (e.g., CMAKE_TOOLCHAIN_FILE).

Build with CMake

  1. Clone the repository:
    git clone https://github.com/helia77/tensorview3D.git
    cd tensorview3D
  2. Create a build directory and configure CMake:
    mkdir build && cd build
    cmake -DCMAKE_TOOLCHAIN_FILE="path/to/vcpkg/scripts/buildsystems/vcpkg.cmake" ..
  3. Build the project:
    cmake --build . --config Release

Install Python Dependencies

To install Python libraries, run on your conda terminal:

conda install numpy scikit-image scipy

Usage

C++ Implementation

  • Build the C++ executable using CMake (steps above) and run:
    ./tensorview3 --input TENSOR_FILENAME

Contributing

Contributions are welcome! If you'd like to improve this repository, follow these steps:

  1. Fork the repository.
  2. Create a feature branch:
    git checkout -b feature-branch
  3. Commit your changes and push the branch.
  4. Open a Pull Request.

About

Visualization and processing tools for 3D tensor fields

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published