Context
CellpyCell.merge(..., mode="campaign", renumber_cycles=False) raises
NotImplementedError with the message that it "requires per-test summary
support through the core bridge; tracked for the native-schema path (#511)"
(cellreader.py, campaign branch of merge()).
That blocker is gone. cellpycore 0.2.2 (core #136) delivered exactly the
missing pieces on the legacy bridge:
So the per-test grouping/windowing machinery the flag needs now exists end to
end on the legacy path — ahead of the native-schema runtime (#511 shipped the
opt-in, but campaign merge is not supported on native-schema cells yet).
Work
merger.campaign_fold: make the cycle offset conditional on
renumber_cycles (data-point offsets must stay unconditional — raw
data_point must remain globally unique for fid/step lookups).
- Drop the
NotImplementedError guard in CellpyCell.merge and forward the
flag.
- Decide/document consumer semantics for duplicate cycle numbers: with
original numbering, (test_id, cycle) is the key — cycle-keyed consumers
(get_cap(cycle=...), split_many, with_cycles, exporters) will see
duplicate cycle numbers. Minimum bar: document that these operate on the
union of matching cycles; anything smarter is follow-up.
- Tests: campaign merge with
renumber_cycles=False on the two-res-file
fixture (tests/test_merge_campaign.py) — raw/steps/summary keep original
per-test cycle numbers, test_id values stay {0, 1}, recomputed summary
windows per test (cumulatives reset at the test boundary), and a v9
round-trip preserves everything.
Refs
🤖 Generated with Claude Code
Context
CellpyCell.merge(..., mode="campaign", renumber_cycles=False)raisesNotImplementedErrorwith the message that it "requires per-test summarysupport through the core bridge; tracked for the native-schema path (#511)"
(cellreader.py, campaign branch of
merge()).That blocker is gone. cellpycore 0.2.2 (core #136) delivered exactly the
missing pieces on the legacy bridge:
test_idis carried through the legacy steps and summary output,test_id,right-hand summary's
test_idand removed the v2: composite group keys + multi-file merge (V2-03/07) #507 re-stamp workaround.So the per-test grouping/windowing machinery the flag needs now exists end to
end on the legacy path — ahead of the native-schema runtime (#511 shipped the
opt-in, but campaign merge is not supported on native-schema cells yet).
Work
merger.campaign_fold: make the cycle offset conditional onrenumber_cycles(data-point offsets must stay unconditional — rawdata_pointmust remain globally unique for fid/step lookups).NotImplementedErrorguard inCellpyCell.mergeand forward theflag.
original numbering,
(test_id, cycle)is the key — cycle-keyed consumers(
get_cap(cycle=...),split_many,with_cycles, exporters) will seeduplicate cycle numbers. Minimum bar: document that these operate on the
union of matching cycles; anything smarter is follow-up.
renumber_cycles=Falseon the two-res-filefixture (
tests/test_merge_campaign.py) — raw/steps/summary keep originalper-test cycle numbers,
test_idvalues stay{0, 1}, recomputed summarywindows per test (cumulatives reset at the test boundary), and a v9
round-trip preserves everything.
Refs
(summary test_id remap + workaround removal)
🤖 Generated with Claude Code