Float32NumericTensor.eye constructor

Float32NumericTensor.eye(
  1. int numRows,
  2. int numCols,
  3. List<int> batchShape, {
  4. double value = 1.0,
})

Implementation

Float32NumericTensor.eye(int numRows, int numCols, List<int> batchShape, {double value = 1.0}) {
  List<int> shape = batchShape + [numRows, numCols];
  this.shape = TensorShape(shape);
  buffer = eyeBuffer(numRows, numCols, batchShape, dType) as Float32List;
}