pacman.model.constraints.placer_constraints package¶
Submodules¶
pacman.model.constraints.placer_constraints.abstract_placer_constraint module¶
-
class
pacman.model.constraints.placer_constraints.abstract_placer_constraint.
AbstractPlacerConstraint
[source]¶ Bases:
pacman.model.constraints.abstract_constraint.AbstractConstraint
A constraint on placement
pacman.model.constraints.placer_constraints.board_constraint module¶
-
class
pacman.model.constraints.placer_constraints.board_constraint.
BoardConstraint
(board_address)[source]¶ Bases:
pacman.model.constraints.placer_constraints.abstract_placer_constraint.AbstractPlacerConstraint
A constraint on the board on which a placement is made
Parameters: board_address – The IP address of the Ethernet of the board to be used -
board_address
¶ The board of the constraint
-
pacman.model.constraints.placer_constraints.chip_and_core_constraint module¶
-
class
pacman.model.constraints.placer_constraints.chip_and_core_constraint.
ChipAndCoreConstraint
(x, y, p=None)[source]¶ Bases:
pacman.model.constraints.placer_constraints.abstract_placer_constraint.AbstractPlacerConstraint
A constraint to place a vertex on a specific chip and, optionally, a specific core on that chip
Parameters: - x (int) – the x-coordinate of the chip
- y (int) – the y-coordinate of the chip
- p (int) – the processor (if any) of the chip
Raises: None – does not raise any known exceptions
-
location
¶ The location as a dictionary with three keys: “x”, “y” and “p”
Returns: a dictionary containing the location Return type: dict of {“x”: int, “y”: int, “p”: int} Raises: None – does not raise any known exceptions
-
p
¶ The processor on the chip
Returns: the processor id or None Return type: int Raises: None – does not raise any known exceptions
-
x
¶ The x-coordinate of the chip
Returns: the x-coordinate Return type: int Raises: None – does not raise any known exceptions
-
y
¶ The y-coordinate of the chip
Returns: the y-coordinate Return type: int Raises: None – does not raise any known exceptions
pacman.model.constraints.placer_constraints.radial_placement_from_chip_constraint module¶
-
class
pacman.model.constraints.placer_constraints.radial_placement_from_chip_constraint.
RadialPlacementFromChipConstraint
(x, y)[source]¶ Bases:
pacman.model.constraints.placer_constraints.abstract_placer_constraint.AbstractPlacerConstraint
A constraint that attempts to place a vertex as close to a chip as possible (including on it)
Parameters: - x (int) – the x-coordinate of the chip
- y (int) – the y-coordinate of the chip
Raises: None – does not raise any known exceptions
-
x
¶
-
y
¶
pacman.model.constraints.placer_constraints.same_chip_as_constraint module¶
-
class
pacman.model.constraints.placer_constraints.same_chip_as_constraint.
SameChipAsConstraint
(vertex)[source]¶ Bases:
pacman.model.constraints.placer_constraints.abstract_placer_constraint.AbstractPlacerConstraint
Indicates that a vertex should be placed on the same chip as another vertex
Parameters: vertex – The vertex to place on the same chip -
vertex
¶ The vertex to place on the same chip
-
Module contents¶
-
class
pacman.model.constraints.placer_constraints.
AbstractPlacerConstraint
[source]¶ Bases:
pacman.model.constraints.abstract_constraint.AbstractConstraint
A constraint on placement
-
class
pacman.model.constraints.placer_constraints.
BoardConstraint
(board_address)[source]¶ Bases:
pacman.model.constraints.placer_constraints.abstract_placer_constraint.AbstractPlacerConstraint
A constraint on the board on which a placement is made
Parameters: board_address – The IP address of the Ethernet of the board to be used -
board_address
¶ The board of the constraint
-
-
class
pacman.model.constraints.placer_constraints.
ChipAndCoreConstraint
(x, y, p=None)[source]¶ Bases:
pacman.model.constraints.placer_constraints.abstract_placer_constraint.AbstractPlacerConstraint
A constraint to place a vertex on a specific chip and, optionally, a specific core on that chip
Parameters: - x (int) – the x-coordinate of the chip
- y (int) – the y-coordinate of the chip
- p (int) – the processor (if any) of the chip
Raises: None – does not raise any known exceptions
-
location
¶ The location as a dictionary with three keys: “x”, “y” and “p”
Returns: a dictionary containing the location Return type: dict of {“x”: int, “y”: int, “p”: int} Raises: None – does not raise any known exceptions
-
p
¶ The processor on the chip
Returns: the processor id or None Return type: int Raises: None – does not raise any known exceptions
-
x
¶ The x-coordinate of the chip
Returns: the x-coordinate Return type: int Raises: None – does not raise any known exceptions
-
y
¶ The y-coordinate of the chip
Returns: the y-coordinate Return type: int Raises: None – does not raise any known exceptions
-
class
pacman.model.constraints.placer_constraints.
RadialPlacementFromChipConstraint
(x, y)[source]¶ Bases:
pacman.model.constraints.placer_constraints.abstract_placer_constraint.AbstractPlacerConstraint
A constraint that attempts to place a vertex as close to a chip as possible (including on it)
Parameters: - x (int) – the x-coordinate of the chip
- y (int) – the y-coordinate of the chip
Raises: None – does not raise any known exceptions
-
x
¶
-
y
¶
-
class
pacman.model.constraints.placer_constraints.
SameChipAsConstraint
(vertex)[source]¶ Bases:
pacman.model.constraints.placer_constraints.abstract_placer_constraint.AbstractPlacerConstraint
Indicates that a vertex should be placed on the same chip as another vertex
Parameters: vertex – The vertex to place on the same chip -
vertex
¶ The vertex to place on the same chip
-