Skip to content

Commit 833d388

Browse files
authored
Update Tensor.java
1 parent 7e2106c commit 833d388

File tree

1 file changed

+1
-1
lines changed
  • extension/android/executorch_android/src/main/java/org/pytorch/executorch

1 file changed

+1
-1
lines changed

extension/android/executorch_android/src/main/java/org/pytorch/executorch/Tensor.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -714,7 +714,7 @@ private static Tensor nativeNewTensor(
714714
tensor = new Tensor_int8(data, shape);
715715
} else if (DType.HALF.jniCode == dtype) {
716716
tensor = new Tensor_raw_data_16b(data, shape, DType.HALF);
717-
} else if (DType.HALF.jniCode == dtype) {
717+
} else if (DType.BFLOAT16.jniCode == dtype) {
718718
tensor = new Tensor_raw_data_16b(data, shape, DType.BFLOAT16);
719719
} else {
720720
throw new IllegalArgumentException("Unknown Tensor dtype");

0 commit comments

Comments
 (0)