Installation#
Quick Install#
For most users, we recommend installing via conda:
conda install -c conda-forge gwpy
pip install gwpy
uv pip install gwpy
pip install git+https://gitlab.com/gwpy/gwpy.git
New to Python?
We recommend uv,
an extremely fast Python package and project manager.
For 99% of operations, just replace pip install with
uv pip install.
For environments that need more than just Python packages, we recommend conda-forge, a community-driven Conda package channel and distribution (without the licensing issues of Anaconda).
Detailed Installation#
Creating a Virtual Environment#
It’s good practice to install GWpy in a virtual environment:
conda create -n gwpy-env -c conda-forge gwpy
uv venv
uv pip install gwpy
Installing from Source#
To install the latest development version:
git clone https://gitlab.com/gwpy/gwpy.git
cd gwpy
pip install .
For development with editable install:
pip install -e . --group dev
Optional Dependencies#
GWpy has several optional dependencies for additional functionality:
Feature |
Install command |
Description |
|---|---|---|
GWF I/O |
|
Read/write GWF (gravitational wave frame) files |
Authentication |
|
Access proprietary data with credentials |
Advanced SQL |
|
Enhanced database query capabilities |
Astronomical calculations |
|
Compute inspiral ranges and other astrophysical quantities |
Pelican data access |
|
Read data from Pelican servers |
Type checking |
|
Install type checking dependencies (e.g., |
Note
Conda doesn’t support optional dependencies, so you may have to install them manually, or use pip within your conda environment.
For details on some of the gravitational-wave specific optional dependencies, see External packages.
Verifying Installation#
Check that GWpy is installed correctly:
python -c "import gwpy; print(gwpy.__version__)"
You should see the version number printed, e.g., 3.0.0.
Test with a simple example:
from gwpy.timeseries import TimeSeries
import numpy as np
# Create a simple time series
data = TimeSeries(np.random.random(1000), sample_rate=1)
print(data)
If this runs without errors, you’re all set!
Need Help?#
If you’re still having trouble:
Check the issue tracker for known problems
Ask on our Slack channel
Open a new issue with details about your problem