Miniscope-IO
mio is our in-development project aiming to provide a consistent, usable programatic interface for interacting with all the devices we make! This page is just a brief project description, for up to date information, please refer to the documentation at https://miniscope-io.readthedocs.org
It was originally developed for the Miniscope Zero project, and we will be extending support for the Miniscope V4 and all other future devices. It replaces previous software that bundled the underlying software too tightly with a GUI or an external program like Bonsai - now we are building the SDK first and then layering a GUI on top.
Mio is built on noob - a lightweight, researcher-focused graph processing library that allows us to build device adapters by stringing together individual operations into reusable pipelines. This design enables rapid development for future devices by reducing the amount of new code needed to only that which is unique to the new device, and re-use the rest. It scratches the itch of tool developers and researchers alike to jam random plotting code, intermediate data i/o, and etc. in the middle of the pipeline, but allows them to do so safely, reversibly, and performantly!
The underlying graph looks something like this - researchers don't need to mess with this if they don't want to, but it's available for them if they want to modify the way it works at a deeper level than most acquisition software allows, right down to the raw bitstream off the scope:
Our goal is to make our scopes easier to integrate into the kind of multimodal experiments with very diverse hardware that are typical in neuroscience: rather than needing to click "play" on 6 different GUIs and computers, miniscopes should be as easy to integrate into your experimental code as any other python library. Through noob, we also will be making cross-language compatibility possible, with a generic streaming protocol available over websockets (for use in browser-based apps), udp, etc.
Target Python API
The package is still a WIP, but we are aiming for a programming interface that looks something like this
from mio import MiniscopeZero
# use defaults, find the first scope
scope = MiniscopeZero()
# use a custom config by referring to its name
scope = MiniscopeZero(config="my-config")
# set and get configuration options
scope.set("exposure", 0.5)
scope.get("exposure")
# just capture to a file forever
scope.capture(video="video.mp4", metadata="metadata.csv")
# iterate over frames within python
for headers, frame in scope.iter():
# do something with the frame! idk like display it!
cv2.imshow("miniscope", frame)
Or from the CLI
# capture forever!
mio capture -c my-config -o ./some-data-directory
# display the frames as they are captured!
mio capture -c my-config -o ./some-data-directory --display
GUI
(work in progress! Spring 2026 is the goal)
