concepts.dsl.tensor_value.MaskedTensorStorage#

class MaskedTensorStorage[source]#

Bases: object

A storage for quantized tensors.

Methods

Attributes

mask

The mask of the value.

optimistic_values

The optimistic values for the tensor.

quantized_values

The quantized values for the tensor.

value

The unquantized tensor.

__init__(value, mask=None, optimistic_values=None, quantized_values=None)#
Parameters:
Return type:

None

__new__(**kwargs)#
mask: Tensor | None = None#

The mask of the value. If not None, entry = 1 if the value is valid, and 0 otherwise.

optimistic_values: Tensor | None = None#

The optimistic values for the tensor. 0 for non-optimistic values.

quantized_values: Tensor | None = None#

The quantized values for the tensor. -1 for non-quantized values.

value: Tensor | TensorizedPyObjValues#

The unquantized tensor.