Batch 2-photon preprocessing pipeline. Runs configurable source extraction (suite2p or suite3d) from a single JSON configuration file.
This package streamlines source extraction from tiff files (at the moment ScanImage files are supported). Suite2p and Suite3d are currently supported, with features like:
- file concatenation
- flexible parameters handling (also including parameter "sweeps")
- creation of batch files for SLURM
- if the experiment used totalsync for synchronization, imaging and other experimental data (eg. behavioral) are automatically synchronized.
pip install batch2pgit clone https://github.com/NeuroNetMem/batch2p.git
cd batch2p
pip install .# (or uv pip install ".[all]" )this will install batch2p without GUI support, (which is suitable for headless servers). To install the GUI, replace the last line with
pip install ".[gui]"# (or uv pip install ".[gui]" )git clone https://github.com/NeuroNetMem/batch2p.git
cd batch2p
uv pip install .If you need suite3d support, install it manually from source after installing batch2p. See instructions at https://github.com/alihaydaroglu/suite3d.
Briefly,
- Clone the suite3d repository (in a different directory):
git clone https://github.com/alihaydaroglu/suite3d.gitcd suite3d pip install ".[all]"# (or uv pip install ".[all]" )Then, install the suite3d cuda dependencies:
pip install "cupy-cuda13x"# for CUDA 13.X, for other CUDA versions change accordinglyDetailed usage documentation can be found in the docs directory.
- batch2p — single-session pipeline
- batch2p-multi — multi-session batch runner
- batch2p-gui — graphical interface