def _populate_iso(self, iso, layout): StockSampleCreationIsoPopulator._populate_iso(self, iso, layout) # Create sector preparation plates. library_name = self.iso_request.label ir_specs_96 = get_reservoir_specs_standard_96() plate_specs_96 = get_rack_specs_from_reservoir_specs(ir_specs_96) ir_specs_384 = get_reservoir_specs_standard_384() plate_specs_384 = get_rack_specs_from_reservoir_specs(ir_specs_384) future_status = get_item_status_future() sec_layout_map = get_sector_layouts_for_384_layout(layout) # Create preparation plates. for sec_idx in range(NUMBER_SECTORS): if not sec_idx in sec_layout_map: continue # TODO: Move label creation to LABELS class. prep_label = self.PREP_PLATE_LABEL_PATTERN \ % (library_name, iso.layout_number, DEFAULT_PREPARATION_PLATE_CONCENTRATION, sec_idx + 1) prep_plate = plate_specs_96.create_rack(prep_label, future_status) sec_layout = sec_layout_map[sec_idx] iso.add_sector_preparation_plate(prep_plate, sec_idx, sec_layout.create_rack_layout()) # Create aliquot plates. for i in range(self.iso_request.number_aliquots): # TODO: Move label creation to LABELS class. aliquot_label = self.ALIQUOT_PLATE_LABEL_PATTERN \ % (library_name, iso.layout_number, DEFAULT_ALIQUOT_PLATE_CONCENTRATION, i + 1) aliquot_plate = plate_specs_384.create_rack(aliquot_label, future_status) iso.add_aliquot_plate(aliquot_plate)
def __sort_into_sectors(self): # Create a rack layout for each quadrant. self.add_debug("Sorting positions into sectors.") self.__sector_layouts = get_sector_layouts_for_384_layout(self.base_layout, LibraryBaseLayout) if len(self.__sector_layouts) < NUMBER_SECTORS: missing_sector_labels = [str(si + 1) for si in range(NUMBER_SECTORS) if not si in self.__sector_layouts] msg = "Some rack sectors are empty. You do not require stock " "racks for them: %s!" % ", ".join( missing_sector_labels ) self.add_warning(msg)
def __sort_into_sectors(self): # Create a rack layout for each quadrant. self.add_debug('Sorting positions into sectors.') self.__sector_layouts = \ get_sector_layouts_for_384_layout(self.base_layout, LibraryBaseLayout) if len(self.__sector_layouts) < NUMBER_SECTORS: missing_sector_labels = [str(si + 1) for si in range(NUMBER_SECTORS) if not si in self.__sector_layouts] msg = 'Some rack sectors are empty. You do not require stock ' \ 'racks for them: %s!' % ', '.join(missing_sector_labels) self.add_warning(msg)