Add a batch import for multicam datasets#1745
Merged
Merged
Conversation
Scans a root folder of collect folders (collect -> camera -> images) and produces per-collect beginMultiCamImport arguments for MML seal surveys, without copying imagery. Camera subfolders are matched case-insensitively across collects; the canonical camera set is the union of image-bearing subfolder names, limited to 2-3 alphanumeric cameras to match the existing multicam subfolder import. Missing/empty/imageless camera folders are reported as per-collect blocking problems; frame-count mismatches are non-blocking warnings (seal collects legitimately drop frames). Default display camera follows pickDefaultMulticamCamera (center/middle alias, else the middle camera of display order). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
New 'MultiCam Batch' entry in the Open Image Sequence dropdown (desktop only, behind a new batch-multi-cam-import prop on ImportButton) opens ImportMultiCamBatchDialog: pick a root folder, review a per-collect validation summary table (cameras, frame counts, problems/warnings), then import all valid collects sequentially via the existing import-multicam-media / finalize-import machinery, continuing past per-collect failures and reporting a final summary. Adds the scan-multicam-batch IPC handler and scanMultiCamBatch frontend API. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Collaborator
|
Some updates to this PR:
Demo Video: 20260708-DIVE-MultiCamBatchImport_small.mp4 |
BryonLewis
approved these changes
Jul 8, 2026
BryonLewis
left a comment
Collaborator
There was a problem hiding this comment.
I left it as a dropdown under image-sequence and added some functionality to skip certain sub-folders, as well as edit the name of the dataset during import.
Added the same functionality to the web version.
Updated documentation as well.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A high-level overview of this branch (
dev/multicollect-import, offdev/sealtk) for reviewers.What it does
Imports many multicam datasets in one action. You point DIVE at a top-level folder whose
subfolders are "collects"; each collect holds the same set of camera subfolders (e.g.
EO/,IR/,UV/) of image frames. DIVE scans and validates them, shows a summary table, and thencreates one multicam dataset per collect — referencing the imagery in place (nothing is copied).
Why it exists
Seal (and similar aerial) surveys produce dozens of collects in the same camera layout.
Importing them one at a time through the normal multicam dialog is slow and error-prone. This
adds a single "scan a folder, import them all" flow with up-front validation, so a whole survey
lands in a few clicks and bad collects are flagged instead of silently failing mid-way.
GUI elements added
ImportButton).ImportMultiCamBatchDialog.vue):counts), any validation problems (blocking, red) or warnings (non-blocking, amber,
e.g. differing frame counts), and a live status chip (Ready / Importing / Imported /
Failed / Skipped).
How it's implemented (high level)
multiCollectImport.ts, desktop backend) — lists collect folders, finds theimage-bearing camera subfolders, derives the canonical camera set (union of camera names
across collects, matched case-insensitively), validates it (must be 2–3 valid camera names),
and per collect produces either ready-to-run import arguments or a list of blocking problems.
It reuses the existing multicam import backend (
findImagesInFolder, the subfolder-layouthelpers,
beginMultiCamImport→finalizeImport→convert) so no new import path or copyingis introduced.
scan-multicam-batch) and itsapi.tswrapper; a small setof result types (
MultiCamBatchScanResult/…Collect/…Camera) inconstants.ts.per-collect
try/catchso one failure doesn't stop the batch (mirrors the existing bulkimport). Status is tracked reactively and the recents list refreshes after each import.
Files it touches (8 files, ~914 lines)
client/platform/desktop/backend/native/multiCollectImport.ts(+ 263-line spec)client/platform/desktop/backend/ipcService.ts,frontend/api.ts,constants.tsclient/platform/desktop/frontend/components/ImportMultiCamBatchDialog.vueclient/dive-common/components/ImportButton.vue,platform/desktop/frontend/components/Recent.vuePlatform support
Desktop only. The scanner, IPC channel, and dialog all live under
platform/desktop. Theshared
ImportButtongained abatchMultiCamImportprop that defaults to false, and onlythe desktop
Recent.vueturns it on — so the menu entry never appears on web and nothing elsechanges there. (Batch import needs direct filesystem folder scanning, which the web platform
doesn't do.)