Class TensorInfo
java.lang.Object
com.codename1.ai.inference.TensorInfo
Immutable metadata for one model input or output. Shapes may contain a
negative dynamic dimension until the input has been resized and tensors
reallocated.
-
Constructor Summary
ConstructorsConstructorDescriptionTensorInfo(String name, TensorType type, int[] shape, int index) Creates tensor metadata. -
Method Summary
-
Constructor Details
-
TensorInfo
Creates tensor metadata.- Parameters:
name- runtime tensor name, possibly emptytype- element typeshape- current tensor dimensionsindex- native model index
-
-
Method Details
-
getName
- Returns:
- the runtime tensor name
-
getType
- Returns:
- the tensor element type
-
getShape
public int[] getShape()- Returns:
- a defensive copy of current dimensions
-
getIndex
public int getIndex()- Returns:
- the zero-based model input or output index
-