File tree Expand file tree Collapse file tree 1 file changed +3
-10
lines changed Expand file tree Collapse file tree 1 file changed +3
-10
lines changed Original file line number Diff line number Diff line change @@ -235,12 +235,6 @@ impl JsTensor {
235235 TensorElementType :: Int64 => self . extract_ort_tensor_ref :: < i64 > ( ) ?. into ( ) ,
236236 TensorElementType :: Uint64 => self . extract_ort_tensor_ref :: < u64 > ( ) ?. into ( ) ,
237237 TensorElementType :: Bool => self . extract_ort_tensor_ref :: < bool > ( ) ?. into ( ) ,
238- TensorElementType :: Float16 => {
239- return Err ( anyhow ! ( "'half::f16' is not supported by JS tensor." ) )
240- }
241- TensorElementType :: Bfloat16 => {
242- return Err ( anyhow ! ( "'half::bf16' is not supported by JS tensor." ) )
243- }
244238 other => {
245239 return Err ( anyhow ! ( "'{other:?}' is not supported by JS tensor." ) )
246240 }
@@ -279,10 +273,9 @@ impl ToJsTensor {
279273 TensorElementType :: Int64 => v8_slice_from ! ( tensor:: <i64 >( value) ) ,
280274 TensorElementType :: Uint64 => v8_slice_from ! ( tensor:: <u64 >( value) ) ,
281275 TensorElementType :: Bool => v8_slice_from ! ( tensor:: <bool >( value) ) ,
282- TensorElementType :: String => todo ! ( ) ,
283- TensorElementType :: Float16 => todo ! ( ) ,
284- TensorElementType :: Bfloat16 => todo ! ( ) ,
285- _ => todo ! ( ) ,
276+ other => {
277+ return Err ( anyhow ! ( "'{other:?}' is not supported by JS tensor." ) )
278+ } ,
286279 } ;
287280
288281 Ok ( Self {
You can’t perform that action at this time.
0 commit comments