Enum Class MachineVersion
- All Implemented Interfaces:
Serializable
,Comparable<MachineVersion>
,Constable
Known types of machine. Properly this should be an open set.
- Author:
- Christian-B
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionUnexpected small board probably created by adding a virtual chip to a 2 by 2 board.Single common style 48 chip board.Original style 48 chip board.Unexpected combination of common style 48 chips boards not in made up of standard Triads.Assumed Combination of 1200 common style 48 chips boards.Combination of 120 common style 48 chips boards.Combination of 600 common style 48 chips boards.Common style 4 chip board.Combination of 3 common style 48 chips boards in a Toroid.Combination of multiple common style 48 chips boards but made up of Triads without wrap-arounds.Combination of multiple common style 48 chips boards but made up of Triads which only wrap-arounds on the Horizontal / X axis.Combination of multiple common style 48 chips boards but made up of Triads which only wrap-arounds on the Vertical / Y axis.Unknown combination of common style 48 chips boards but made up of Triads with both wrap-arounds.Combination of 24 common style 48 chips boards.Original style 4 chip board. -
Field Summary
FieldsModifier and TypeFieldDescriptionfinal boolean
Indicates if this machine is expected to have wrap-arounds on the X axis.final Integer
Python ID for this version ornull
if no matching ID in python.final boolean
Indicates if this machine has exactly 4 chips is a 2 by 2 layout.final boolean
Indicates if this machine has exactly one 48 chip board.final boolean
Indicates if this board is made up of triads, i.e., one or more groups of three boards in the typical layout.final MachineDimensions
The only possible dimensions for this version ornull
if multiple sizes allowed.final boolean
Indicates if this machine is expected to have wrap-arounds on the Y axis. -
Method Summary
Modifier and TypeMethodDescriptionstatic MachineVersion
Converts a python board ID into a MachineVersion.static MachineVersion
bySize
(int width, int height) Calculate the machine version based on the size.static MachineVersion
bySize
(MachineDimensions dimensions) Calculate the machine version based on the size.int
Get the version number of the SpiNN boards in the hardware configuration.static MachineVersion
Returns the enum constant of this class with the specified name.static MachineVersion[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
TWO
Original style 4 chip board. -
THREE
Common style 4 chip board. -
FOUR
Original style 48 chip board. -
FIVE
Single common style 48 chip board. -
THREE_BOARD
Combination of 3 common style 48 chips boards in a Toroid. -
TWENTYFOUR_BOARD
Combination of 24 common style 48 chips boards. -
ONE_TWENTY_BOARD
Combination of 120 common style 48 chips boards. -
SIX_HUNDRED_BOARD
Combination of 600 common style 48 chips boards. -
ONE_THOUSAND_TWO_HUNDRED_BOARD
Assumed Combination of 1200 common style 48 chips boards. -
TRIAD_NO_WRAPAROUND
Combination of multiple common style 48 chips boards but made up of Triads without wrap-arounds.This is typically what spalloc provides when returning part of a larger machine.
-
TRIAD_WITH_WRAPAROUND
Unknown combination of common style 48 chips boards but made up of Triads with both wrap-arounds.All known machine sizes with both wrap-arounds have unique
MachineVersion
s.Note: While this is physically possible with standards boards there is no known case then such a machine would be obtained. The assumption that this version has wrap-arounds is purely based on the size.
-
TRIAD_WITH_HORIZONTAL_WRAP
Combination of multiple common style 48 chips boards but made up of Triads which only wrap-arounds on the Horizontal / X axis.This is possible when spalloc returns a large part of a machine.
-
TRIAD_WITH_VERTICAL_WRAP
Combination of multiple common style 48 chips boards but made up of Triads which only wrap-arounds on the Vertical / Y axis.This is possible when spalloc returns a large part of a machine.
-
NONE_TRIAD_LARGE
Unexpected combination of common style 48 chips boards not in made up of standard Triads.Note: While this is physically possible with standards boards there is no known case then such a machine would be obtained. The assumption that this version does not have wrap-arounds is purely based on the size.
-
EXTENDED_SMALL
Unexpected small board probably created by adding a virtual chip to a 2 by 2 board.
-
-
Field Details
-
id
Python ID for this version ornull
if no matching ID in python. -
isFourChip
public final boolean isFourChipIndicates if this machine has exactly 4 chips is a 2 by 2 layout. -
isFourtyeightChip
public final boolean isFourtyeightChipIndicates if this machine has exactly one 48 chip board. -
horizontalWrap
public final boolean horizontalWrapIndicates if this machine is expected to have wrap-arounds on the X axis. -
verticalWrap
public final boolean verticalWrapIndicates if this machine is expected to have wrap-arounds on the Y axis. -
isTriad
public final boolean isTriadIndicates if this board is made up of triads, i.e., one or more groups of three boards in the typical layout. -
machineDimensions
The only possible dimensions for this version ornull
if multiple sizes allowed.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
byId
Converts a python board ID into a MachineVersion.- Parameters:
id
- Python board version.- Returns:
- Machine version assuming just a single board.
- Throws:
IllegalArgumentException
- If the ID doesn't correspond to a supported version.
-
bySize
Calculate the machine version based on the size.- Parameters:
width
- The width of the machine to find the version for.height
- The height of the machine to find the version for.- Returns:
- A Board version.
- Throws:
IllegalArgumentException
- if the size is not valid.
-
bySize
Calculate the machine version based on the size.- Parameters:
dimensions
- The width and height of the machine to find the version for.- Returns:
- A Board version.
- Throws:
IllegalArgumentException
- if the size is not valid.
-
hardwareVersion
public int hardwareVersion()Get the version number of the SpiNN boards in the hardware configuration.- Returns:
- 2, 3, 4 or 5.
-