pyds9
Python/DS9 connection via XPA (with numpy and pyfits support)
What it is and what it does
pyds9 is a Python wrapper around the XPA messaging system that enables programmatic control of SAO DS9, an interactive astronomical image viewer. It allows you to open DS9 windows, load FITS image files, and send commands to DS9 from Python code, bridging the gap between Python data analysis and interactive visualization.
The package wraps XPA to communicate with DS9 instances. It has no runtime dependencies, but requires compilation of bundled C code during installation, which depends on X11 development libraries. The package has received no updates since its initial release in 2016-08-05, and shows no recent maintenance activity, making it a legacy tool with uncertain compatibility on modern systems.
Use it for:
- Automate loading and display of FITS astronomical images in DS9 from Python analysis pipelines
- Query which DS9 windows are currently open and send commands to specific instances programmatically
- Build interactive astronomy workflows that combine Python data processing with DS9 visualization
- Test or script DS9 functionality as part of astronomy software testing suites
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
pyds9 provides a Python interface to communicate with SAO DS9 (an astronomical image viewer) via the XPA messaging system, allowing remote control of DS9 windows and image display.
No, unless you are maintaining legacy astronomy code that already depends on pyds9. The package is abandoned (no updates since 2016-08-05), has unclear licensing, requires non-trivial system dependencies and C compilation, and offers no assurance of compatibility with modern Python or X11 environments. For new projects, consider whether DS9 integration is necessary or if alternative approaches would be more maintainable.
Install
pyds9 on PyPI
pip
pip install pyds9uv
uv add pyds9poetry
poetry add pyds9Installing pyds9
Before you install
Installation requires compilation of C code and X11 development libraries (libXt-devel or libxt-dev), making setup non-trivial on many systems. The package has been abandoned since 2016-08-05 with no maintenance activity, presenting significant risk for compatibility issues with modern Python and system libraries.
License in practice
License treatment is unclear (marked UNKNOWN with no SPDX identifier), making it difficult to assess legal implications for commercial or redistributed use without consulting the source repository directly.
Quickstart
import pyds9
print(pyds9.ds9_targets())
d = pyds9.DS9()
d.set("file /path/to/fits")
Requires X11 development headers (libXt-devel on openSUSE, libxt-dev on Ubuntu), a working C compiler, and DS9 installed separately; installation involves C compilation.
Verify before relying
- Compatibility with Python versions released after 2016 (requires_python is unspecified)
- Whether the package works with modern X11 implementations and current DS9 releases
- Current maintenance status of the repository (archived status unclear despite last commit in 2016)
Package facts
| License | UNKNOWN (unclear) |
| Python support | not specified |
| Install friction | high — source build required |
| Runtime dependencies | none |
| Maintenance | abandoned — 3,661 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 238,847/month — #8,929 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: pyds9-1.8.1.tar.gz
Keywords: astronomy, science, ds9
Tags
More Scientific/Engineering packages
NumPy provides an N-dimensional array object…
permissive · top 100 on PyPI
pandaspandas provides fast, flexible data structures…
permissive · top 100 on PyPI
scipyscipy provides numerical algorithms for…
permissive · top 100 on PyPI
scikit-learnscikit-learn provides a comprehensive Python…
permissive · top 1,000 on PyPI
dilldill extends Python's pickle module to…
permissive · top 1,000 on PyPI
multiprocessMultiprocess is an enhanced fork of Python's…
permissive · top 1,000 on PyPI
pyvoPyVO provides Python access to Virtual…
permissive · top 15,000 on PyPI
specutilsSpecutils provides Python representations of…
permissive · top 15,000 on PyPI
PyAVMPyAVM reads, writes, and embeds Astronomy…
permissive · top 15,000 on PyPI
xlibProvides a pure-Python X11 client library for…
copyleft · top 15,000 on PyPI
photutilsPhotutils provides tools for detecting and…
permissive · top 15,000 on PyPI
lsst-daf-butlerProvides an abstraction layer for reading and…
unclear · top 15,000 on PyPI
astroqueryAstroquery provides a Python interface to query…
permissive · top 15,000 on PyPI
regionsRegions provides tools for defining,…
permissive · top 15,000 on PyPI
ephemPyEphem computes high-precision positions of…
permissive · top 5,000 on PyPI
reprojectReproject astronomical images between different…
permissive · top 15,000 on PyPI