pacman.model.tags package

Submodules

pacman.model.tags.tags module

class pacman.model.tags.tags.Tags[source]

Bases: object

Represents assigned IP Tag and Reverse IP Tags

add_ip_tag(ip_tag, vertex)[source]

Add an IP tag

Parameters:
  • ip_tag (spinn_machine.tags.IPTag) – The tag to add
  • vertex (pacman.model.graph.machine.MachineVertex) – The machine vertex by which the tag is to be used
Raises:

PacmanInvalidParameterException

  • If the combination of (board-address, tag) has already been assigned to an IP tag with different properties
  • If the combination of (board-address, tag) has already been assigned to a reverse IP tag

add_reverse_ip_tag(reverse_ip_tag, vertex)[source]

Add a reverse iptag

Parameters:
  • reverse_ip_tag (spinn_machine.tags.ReverseIPTag) – The tag to add
  • vertex (pacman.model.graph.machine.MachineVertex) – The vertex by which the tag is to be used
Raises:

PacmanInvalidParameterException

  • If the combination of (board-address, tag) has already been assigned to an IP tag or Reverse IP tag
  • If the port of the tag has already been assigned on the given board-address

get_ip_tags_for_vertex(vertex)[source]

Get the IP Tags assigned to a given machine vertex

Parameters:vertex (pacman.model.graph.machine.MachineVertex) – The vertex to get the tags for
Returns:An iterable of IPTag or None if the vertex has no tags
Return type:iterable of spinn_machine.tags.IPTag or None
get_reverse_ip_tags_for_vertex(vertex)[source]

Get the Reverse IP Tags assigned to a given machine vertex

Parameters:vertex (pacman.model.graph.AbstractVertex) – The vertex to get the tags for
Returns:An iterable of ReverseIPTag or None if the vertex has no tags
Return type:iterable of spinn_machine.tags.ReverseIPTag or None
ip_tags

The IPTags assigned

Returns:iterable of IPTag
Return type:iterable of spinn_machine.tags.IPTag
reverse_ip_tags

The ReverseIPTags assigned

Returns:iterable of ReverseIPTag
Return type:iterable of spinn_machine.tags.ReverseIPTag

Module contents

class pacman.model.tags.Tags[source]

Bases: object

Represents assigned IP Tag and Reverse IP Tags

add_ip_tag(ip_tag, vertex)[source]

Add an IP tag

Parameters:
  • ip_tag (spinn_machine.tags.IPTag) – The tag to add
  • vertex (pacman.model.graph.machine.MachineVertex) – The machine vertex by which the tag is to be used
Raises:

PacmanInvalidParameterException

  • If the combination of (board-address, tag) has already been assigned to an IP tag with different properties
  • If the combination of (board-address, tag) has already been assigned to a reverse IP tag

add_reverse_ip_tag(reverse_ip_tag, vertex)[source]

Add a reverse iptag

Parameters:
  • reverse_ip_tag (spinn_machine.tags.ReverseIPTag) – The tag to add
  • vertex (pacman.model.graph.machine.MachineVertex) – The vertex by which the tag is to be used
Raises:

PacmanInvalidParameterException

  • If the combination of (board-address, tag) has already been assigned to an IP tag or Reverse IP tag
  • If the port of the tag has already been assigned on the given board-address

get_ip_tags_for_vertex(vertex)[source]

Get the IP Tags assigned to a given machine vertex

Parameters:vertex (pacman.model.graph.machine.MachineVertex) – The vertex to get the tags for
Returns:An iterable of IPTag or None if the vertex has no tags
Return type:iterable of spinn_machine.tags.IPTag or None
get_reverse_ip_tags_for_vertex(vertex)[source]

Get the Reverse IP Tags assigned to a given machine vertex

Parameters:vertex (pacman.model.graph.AbstractVertex) – The vertex to get the tags for
Returns:An iterable of ReverseIPTag or None if the vertex has no tags
Return type:iterable of spinn_machine.tags.ReverseIPTag or None
ip_tags

The IPTags assigned

Returns:iterable of IPTag
Return type:iterable of spinn_machine.tags.IPTag
reverse_ip_tags

The ReverseIPTags assigned

Returns:iterable of ReverseIPTag
Return type:iterable of spinn_machine.tags.ReverseIPTag