ophyd
Bluesky hardware abstraction with an emphasis on EPICS
What it is and what it does
Ophyd is a hardware abstraction library designed for scientific experiment orchestration and data acquisition. It sits between experiment control code and physical devices or control systems, allowing you to write device-agnostic logic that works across different hardware setups. The library is built around the concept of grouping individual control channels (such as EPICS PVs) into logical Device objects with high-level methods like trigger(), read(), and set(...), and it assigns meaningful names and metadata categories to readings so they propagate correctly into analysis pipelines.
Ophyd is typically used with the Bluesky Run Engine for coordinated experiment execution, though it can also be used standalone. It supports EPICS as a primary control system but is designed to work with other systems as well. The library depends on networkx, numpy, opentelemetry-api, packaging, and pint for graph operations, numerical work, observability, version handling, and unit management respectively.
Use it for:
- Integrate EPICS-based beamline hardware into a Python experiment orchestration workflow without writing device-specific control code.
- Group related motor, detector, and sample-stage channels into a single Device object that can be configured and used as a coordinated unit.
- Assign meaningful names and metadata categories to sensor readings so they flow correctly into data analysis pipelines and experiment logs.
- Build portable experiment scripts that work across different beamlines or facilities by abstracting away hardware-specific details.
- Coordinate multi-step experiments where devices must be triggered, read, and configured in a specific sequence.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Ophyd provides a Python abstraction layer for hardware control and data acquisition, enabling experiment orchestration code to work with devices and control systems like EPICS without device-specific details.
Yes. Ophyd is actively maintained, production-stable, has no known vulnerabilities, and installs with low friction. It is the standard abstraction layer for hardware control in the Bluesky ecosystem and is well-suited for scientific facilities and research labs that need to orchestrate experiments across diverse hardware. Install it if you are building experiment control code or integrating with EPICS or similar control systems.
Install
ophyd on PyPI
pip
pip install ophyduv
uv add ophydpoetry
poetry add ophydInstalling ophyd
Before you install
Low install friction with a pure-wheel distribution. The package is actively maintained with a recent release and supports current Python versions (3.8–3.13). Five runtime dependencies are all standard scientific/utility libraries.
License in practice
BSD license is permissive, allowing commercial and private use with minimal restrictions; you may use, modify, and distribute ophyd freely provided you retain the license notice.
Quickstart
pip install ophyd
from ophyd import Device, Component
from ophyd.epics_motor import EpicsMotor
class MyMotor(Device):
motor = Component(EpicsMotor, 'PV:motor')
device = MyMotor(name='my_motor')
Requires an EPICS control system or compatible hardware backend to be useful; standalone use is possible but limited.
Verify before relying
- Specific EPICS version compatibility and whether non-EPICS control systems are equally well-supported.
- Performance characteristics when handling large numbers of devices or high-frequency data streams.
- Integration maturity with control systems other than EPICS.
Package facts
| License | BSD (permissive) |
| Python support | supports the current Python release (>=3.8) |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 5 — networkx, numpy, opentelemetry-api, packaging, pint |
| Maintenance | actively maintained — 71 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 97,103/month — #13,167 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: ophyd-1.11.2-py3-none-any.whl
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
ophyd-asyncophyd-async provides asynchronous hardware…
permissive · top 15,000 on PyPI
blueskyBluesky is an experiment control and scientific…
permissive · top 15,000 on PyPI
epik8s-toolsAutomates project structure, Helm chart, and…
permissive · top 15,000 on PyPI
epicscorelibsProvides compiled EPICS Core libraries and…
unclear · top 15,000 on PyPI
pykaosPyKAOS provides an abstraction layer for agents…
unclear · top 15,000 on PyPI
zhinst-toolkitzhinst-toolkit provides a high-level Python…
permissive · top 15,000 on PyPI
event-modelDefines and validates the formal data model for…
permissive · top 15,000 on PyPI
pyadi-iiopyadi-iio provides Python classes that wrap…
permissive · top 15,000 on PyPI
qcodesQCoDeS is a Python data acquisition and control…
permissive · top 15,000 on PyPI
phoebusgenGenerates Phoebus Display Builder XML format…
copyleft · top 15,000 on PyPI