Tensor_int32 Class — pytorch Architecture
Architecture documentation for the Tensor_int32 class in Tensor.java from the pytorch codebase.
Entity Profile
Relationship Graph
Source Code
android/pytorch_android/src/main/java/org/pytorch/Tensor.java lines 551–581
static class Tensor_int32 extends Tensor {
private final IntBuffer data;
private Tensor_int32(IntBuffer data, long[] shape, MemoryFormat memoryFormat) {
super(shape, memoryFormat);
this.data = data;
}
@Override
public DType dtype() {
return DType.INT32;
}
@Override
Buffer getRawDataBuffer() {
return data;
}
@Override
public int[] getDataAsIntArray() {
data.rewind();
int[] arr = new int[data.remaining()];
data.get(arr);
return arr;
}
@Override
public String toString() {
return String.format("Tensor(%s, dtype=torch.int32)", Arrays.toString(shape));
}
}
Domain
Source
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free