pygrenade_vx.common.CuboidMultiIndexSequence

class pygrenade_vx.common.CuboidMultiIndexSequence

Bases: pygrenade_common.MultiIndexSequence

__init__(*args, **kwargs)

Overloaded function.

  1. __init__(self: pygrenade_common.CuboidMultiIndexSequence) -> None

  2. __init__(self: pygrenade_common.CuboidMultiIndexSequence, shape: list[int], origin: pygrenade_common.MultiIndex) -> None

Construct sequence.

  1. __init__(self: pygrenade_common.CuboidMultiIndexSequence, shape: list[int], origin: pygrenade_common.MultiIndex, dimension_units: list[Optional[pygrenade_common.MultiIndexSequence.DimensionUnit]]) -> None

Construct sequence. Constructor present for Python wrapping to work.

  1. __init__(self: pygrenade_common.CuboidMultiIndexSequence, shape: list[int]) -> None

Construct sequence with zero origin.

  1. __init__(self: pygrenade_common.CuboidMultiIndexSequence, shape: list[int], dimension_units: list[Optional[pygrenade_common.MultiIndexSequence.DimensionUnit]]) -> None

Construct sequence with zero origin. Constructor present for Python wrapping to work.

  1. __init__(self: pygrenade_common.CuboidMultiIndexSequence, arg0: pygrenade_common.CuboidMultiIndexSequence) -> None

Methods

__init__(*args, **kwargs)

Overloaded function.

cartesian_product(self, other)

Construct sequence which is the cartesian product of this sequence and the other sequence.

copy(self)

dimensionality(self)

Get dimensionality of multi-indices in sequence.

distinct_projection(self, dimensions)

Get distinct projection of sequence onto given dimensions.

get_dimension_units(self)

Get dimension units.

get_elements(self)

Get elements in sequence.

get_origin(self)

Get origin of cuboid in the index space.

get_shape(self)

Get shape of cuboid in the index space.

includes(self, other)

Get whether all elements of sequence are present in other sequence.

is_injective(self)

Get whether sequence of elements is injective.

move(self)

projection(self, dimensions)

Get projection of sequence onto given dimensions.

related_sequence_subset_restriction(self, …)

Get restriction of sequence defined by subset restriction of related sequence.

set_dimension_units(self, value)

Set dimension units.

set_origin(self, value)

Set origin of cuboid in the index space.

set_shape(self, value)

Set shape of cuboid in the index space.

size(self)

Get number of elements in sequence.

slice(self, indices)

Slice sequence linearly at given indices.

subset_restriction(self, other)

Get restriction of sequence onto subset of elements present in other sequence.

cartesian_product(self: pygrenade_common.CuboidMultiIndexSequence, other: pygrenade_common.MultiIndexSequence)pygrenade_common.MultiIndexSequence

Construct sequence which is the cartesian product of this sequence and the other sequence.

copy(self: pygrenade_common.CuboidMultiIndexSequence)pygrenade_common.MultiIndexSequence
dimensionality(self: pygrenade_common.CuboidMultiIndexSequence)int

Get dimensionality of multi-indices in sequence.

distinct_projection(self: pygrenade_common.CuboidMultiIndexSequence, dimensions: set[int])pygrenade_common.MultiIndexSequence

Get distinct projection of sequence onto given dimensions.

get_dimension_units(self: pygrenade_common.CuboidMultiIndexSequence)list[dapr::PropertyHolder<grenade::common::MultiIndexSequence::DimensionUnit, std::unique_ptr>]

Get dimension units.

get_elements(self: pygrenade_common.CuboidMultiIndexSequence)list[pygrenade_common.MultiIndex]

Get elements in sequence.

get_origin(self: pygrenade_common.CuboidMultiIndexSequence)pygrenade_common.MultiIndex

Get origin of cuboid in the index space.

get_shape(self: pygrenade_common.CuboidMultiIndexSequence)list[int]

Get shape of cuboid in the index space.

includes(self: pygrenade_common.CuboidMultiIndexSequence, other: pygrenade_common.MultiIndexSequence)bool

Get whether all elements of sequence are present in other sequence. The dimension units are required to match in addition to geometric inclusion.

is_injective(self: pygrenade_common.CuboidMultiIndexSequence)bool

Get whether sequence of elements is injective. This is the case if all elements are distinct. Cuboid sequences are always injective.

move(self: pygrenade_common.CuboidMultiIndexSequence)pygrenade_common.MultiIndexSequence
projection(self: pygrenade_common.CuboidMultiIndexSequence, dimensions: set[int])pygrenade_common.MultiIndexSequence

Get projection of sequence onto given dimensions.

related_sequence_subset_restriction(self: pygrenade_common.CuboidMultiIndexSequence, related: pygrenade_common.MultiIndexSequence, subset: pygrenade_common.MultiIndexSequence)pygrenade_common.MultiIndexSequence

Get restriction of sequence defined by subset restriction of related sequence. Elements are part of the restricted sequence, if the element at the same index in the related sequence is part of the subset.

set_dimension_units(self: pygrenade_common.CuboidMultiIndexSequence, value: list[dapr::PropertyHolder<grenade::common::MultiIndexSequence::DimensionUnit, std::unique_ptr>])None

Set dimension units.

set_origin(self: pygrenade_common.CuboidMultiIndexSequence, value: pygrenade_common.MultiIndex)None

Set origin of cuboid in the index space.

set_shape(self: pygrenade_common.CuboidMultiIndexSequence, value: list[int])None

Set shape of cuboid in the index space.

size(self: pygrenade_common.CuboidMultiIndexSequence)int

Get number of elements in sequence.

slice(self: pygrenade_common.CuboidMultiIndexSequence, indices: set[int])list[pygrenade_common.MultiIndexSequence]

Slice sequence linearly at given indices. The splits then contain sequences of the elements at the positions in the open intervals [0, indices[0]), [indices[i], indices[i+1]), …, [indices[N-1], size).

subset_restriction(self: pygrenade_common.CuboidMultiIndexSequence, other: pygrenade_common.MultiIndexSequence)pygrenade_common.MultiIndexSequence

Get restriction of sequence onto subset of elements present in other sequence.