Installation¶
Requirements¶
Complexplorer requires Python 3.11 or higher. You can check your Python version with:
Basic Installation¶
Install Complexplorer from PyPI using pip:
This installs the core library with its basic dependencies:
numpy>= 1.26.0matplotlib>= 3.8.0scipy>= 1.11.0
Optional Dependencies¶
Complexplorer offers several optional feature sets that you can install as needed:
Interactive Matplotlib Plots (Recommended for CLI Scripts)¶
For interactive matplotlib plots in command-line scripts:
This installs PyQt6 >= 6.5.0 for enhanced matplotlib interactivity.
High-Performance 3D Visualizations (Highly Recommended)¶
For cinema-quality 3D visualizations with 15-30x better performance:
This installs PyVista >= 0.45.0 for high-performance 3D rendering. Strongly recommended if you plan to:
- Create Riemann relief maps
- Work with high-resolution 3D landscapes
- Generate publication-quality 3D visualizations
- Export interactive 3D scenes
PyVista for Best Experience
PyVista provides dramatically better 3D rendering quality and performance compared to matplotlib. Use it via command-line scripts (not Jupyter notebooks) for optimal antialiasing and interactivity.
All Optional Features¶
To install everything at once:
This installs all optional dependencies including PyQt6 and PyVista.
Development Installation¶
If you want to contribute to Complexplorer or run tests, clone the repository and install in editable mode:
# Clone the repository
git clone https://github.com/kuvychko/complexplorer.git
cd complexplorer
# Create and activate virtual environment (optional but recommended)
python -m venv .venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
# Install in editable mode with development dependencies
pip install -e ".[dev]"
The dev extra includes:
pytestfor running testspytest-covfor coverage reports- All optional dependencies (PyQt6, PyVista)
Using uv (Faster Alternative)¶
The project uses uv for fast Python package management:
# Install uv if you don't have it
pip install uv
# Create virtual environment and install
uv venv
source .venv/bin/activate # On Windows: .venv\Scripts\activate
uv pip install -e ".[dev]"
Verifying Installation¶
Test that Complexplorer is installed correctly:
import complexplorer as cp
print(cp.__version__)
# Test basic functionality
domain = cp.Rectangle(2, 2)
f = lambda z: z**2
cp.plot(domain, f)
You should see version information and a plot window showing the phase portrait of z^2.
Platform-Specific Notes¶
Windows¶
- PyQt6 and PyVista install smoothly via pip
- For best PyVista performance, ensure you have updated graphics drivers
macOS¶
- PyQt6 works out of the box
- PyVista may require XQuartz for off-screen rendering:
brew install --cask xquartz
Linux¶
- PyQt6 may require additional system packages:
- PyVista should work without additional dependencies
Upgrading from v1.x¶
If you're upgrading from Complexplorer v1.x to v2.0:
Breaking Changes in v2.0
Version 2.0 introduces breaking API changes. See the Migration Guide for details on updating your code.
Key changes:
n_phiparameter renamed tophase_sectors- New colormap families (PerceptualPastel, Isoluminant, etc.)
- Enhanced phase portrait auto-scaling improvements
- Simplified API with
plot()function
Troubleshooting¶
Import Errors¶
If you get import errors, ensure you're using Python 3.11+:
PyVista Display Issues¶
If PyVista plots don't display:
- Jupyter notebooks: Use
notebook=Trueparameter or switch to command-line scripts - Remote SSH: Set
show=Falseand usefilename='output.png'to save plots - Graphics drivers: Update your graphics drivers for best performance
Matplotlib Backend Issues¶
If matplotlib plots don't appear interactively:
Next Steps¶
Now that you have Complexplorer installed, check out:
- Quick Start Guide - Create your first visualization
- User Guide - Learn about domains and colormaps
- Examples Gallery - Explore beautiful visualizations