Skip to content

Add 1.12.1-dj branch: pin CaImAn for worker images on upstream v1.12.1#15

Draft
MilagrosMarin wants to merge 64 commits into
mainfrom
1.12.1-dj
Draft

Add 1.12.1-dj branch: pin CaImAn for worker images on upstream v1.12.1#15
MilagrosMarin wants to merge 64 commits into
mainfrom
1.12.1-dj

Conversation

@MilagrosMarin
Copy link
Copy Markdown
Collaborator

@MilagrosMarin MilagrosMarin commented May 29, 2026

Summary

Creates a 1.12.1-dj branch based on upstream v1.12.1 with the three DataJoint-specific patches that the fmi_luthi worker image depends on, so the worker Dockerfile can move off cloning unpinned main.

Background

The worker image currently clones datajoint/CaImAn with no branch and no commit pin:

RUN git clone https://github.com/datajoint/CaImAn.git

That means two image builds on different days can ship two different CaImAn versions, which makes pipeline runs hard to reproduce. The fork has also drifted to 224 commits behind upstream main. This branch gives us a versioned, pinnable target.

Contents

Branched from upstream v1.12.1, with the existing fork-specific patches replayed as two squashed commits + a VERSION bump:

  • d31e6066 feat(fit_file): add output_dir and return_mc kwargs with CAIMAN_TEMP redirect
  • e39cea7b fix: use caiman.paths.fn_relocated in apply_shifts_movie
  • 94d3bf22 VERSION: bump to 1.12.1+dj1

28 additions, 4 deletions across 3 files. The diff against upstream v1.12.1 is identical in behaviour to the fork-specific patches that landed on main between June 2024 and February 2025 (PRs #8, #9, #10, #13 on this repo) — only the upstream base has moved forward.

Compatibility

The workflow code calls fit_file(..., output_dir=...) at fmi_luthi/src/workflow/pipeline/field_processing.py:183. That call site keeps working unchanged against this branch.

How to use

Pin in dependent projects with:

caiman @ git+https://github.com/datajoint/CaImAn.git@1.12.1-dj

And in the worker Dockerfile:

RUN git clone -b 1.12.1-dj https://github.com/datajoint/CaImAn.git

Test plan

  • Build the calcium-imaging worker image against this branch
  • Run the existing pipeline integration test on the rebuilt image
  • Re-run Andrés's session 4 through the rebuilt worker to compare footprints against his standalone v1.12.1 run

pgunn and others added 30 commits January 14, 2025 21:11
…e-fix

Fix incorrect framerate when loading bidirectional SBX files
Numpy 2.0 compatibility: change all np.Inf to np.inf
pgunn and others added 25 commits February 27, 2025 15:51
…_params_for_nmf

CNMF.initialization.greedyROI() - Add a limited mechanism to specify params in calls to sklearn's NMF
…fix_calling_conventions

Fix calling conventions
…demo_seeded_notebook

Fix demo seeded notebook
…_bad_params_for_huge_files

Handle cases where parameters end up with bad values for OnACID given long movies
…redirect

Adds optional output_dir and return_mc keyword arguments to
CNMF.fit_file:

  - When output_dir is set, CAIMAN_TEMP is redirected to that
    directory for the duration of the call and restored afterwards,
    so per-call outputs land in caller-specified locations without
    leaking global state.
  - When return_mc=True and motion_correct=True, fit_file returns
    (cnm2, mc) so callers can inspect the motion-correction object.

Carried forward from datajoint/CaImAn fork (commits 2447620,
ecc6df6, 5a3ec02, ffcff31, 11417cc, 55969b1) onto upstream
v1.12.1.
Mirror the fn_relocated path-relocation pattern that is already
used elsewhere in motion_correction.py (e.g. line 564) so that
apply_shifts_movie writes its memmap into the relocated path when
CAIMAN_TEMP is set.

Carried forward from datajoint/CaImAn fork (commit fa9f0e7) onto
upstream v1.12.1.
DataJoint patches applied on top of upstream v1.12.1.
Uses PEP 440 local version identifier (+dj1) to mark this as a
distro-patched build of upstream 1.12.1.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants