Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
60 commits
Select commit Hold shift + click to select a range
d8babe3
Encapsulate pipette batch scheduling into dedicated module
BioCam Mar 12, 2026
8eece6f
make x_grouping_tolerance required argument
BioCam Mar 13, 2026
cbee224
Merge branch 'PyLabRobot:main' into encapsulate-pipette-batch-scheduling
BioCam Mar 16, 2026
fa39d12
Merge branch 'PyLabRobot:main' into encapsulate-pipette-batch-scheduling
BioCam Mar 20, 2026
a032cd5
Fix spacings list sizing in plan_batches when num_channels exceeds ma…
BioCam Mar 20, 2026
4310973
Remove detection parameter exposure from probe_liquid_heights (defer …
BioCam Mar 20, 2026
607565b
explain dual exception handling
BioCam Mar 20, 2026
ae9cc13
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Mar 21, 2026
b3b326b
Merge branch 'PyLabRobot:main' into encapsulate-pipette-batch-scheduling
BioCam Mar 22, 2026
6d53765
Refactor plan_batches to accept containers, add execute_batched, fix …
BioCam Mar 22, 2026
564f36a
create `print_batches`
BioCam Mar 22, 2026
f6e8690
fix linting
BioCam Mar 22, 2026
9c3448a
`make format`
BioCam Mar 22, 2026
8c3b851
Merge branch 'main' into encapsulate-pipette-batch-scheduling
rickwierenga Mar 22, 2026
5bf7bb6
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Mar 23, 2026
5147f11
update docstrings
BioCam Mar 23, 2026
5e46375
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Mar 24, 2026
d143bdf
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Mar 24, 2026
c7e18ff
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Mar 26, 2026
1f94198
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Mar 29, 2026
19f7332
Merge origin/main into encapsulate-pipette-batch-scheduling
BioCam Apr 8, 2026
3be2bc8
Improve probe_liquid_heights Z handling, use compute_channel_offsets …
BioCam Apr 8, 2026
8ad38ab
add TODO for move to radii model (out of PR scope)
BioCam Apr 8, 2026
cee71a1
Allow duplicate `use_channels`, remove redundant inline comment
BioCam Apr 8, 2026
afe8996
Address PR review: reorder `validate_channel_selections` args, use li…
BioCam Apr 8, 2026
37e5449
Return data from callbacks, don't mutate inputs, use literal box-draw…
BioCam Apr 8, 2026
b485855
Simplify plan_batches to coordinates-only, validate channel_spacings,…
BioCam Apr 9, 2026
6f8f734
Remove obsolete odd-span center shift, inline `_offsets_for_consecuti…
BioCam Apr 9, 2026
cd192fc
Route single-channel container offsets through compute_channel_offset…
BioCam Apr 9, 2026
6dcf72e
Apply container offsets for single-channel targets, consolidate lld_m…
BioCam Apr 9, 2026
f6cd56f
Guard _min_spacing_between against non-adjacent channel indices
rickwierenga Apr 10, 2026
20ad929
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Apr 10, 2026
a19c32d
Scope `_effective_spacing` to sub-group in `compute_single_container_…
BioCam Apr 10, 2026
b206201
Inline `_min_spacing_between` into `_span_required`
BioCam Apr 10, 2026
7307c8e
Remove redundant lo→candidate span check from batch partitioning
BioCam Apr 10, 2026
665fc36
Move `compute_single_container_offsets` to channel_positioning
BioCam Apr 10, 2026
b3e43e9
Rename to `compute_nonconsecutive_channel_offsets`, improve docstring…
BioCam Apr 10, 2026
c488da2
Simplify batch partitioning, inline into plan_batches, update stale d…
BioCam Apr 10, 2026
1d100ff
Reject duplicate channels in `probe_liquid_heights` but allow in gene…
BioCam Apr 10, 2026
16a323f
Override `execute_batched` in chatterbox, restructure `probe_liquid_h…
BioCam Apr 10, 2026
f47c312
Extract `_prepare_batched` for reuse by future aspirate/dispense
BioCam Apr 11, 2026
3be0993
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Apr 11, 2026
25276b8
Promote per-batch LLD callback to override hook, collapse chatterbox
BioCam Apr 13, 2026
54daf5c
Accept per-container `LLDMode` list in `probe_liquid_heights`
BioCam Apr 13, 2026
b79b41a
`make format`
BioCam Apr 13, 2026
967a0f8
Merge remote-tracking branch 'origin/main' into encapsulate-pipette-b…
rickwierenga Apr 13, 2026
553bae0
Merge branch 'encapsulate-pipette-batch-scheduling' of https://github…
rickwierenga Apr 13, 2026
aa8bdfa
Replace greedy first-fit batching with container-aware exact-cover pl…
rickwierenga Apr 14, 2026
5259557
Rewrite pipette_batch_scheduling module docstring with problem classi…
BioCam Apr 14, 2026
57e47dc
Narrow `is_valid_batch` return in tests and drop unused imports
BioCam Apr 14, 2026
bb743ca
Merge pull request #1 from PyLabRobot/refactor-plan-batches-exact-cover
BioCam Apr 15, 2026
a5eb57d
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Apr 16, 2026
d939f3f
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Apr 17, 2026
6fcb20a
Merge branch 'main' into encapsulate-pipette-batch-scheduling
BioCam Apr 17, 2026
dbc6d95
Review fixes: log_batches, deprecate move_to_z_safety_after, restore …
rickwierenga Apr 18, 2026
a465d04
Merge branch 'main' into encapsulate-pipette-batch-scheduling
rickwierenga Apr 18, 2026
58d473d
Review fixes: canonical x_position, support duplicate channels, depre…
rickwierenga Apr 22, 2026
4697a88
Merge branch 'main' into encapsulate-pipette-batch-scheduling
rickwierenga Apr 24, 2026
d6048a4
Remove duplicate TestChannelsMinimumYSpacing class in STAR_tests
rickwierenga Apr 24, 2026
0f7a583
Apply ruff format and import sort
rickwierenga Apr 24, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
616 changes: 316 additions & 300 deletions pylabrobot/liquid_handling/backends/hamilton/STAR_backend.py
Comment thread
BioCam marked this conversation as resolved.

Large diffs are not rendered by default.

50 changes: 33 additions & 17 deletions pylabrobot/liquid_handling/backends/hamilton/STAR_chatterbox.py
Comment thread
BioCam marked this conversation as resolved.
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
MachineConfiguration,
STARBackend,
)
from pylabrobot.resources.container import Container
from pylabrobot.resources.well import Well

_DEFAULT_MACHINE_CONFIGURATION = MachineConfiguration(
Expand Down Expand Up @@ -213,6 +214,10 @@ async def channel_request_y_minimum_spacing(self, channel_idx: int) -> float:
)
return self._channels_minimum_y_spacing[channel_idx]

async def channels_request_y_minimum_spacing(self) -> List[float]:
"""Return mock per-channel minimum Y spacings for all channels."""
return list(self._channels_minimum_y_spacing)

async def move_channel_y(self, channel: int, y: float):
print(f"moving channel {channel} to y: {y}")

Expand Down Expand Up @@ -314,22 +319,33 @@ async def request_tip_len_on_channel(self, channel_idx: int) -> float:
async def position_channels_in_y_direction(self, ys, make_space=True):
print("positioning channels in y:", ys, "make_space:", make_space)

async def probe_liquid_heights(
self,
containers,
use_channels=None,
resource_offsets=None,
lld_mode=None,
search_speed=10.0,
n_replicates=1,
min_traverse_height_at_beginning_of_command=None,
min_traverse_height_during_command=None,
z_position_at_end_of_command=None,
move_to_z_safety_after=None,
) -> List[float]:
"""Return liquid heights from the volume tracker using each container's
height-from-volume function. No physical probing in simulation."""
return [c.compute_height_from_volume(c.tracker.get_used_volume()) for c in containers]

async def request_pip_height_last_lld(self):
return list(range(12))

async def _run_lld_on_channel_batch(
self,
batch,
containers: List[Container],
tip_lengths: List[float],
z_cavity_bottom: List[float],
z_top: List[float],
lld_mode: List["STARBackend.LLDMode"],
search_speed: float,
n_replicates: int,
) -> Dict[int, List[Optional[float]]]:
"""Simulate LLD by computing absolute heights from each container's volume tracker.

Empty containers report the cavity-bottom Z (relative height 0). Non-empty
containers report ``cavity_bottom + compute_height_from_volume(volume)`` so the
parent ``probe_liquid_heights`` can subtract ``z_cavity_bottom`` consistently.
"""
measurements: Dict[int, List[Optional[float]]] = {}
for orig_idx in batch.indices:
container = containers[orig_idx]
volume = container.tracker.get_used_volume()
if volume == 0:
absolute_height = z_cavity_bottom[orig_idx]
else:
absolute_height = z_cavity_bottom[orig_idx] + container.compute_height_from_volume(volume)
measurements[orig_idx] = [absolute_height] * n_replicates
return measurements
Loading
Loading