Skip to content

Repository files navigation

Simphony

Build Release Latest Release GHCR Package

Simphony is a GPU-accelerated optical photon transport framework that couples NVIDIA OptiX with Geant4 for detector simulation workflows. It imports GDML detector geometries, offloads optical photon propagation to NVIDIA GPUs, and provides example applications for Cerenkov, scintillation, torch-driven, and file-driven photon transport studies.

The project builds on Simon Blyth's original Opticks work and adapts that approach for current OptiX- and Geant4-based simulation workflows.

Quick start

Build from source

If CUDA 12.1+, NVIDIA OptiX 7+, Geant4 11.3+, CMake 3.22+, and Python 3.10+ are already installed, you can build and test Simphony directly:

git clone https://github.com/BNLNPPS/simphony.git
cd simphony
cmake -S . -B build
cmake --build build
ctest --test-dir build

You can edit and build without a GPU. Running Simphony and its GPU-backed tests requires a CUDA-capable NVIDIA GPU.

Use the Dev Container

For a ready-made environment, first install Docker Engine. Then install the Dev Container CLI and start the environment:

npm install -g @devcontainers/cli
git clone https://github.com/BNLNPPS/simphony.git
cd simphony
devcontainer up
devcontainer exec bash

The source tree is mounted into the container. Once inside, use the same CMake commands above and rerun only the relevant build and tests as you work.

The root .env selects the OS and toolchain versions. See Choose dependency versions before changing them.

To run GPU-backed code, install the NVIDIA Container Toolkit on the host. The Dev Container CLI detects the NVIDIA runtime and requests GPU access automatically.

Try a published image

To take the latest release for a quick test drive, use Docker or Apptainer:

docker run --rm --gpus all ghcr.io/bnlnpps/simphony simg4ox -g tests/geom/raindrop.gdml -m tests/run.mac
apptainer exec --nv docker://ghcr.io/bnlnpps/simphony simg4ox -g /workspaces/simphony/tests/geom/raindrop.gdml -m /workspaces/simphony/tests/run.mac

Install with Spack

Simphony is also available through the BNLNPPS Spack repository:

spack repo add https://github.com/BNLNPPS/spack-packages
spack install simphony

See Getting started for targeted test commands, container lifecycle tips, native builds, and NERSC usage.

Documentation

Published container images

The project publishes reusable base images for development environments and Docker build-cache warmup, along with versioned release and develop images. Pushes to main update the versioned tags, while tagged releases update the latest alias. Every tag below links to the Simphony package page.

Target OS CUDA OptiX Geant4 CMake Alias Tag
base ubuntu26.04 13.3.0 9.1.0 11.4.2 4.3.4 cuda13.3.0-base-ubuntu26.04-optix9.1.0-geant411.4.2-cmake4.3.4
base ubuntu24.04 13.0.3 9.0.0 11.4.2 4.2.1 base cuda13.0.3-base-ubuntu24.04-optix9.0.0-geant411.4.2-cmake4.2.1
base ubuntu24.04 12.5.1 9.0.0 11.4.1 3.28.3 cuda12.5.1-base-ubuntu24.04-optix9.0.0-geant411.4.1-cmake3.28.3
base ubuntu22.04 12.1.1 8.0.0 11.3.2 3.22.1 cuda12.1.1-base-ubuntu22.04-optix8.0.0-geant411.3.2-cmake3.22.1
release ubuntu26.04 13.3.0 9.1.0 11.4.2 4.3.4 cuda13.3.0-release-ubuntu26.04-optix9.1.0-geant411.4.2-cmake4.3.4
release ubuntu24.04 13.0.3 9.0.0 11.4.2 4.2.1 latest cuda13.0.3-release-ubuntu24.04-optix9.0.0-geant411.4.2-cmake4.2.1
release ubuntu22.04 12.1.1 8.0.0 11.3.2 3.22.1 cuda12.1.1-release-ubuntu22.04-optix8.0.0-geant411.3.2-cmake3.22.1
develop ubuntu24.04 13.0.3 9.0.0 11.4.2 4.2.1 develop cuda13.0.3-develop-ubuntu24.04-optix9.0.0-geant411.4.2-cmake4.2.1
develop ubuntu24.04 12.5.1 9.0.0 11.4.1 3.28.3 cuda12.5.1-develop-ubuntu24.04-optix9.0.0-geant411.4.1-cmake3.28.3
develop ubuntu22.04 12.1.1 8.0.0 11.3.2 3.22.1 cuda12.1.1-develop-ubuntu22.04-optix8.0.0-geant411.3.2-cmake3.22.1

About

GPU-Accelerated Optical Photon Simulation using NVIDIA OptiX

Resources

Stars

Watchers

Forks

Releases

Packages

Used by

Contributors

Languages