citrine.informatics.dimensions module

Tools for working with Dimensions.

class citrine.informatics.dimensions.ContinuousDimension(descriptor: RealDescriptor, *, lower_bound: float | None = None, upper_bound: float | None = None)

Bases: Serializable[ContinuousDimension], Dimension

A continuous, real-valued dimension.

Parameters:
  • descriptor (RealDescriptor) – a descriptor of the single dimension

  • lower_bound (float) – inclusive lower bound

  • upper_bound (float) – inclusive upper bound

classmethod build(data: dict) Self

Build an instance of this object from given data.

dump() dict

Dump this instance.

classmethod get_type(data) Type[Serializable]

Return the subtype.

descriptor: RealDescriptor = None
lower_bound = None
typ = 'ContinuousDimension'
upper_bound = None
class citrine.informatics.dimensions.Dimension

Bases: PolymorphicSerializable[Dimension]

A Dimension describes the values that a quantity can take in the context of a design space.

Abstract type that returns the proper type given a serialized dict.

classmethod build(data: dict) SelfType

Build the underlying type.

classmethod get_type(data) Type[Serializable]

Return the subtype.

class citrine.informatics.dimensions.EnumeratedDimension(descriptor: Descriptor, *, values: List[str])

Bases: Serializable[EnumeratedDimension], Dimension

A finite, enumerated dimension.

Parameters:
  • descriptor (Descriptor) – a descriptor of the single dimension

  • values (list[str]) – list of values that can be parsed by the descriptor

classmethod build(data: dict) Self

Build an instance of this object from given data.

dump() dict

Dump this instance.

classmethod get_type(data) Type[Serializable]

Return the subtype.

descriptor: Descriptor = None
typ = 'EnumeratedDimension'
values: List[str] = None
class citrine.informatics.dimensions.IntegerDimension(descriptor: IntegerDescriptor, *, lower_bound: int | None = None, upper_bound: int | None = None)

Bases: Serializable[IntegerDimension], Dimension

An integer-valued dimension with inclusive lower and upper bounds.

Parameters:
  • descriptor (IntegerDescriptor) – a descriptor of the single dimension

  • lower_bound (int) – inclusive lower bound

  • upper_bound (int) – inclusive upper bound

classmethod build(data: dict) Self

Build an instance of this object from given data.

dump() dict

Dump this instance.

classmethod get_type(data) Type[Serializable]

Return the subtype.

descriptor: IntegerDescriptor = None
lower_bound = None
typ = 'IntegerDimension'
upper_bound = None