@ProviderType
public class TensorDescriptor
extends java.lang.Object
Tensor used as input or output
of a model for Artificial Intelligence and Machine Learning algorithms| Constructor and Description |
|---|
TensorDescriptor(java.lang.String name,
java.lang.String type,
java.util.Optional<java.lang.String> format,
java.util.List<java.lang.Long> shape,
java.util.Map<java.lang.String,java.lang.Object> parameters)
Instantiates a tensor descriptor
|
| Modifier and Type | Method and Description |
|---|---|
static TensorDescriptorBuilder |
builder(java.lang.String name,
java.lang.String type,
java.util.List<java.lang.Long> shape)
Instantiates a builder for a
TensorDescriptor |
java.util.Optional<java.lang.String> |
getFormat()
Return the format of the data.
|
java.lang.String |
getName()
Return the name of the tensor
|
java.util.Map<java.lang.String,java.lang.Object> |
getParameters()
Return the optional parameters assign to the tensor
|
java.util.List<java.lang.Long> |
getShape()
Return the shape of the data as the size of a multi-dimensional matrix.
|
java.lang.String |
getType()
Return the type of data contained in the tensor.
|
TensorDescriptorBuilder |
toBuilder()
Creates a new
TensorDescriptorBuilder and initialises it from this TensorDescriptor instance. |
public TensorDescriptor(java.lang.String name,
java.lang.String type,
java.util.Optional<java.lang.String> format,
java.util.List<java.lang.Long> shape,
java.util.Map<java.lang.String,java.lang.Object> parameters)
name - the name of the tensortype - a string representing the type of data contained in the tensor.
Its value is implementation specific, so a user should refer to
the implementation documentation to figure out the allowed values.shape - the shape of the datapublic static TensorDescriptorBuilder builder(java.lang.String name, java.lang.String type, java.util.List<java.lang.Long> shape)
TensorDescriptorname - the name of the tensortype - a string representing the type of data contained in the tensor.
Its value is implementation specific, so a user should refer to
the implementation documentation to figure out the allowed values.shape - the shape of the data as the size of a multi-dimensional matrixpublic TensorDescriptorBuilder toBuilder()
TensorDescriptorBuilder and initialises it from this TensorDescriptor instance.TensorDescriptorBuilderpublic java.lang.String getName()
public java.lang.String getType()
public java.util.Optional<java.lang.String> getFormat()
public java.util.List<java.lang.Long> getShape()
public java.util.Map<java.lang.String,java.lang.Object> getParameters()