pylabrobot.lib.liquid_handling.tip_spot_finding.find_tip_spots#
- pylabrobot.lib.liquid_handling.tip_spot_finding.find_tip_spots(root: Resource, has_tip: bool | None = None, volume: float | None = None, has_filter: bool | None = None, count: int | None = None, x_aligned: bool = False, available_for_tip_handling: bool | None = None) List[TipSpot]#
Find tip spots in consumption order.
Searches every tip rack in the tree under root, root included: a deck, a carrier, a bench resource holding several racks, a whole facility, or a single rack. Racks with an empty spot come first; among them, and then among full racks, the one with the fewest tips left, then the left-most, then the rear-most. Within a rack, spots run left to right, each column back to front, so a rack is opened at its left-most column. This suits channels on one X arm that cannot pass each other.
- Parameters:
root (Resource) – Resource whose tree is searched for tip racks. Positions are compared in root’s own frame, so a deck gives the channels’ order however the device sits above it.
has_tip (bool | None) – True for spots holding a tip, False for empty spots, None for both.
volume (float | None) – Tip nominal volume in uL. Read from the present tip, or from the configured tip when has_tip is False; with has_tip None, only spots holding a tip match.
has_filter (bool | None) – Tip filter state, matched like volume.
count (int | None) – Return exactly this many spots, sorted back to front, or an empty list if fewer match. None returns every match.
x_aligned (bool) – Return spots from a single rack column: the first column in consumption order holding at least count spots. A shorter column is skipped. Falls back to the unaligned batch when no column can serve count. Without count, returns the first column.
available_for_tip_handling (bool | None) – True for spots in racks a head can reach, False for spots in racks it cannot, e.g. under a lid or under another rack in a stack, None for both. See
TipRack.available_for_tip_handling.
- Returns:
Matching tip spots.
- Raises:
ValueError – If count is not positive.
NoLocationError – If a resource between root and a rack has no location.
- Return type: