def _add_virtual_chips(self): # allocate chip ids to the virutal chips chip_id_allocator = MallocBasedChipIdAllocator() chip_id_allocator.allocate_chip_ids(self._partitionable_graph, self._machine) # add virtual chips to the machine object for vertex in self._partitionable_graph.vertices: if isinstance(vertex, AbstractVirtualVertex): # check if the virtual chip doesn't already exist if self._machine.get_chip_at(vertex.virtual_chip_x, vertex.virtual_chip_y) is None: virutal_chip = self._create_virtual_chip(vertex) self._machine.add_chip(virutal_chip)
def _add_virtual_chips(self): # allocate chip ids to the virutal chips chip_id_allocator = MallocBasedChipIdAllocator() chip_id_allocator.allocate_chip_ids(self._partitionable_graph, self._machine)