@TensorType(dataType=DT_INT64, byteSize=8, mapperClass=TInt64Mapper.class) public interface TInt64 extends org.tensorflow.ndarray.LongNdArray, TIntegral
Modifier and Type | Method and Description |
---|---|
static TInt64 |
scalarOf(long value)
Allocates a new tensor for storing a single long value.
|
static TInt64 |
tensorOf(org.tensorflow.ndarray.NdArray<Long> src)
Allocates a new tensor which is a copy of a given array of longs.
|
static TInt64 |
tensorOf(org.tensorflow.ndarray.Shape shape)
Allocates a new tensor of the given shape.
|
static TInt64 |
tensorOf(org.tensorflow.ndarray.Shape shape,
Consumer<TInt64> dataInit)
Allocates a new tensor of the given shape and initialize its data.
|
static TInt64 |
tensorOf(org.tensorflow.ndarray.Shape shape,
org.tensorflow.ndarray.buffer.LongDataBuffer data)
Allocates a new tensor of the given shape, initialized with the provided data.
|
static TInt64 |
vectorOf(long... values)
Allocates a new tensor for storing a vector of longs.
|
static TInt64 scalarOf(long value)
value
- long to store in the new tensorstatic TInt64 vectorOf(long... values)
values
- longs to store in the new tensorstatic TInt64 tensorOf(org.tensorflow.ndarray.NdArray<Long> src)
The tensor will have the same shape as the source array and its data will be copied.
src
- the source array giving the shape and data to the new tensorstatic TInt64 tensorOf(org.tensorflow.ndarray.Shape shape)
shape
- shape of the tensor to allocatestatic TInt64 tensorOf(org.tensorflow.ndarray.Shape shape, org.tensorflow.ndarray.buffer.LongDataBuffer data)
shape
- shape of the tensor to allocatedata
- buffer of longs to initialize the tensor withstatic TInt64 tensorOf(org.tensorflow.ndarray.Shape shape, Consumer<TInt64> dataInit)
shape
- shape of the tensor to allocatedataInit
- tensor data initializerTensorFlowException
- if the tensor cannot be allocated or initializedCopyright © 2015–2022. All rights reserved.