Installation#
This page provides detailed installation instructions for GeomFuM.
Quick Installation#
Install GeomFuM directly from GitHub:
pip install geomfum@git+https://github.com/3diglab/geomfum.git@main
For development installation with all dependencies:
pip install geomfum[opt]@git+https://github.com/3diglab/geomfum.git@main
Prerequisites#
System Requirements#
Python: 3.9 or higher
Operating System: Linux, macOS, or Windows
Memory: At least 4GB RAM (8GB+ recommended for large meshes)
Required Dependencies#
Core dependencies (installed automatically):
numpy- Numerical computingscipy- Scientific computingscikit-learn- Machine learning utilitiesmeshio- Mesh I/Opyfmaps- Functional maps in pythontorch- Deep learning (PyTorch backend)geomstats- Geometric Riemannian statistics
Optional Dependencies#
Install specific optional dependencies based on your needs:
Laplacian Computation#
For robust Laplacian computation:
pip install geomfum[lapl]
This installs:
robust-laplacian- Robust Laplacian computationlibigl- Geometric processing library
Metric Computation#
For advanced metric computations:
pip install geomfum[metric]
This installs:
networkx- Graph algorithmspotpourri3d- 3D geometry processing
Sampling Tools#
For mesh sampling utilities:
pip install geomfum[sampling]
This installs:
pymeshlab- MeshLab Python bindings
Rematching Algorithm#
For the Rematching algorithm:
pip install geomfum[rematching]
This installs:
Rematching- Low-resolution shape correspondence
Sinkhorn Filtering#
For optimal transport-based refinement:
pip install geomfum[sinkhorn]
This installs:
POT- Python Optimal Transport
Visualization#
For visualization capabilities:
# Plotly-based visualization
pip install geomfum[plotly]
# PyVista-based visualization
pip install geomfum[pyvista]
# Polyscope-based visualization
pip install geomfum[polyscope]
# All visualization backends
pip install geomfum[plotting-all]
Testing and Development#
For development and testing:
pip install geomfum[test]
This installs:
pytest- Testing frameworkpolpo- Geometric processing utilitiesAll optional dependencies
Testing scripts and notebooks
Complete Installation#
Install everything:
pip install geomfum[opt,test-scripts,plotting-all]@git+https://github.com/3diglab/geomfum.git@main
Backend Configuration#
GeomFuM supports multiple backends for numerical computations:
NumPy Backend (Default)#
The NumPy backend is used by default and provides good performance for most use cases:
import os
os.environ["GEOMSTATS_BACKEND"] = "numpy"
import geomfum as gfm
PyTorch Backend#
Use PyTorch backend for GPU acceleration and deep learning:
import os
os.environ["GEOMSTATS_BACKEND"] = "pytorch"
import geomfum as gfm
Check Current Backend#
Verify which backend is currently active:
import geomstats.backend as gs
print(f"Current backend: {gs.__name__}")
Troubleshooting#
Common Installation Issues#
C++ Dependencies#
Some dependencies require C++ compilation. If you encounter issues:
Install build tools:
Linux:
sudo apt-get install build-essential
macOS:
Install Xcode Command Line Tools
Windows:
Install
Visual Studio Build Tools
Install Eigen (if required):
Linux:
sudo apt-get install libeigen3-dev
macOS:
brew install eigen
PyRMT Installation#
For the Rematching algorithm, follow the specific instructions:
# Clone and install PyRMT
git clone https://github.com/filthynobleman/rematching.git
cd rematching
git checkout python-binding
pip install -e .
Next Steps#
For issues and questions, visit our GitHub repository or join our Discord server.