concepts.benchmark.namo.namo_polygon.namo_polygon_primitives.BoundingBox#

class BoundingBox[source]#

Bases: NamedTuple

BoundingBox(x0, y0, x1, y1)

Methods

count(value, /)

Return number of occurrences of value.

index(value[, start, stop])

Return first index of value.

inside(x, y)

point_inside(point)

Attributes

x0

Alias for field number 0

x1

Alias for field number 2

y0

Alias for field number 1

y1

Alias for field number 3

__add__(value, /)#

Return self+value.

__getitem__(key, /)#

Return self[key].

__init__()#
__iter__()#

Implement iter(self).

__len__()#

Return len(self).

__mul__(value, /)#

Return self*value.

static __new__(_cls, x0, y0, x1, y1)#

Create new instance of BoundingBox(x0, y0, x1, y1)

Parameters:
count(value, /)#

Return number of occurrences of value.

index(value, start=0, stop=9223372036854775807, /)#

Return first index of value.

Raises ValueError if the value is not present.

inside(x, y)[source]#
Parameters:
Return type:

bool

point_inside(point)[source]#
Parameters:

point (Tuple[int, int])

Return type:

bool

x0: int#

Alias for field number 0

x1: int#

Alias for field number 2

y0: int#

Alias for field number 1

y1: int#

Alias for field number 3