mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-05-23 22:13:38 +00:00
remove duplicate function definition (#21903)
This commit is contained in:
parent
7df8776322
commit
4fece0430f
1 changed files with 0 additions and 8 deletions
|
|
@ -23,14 +23,6 @@ class TensorViewImpl implements TensorView {
|
|||
public readonly dims: readonly number[],
|
||||
) {}
|
||||
|
||||
getUint16Array(): Uint16Array {
|
||||
if (this.dataType !== DataType.float16 && this.dataType !== DataType.uint16) {
|
||||
throw new Error('Invalid data type');
|
||||
}
|
||||
const elementCount = ShapeUtil.size(this.dims);
|
||||
return elementCount === 0 ? new Uint16Array() : new Uint16Array(this.module.HEAP8.buffer, this.data, elementCount);
|
||||
}
|
||||
|
||||
getFloat32Array(): Float32Array {
|
||||
if (this.dataType !== DataType.float) {
|
||||
throw new Error('Invalid data type');
|
||||
|
|
|
|||
Loading…
Reference in a new issue