Installing and compiling SVD
You can either use the precompiled version of SVD, or build SVD for yourself.
Installing SVD
The executable folder contains all the required files and libraries for Windows. There is no separate installation. To run SVD, start the SVDUI.exe (instructions).
For DNN inference, SVD now uses ONNX Runtime. The required library onnxruntime.dll (CPU version) is included in the executable folder.
Instructions for compiling SVD
The SVD model is a stand alone modelling software written in C++ and available under a GPL license. SVD builds on the Qt framework, and is best compiled and modified with the tools provided by Qt (e.g. the QtCreator IDE).
Currently, building SVD is available for Windows, Linux, and macOS.
SVD consists of a number of sub-projects:
Predictor: the link to ONNX Runtime; this part includes ONNX-headers and contains the logic for communicating with the inference engine.SVDCore: The main part of the model (representation of the simulated area, data, …)SVDUI: The Qt-based user interface
To build SVD:
- open the
SVDModel.profile in QtCreator - Build all sub-projects
- Run the
SVDUI.exe(Windows) or the resulting binary (Linux/Mac)
Compiling SVD with ONNX Runtime
SVD requires the ONNX Runtime C++ API.
[!IMPORTANT] Do NOT use
pip install,nuget, or other package managers for installing ONNX Runtime for SVD. These are intended for Python or .NET environments. For SVD (C++), you must download the precompiled shared library binaries (headers and.so/.dllfiles) directly from the Official GitHub Releases.
Windows
- Download the ONNX Runtime binaries (e.g.,
onnxruntime-win-x64-n.n.n.zip) from the official releases. - Extract the archive to a local directory (e.g.,
C:\dev\onnxruntime). - In SVD’s
SVDModel/config.pri, set theONNXRUNTIME_DIRto this path if it differs from the default. - Copy
onnxruntime.dllto your build output folder (whereSVDUI.exeresides).
Linux (Ubuntu / Fedora)
The build system expects ONNX Runtime to be located in /opt/onnxruntime.
Example: Manual installation for GPU support
# 1. Choose a version compatible with your CUDA/cuDNN (e.g., 1.17.1)
VERSION="1.17.1"
FILENAME="onnxruntime-linux-x64-gpu-${VERSION}.tgz"
# 2. Download from GitHub
wget https://github.com/microsoft/onnxruntime/releases/download/v${VERSION}/${FILENAME}
# 3. Extract and move to /opt/onnxruntime
sudo mkdir -p /opt/onnxruntime
sudo tar -xzf ${FILENAME} -C /opt/onnxruntime --strip-components=1
# 4. Cleanup
rm ${FILENAME}
# 5. Configure the dynamic linker so the OS can find the libraries
echo "/opt/onnxruntime/lib" | sudo tee /etc/ld.so.conf.d/onnxruntime.conf
sudo ldconfigIf you only need CPU support, replace gpu with cpu in the filename above.
macOS
- Download the macOS binaries (universal or x64/arm64 depending on your hardware).
- Extract to a preferred location and update
ONNXRUNTIME_DIRinSVDModel/config.pri. - Alternatively, you can install via Homebrew (
brew install onnxruntime), but ensure the paths inconfig.primatch (Homebrew usually installs to/usr/localon Intel or/opt/homebrewon Apple Silicon).
Using GPU acceleration (CUDA)
To use NVIDIA GPUs for faster DNN inference:
- Requirement: You must have an NVIDIA GPU and compatible drivers installed.
- ONNX Runtime: Download the GPU-enabled version of ONNX Runtime (e.g.,
onnxruntime-linux-x64-gpu-*). - CUDA & cuDNN: Install the versions of CUDA and cuDNN that are compatible with the ONNX Runtime version you downloaded (check the ONNX Runtime documentation).
- Note: Newer versions of ONNX Runtime (e.g., 1.17+) often require cuDNN 9.x.
- Ubuntu Installation: To install cuDNN 9, you typically need to add the NVIDIA repository and run:
bash sudo apt-get install libcudnn9-cuda-12 - Verification: Use
ldd /opt/onnxruntime/lib/libonnxruntime_providers_cuda.soto ensure all dependencies (likelibcudnn.so.9) are found.
- Build Configuration: In
SVDModel/config.pri, uncomment the line:DEFINES += USE_CUDA - Execution: When SVD starts, it will attempt to initialize the CUDA execution provider. Check the log output to verify if it succeeded or fell back to CPU.
other installs
FreeImage
Used in SVD for loading and saving GeoTIFF files.
Linux:
sudo apt-get install libfreeimage-dev # Ubuntu
sudo dnf install FreeImage-devel # FedoraOpenGL
Used for rendering the landscape.
Linux:
sudo apt-get install libgl-dev libgl1-mesa-dev # Ubuntu
sudo dnf install mesa-libGL-devel # FedoraSVD without ONNX
SVD can be used without ONNX Runtime. This version is not able to use DNNs for estimating state transitions, but can still be useful, e.g., as a pure state-and-transition-model using the matrix module.
To build SVD without ONNX, you need to update the file SVDModel/config.pri. To disable ONNX, comment out this line:
DEFINES += USE_ONNXRUNTIME
Save and recompile (ensure that qmake is executed).