bpod-core#
A modern Python interface for Bpod Finite State Machines.
Warning
bpod-core is under development and not yet ready for production use.
bpod-core is a Python library for running behavioral experiments on Bpod hardware. You describe the trial logic as a finite state machine; bpod-core validates it, runs it on a connected Bpod device, and returns every recorded event with precise timestamps as an analysis-ready data frame.
Bpod Finite State Machines are an open-source platform by Sanworks for controlling behavioral experiments: a microcontroller-based finite state machine that runs the trial logic in real time and talks to sensors, valves, and other peripherals with deterministic millisecond-scale timing. Running the state machine on dedicated microcontroller hardware, rather than a general-purpose computer, keeps time-critical trial execution isolated from operating-system scheduling jitter. This makes Bpod particularly well-suited to closed-loop experiments, where state transitions must be triggered by sensor readings within a tight, predictable latency.
bpod-core grew out of the need for a modern, well-tested way to work with Bpod devices from Python, and is designed to fit naturally into everyday research workflows. It is maintained by the software development team at the International Brain Laboratory.
Goals#
Interface to Bpod Devices: Provides an interface for interacting with Bpod devices.
State Machine Management: Offers capabilities to define, validate, and run state machines.
Standalone or Library Use: Can function independently or be integrated as a library within other projects.
Performance-Oriented: Designed to be lean and fast.
Quality Assurance: Typed, tested, and documented.
Non-Goals#
No GUI: Does not include a graphical user interface.
Limited High-Level Functionality: Does not provide features such as data management, configuration, or calibration.
No Specific Module Support: Does not implement support for specific Bpod modules.