@@ -51,24 +51,37 @@ interface MLContext {
51
51
52
52
dictionary MLOpSupportLimits {
53
53
MLInputOperandLayout preferredInputLayout;
54
- MLSupportLimits input;
55
- MLSupportLimits constant;
56
- MLSupportLimits output;
54
+ [EnforceRange] unsigned long long maxTensorByteLength;
55
+ MLDataTypeLimits input;
56
+ MLDataTypeLimits constant;
57
+ MLDataTypeLimits output;
57
58
};
58
59
59
- dictionary MLSupportLimits {
60
- sequence<MLOperandDataType> dataTypes;
60
+ typedef sequence<MLOperandDataType> MLDataTypeList;
61
+
62
+ dictionary MLDataTypeLimits {
63
+ MLDataTypeList dataTypes;
64
+ };
65
+
66
+ dictionary MLRankRange {
67
+ unsigned long min;
68
+ unsigned long max;
69
+ };
70
+
71
+ dictionary MLTensorLimits {
72
+ MLDataTypeList dataTypes;
73
+ MLRankRange rankRange;
61
74
};
62
75
63
76
dictionary MLBinarySupportLimits {
64
- MLSupportLimits a;
65
- MLSupportLimits b;
66
- MLSupportLimits output;
77
+ MLTensorLimits a;
78
+ MLTensorLimits b;
79
+ MLDataTypeLimits output;
67
80
};
68
81
69
82
dictionary MLSingleInputSupportLimits {
70
- MLSupportLimits input;
71
- MLSupportLimits output;
83
+ MLTensorLimits input;
84
+ MLDataTypeLimits output;
72
85
};
73
86
74
87
[SecureContext, Exposed=(Window, Worker)]
@@ -175,12 +188,12 @@ partial interface MLGraphBuilder {
175
188
};
176
189
177
190
dictionary MLBatchNormalizationSupportLimits {
178
- MLSupportLimits input;
179
- MLSupportLimits mean;
180
- MLSupportLimits variance;
181
- MLSupportLimits scale;
182
- MLSupportLimits bias;
183
- MLSupportLimits output;
191
+ MLTensorLimits input;
192
+ MLTensorLimits mean;
193
+ MLTensorLimits variance;
194
+ MLTensorLimits scale;
195
+ MLTensorLimits bias;
196
+ MLDataTypeLimits output;
184
197
};
185
198
186
199
partial dictionary MLOpSupportLimits {
@@ -217,8 +230,8 @@ partial interface MLGraphBuilder {
217
230
};
218
231
219
232
dictionary MLConcatSupportLimits {
220
- MLSupportLimits inputs;
221
- MLSupportLimits output;
233
+ MLTensorLimits inputs;
234
+ MLDataTypeLimits output;
222
235
};
223
236
224
237
partial dictionary MLOpSupportLimits {
@@ -249,10 +262,10 @@ partial interface MLGraphBuilder {
249
262
};
250
263
251
264
dictionary MLConv2dSupportLimits {
252
- MLSupportLimits input;
253
- MLSupportLimits filter;
254
- MLSupportLimits bias;
255
- MLSupportLimits output;
265
+ MLTensorLimits input;
266
+ MLTensorLimits filter;
267
+ MLTensorLimits bias;
268
+ MLDataTypeLimits output;
256
269
};
257
270
258
271
partial dictionary MLOpSupportLimits {
@@ -353,8 +366,8 @@ partial interface MLGraphBuilder {
353
366
};
354
367
355
368
dictionary MLLogicalNotSupportLimits {
356
- MLSupportLimits a;
357
- MLSupportLimits output;
369
+ MLTensorLimits a;
370
+ MLDataTypeLimits output;
358
371
};
359
372
360
373
partial dictionary MLOpSupportLimits {
@@ -411,15 +424,15 @@ partial interface MLGraphBuilder {
411
424
optional MLOperatorOptions options = {});
412
425
};
413
426
414
- dictionary MLQuantizationSupportLimits {
415
- MLSupportLimits input;
416
- MLSupportLimits scale;
417
- MLSupportLimits zeroPoint;
418
- MLSupportLimits output;
427
+ dictionary MLQuantizeDequantizeLinearSupportLimits {
428
+ MLTensorLimits input;
429
+ MLTensorLimits scale;
430
+ MLTensorLimits zeroPoint;
431
+ MLDataTypeLimits output;
419
432
};
420
433
421
434
partial dictionary MLOpSupportLimits {
422
- MLQuantizationSupportLimits dequantizeLinear;
435
+ MLQuantizeDequantizeLinearSupportLimits dequantizeLinear;
423
436
};
424
437
425
438
partial interface MLGraphBuilder {
@@ -430,7 +443,7 @@ partial interface MLGraphBuilder {
430
443
};
431
444
432
445
partial dictionary MLOpSupportLimits {
433
- MLQuantizationSupportLimits quantizeLinear;
446
+ MLQuantizeDequantizeLinearSupportLimits quantizeLinear;
434
447
};
435
448
436
449
dictionary MLEluOptions : MLOperatorOptions {
@@ -466,9 +479,9 @@ partial interface MLGraphBuilder {
466
479
};
467
480
468
481
dictionary MLGatherSupportLimits {
469
- MLSupportLimits input;
470
- MLSupportLimits indices;
471
- MLSupportLimits output;
482
+ MLTensorLimits input;
483
+ MLTensorLimits indices;
484
+ MLDataTypeLimits output;
472
485
};
473
486
474
487
partial dictionary MLOpSupportLimits {
@@ -516,10 +529,10 @@ partial interface MLGraphBuilder {
516
529
};
517
530
518
531
dictionary MLGemmSupportLimits {
519
- MLSupportLimits a;
520
- MLSupportLimits b;
521
- MLSupportLimits c;
522
- MLSupportLimits output;
532
+ MLTensorLimits a;
533
+ MLTensorLimits b;
534
+ MLTensorLimits c;
535
+ MLDataTypeLimits output;
523
536
};
524
537
525
538
partial dictionary MLOpSupportLimits {
@@ -564,13 +577,13 @@ partial interface MLGraphBuilder {
564
577
};
565
578
566
579
dictionary MLGruSupportLimits {
567
- MLSupportLimits input;
568
- MLSupportLimits weight;
569
- MLSupportLimits recurrentWeight;
570
- MLSupportLimits bias;
571
- MLSupportLimits recurrentBias;
572
- MLSupportLimits initialHiddenState;
573
- MLSupportLimits outputs;
580
+ MLTensorLimits input;
581
+ MLTensorLimits weight;
582
+ MLTensorLimits recurrentWeight;
583
+ MLTensorLimits bias;
584
+ MLTensorLimits recurrentBias;
585
+ MLTensorLimits initialHiddenState;
586
+ MLDataTypeLimits outputs;
574
587
};
575
588
576
589
partial dictionary MLOpSupportLimits {
@@ -595,13 +608,13 @@ partial interface MLGraphBuilder {
595
608
};
596
609
597
610
dictionary MLGruCellSupportLimits {
598
- MLSupportLimits input;
599
- MLSupportLimits weight;
600
- MLSupportLimits recurrentWeight;
601
- MLSupportLimits hiddenState;
602
- MLSupportLimits bias;
603
- MLSupportLimits recurrentBias;
604
- MLSupportLimits output;
611
+ MLTensorLimits input;
612
+ MLTensorLimits weight;
613
+ MLTensorLimits recurrentWeight;
614
+ MLTensorLimits hiddenState;
615
+ MLTensorLimits bias;
616
+ MLTensorLimits recurrentBias;
617
+ MLDataTypeLimits output;
605
618
};
606
619
607
620
partial dictionary MLOpSupportLimits {
@@ -642,10 +655,10 @@ partial interface MLGraphBuilder {
642
655
};
643
656
644
657
dictionary MLNormalizationSupportLimits {
645
- MLSupportLimits input;
646
- MLSupportLimits scale;
647
- MLSupportLimits bias;
648
- MLSupportLimits output;
658
+ MLTensorLimits input;
659
+ MLTensorLimits scale;
660
+ MLTensorLimits bias;
661
+ MLDataTypeLimits output;
649
662
};
650
663
651
664
partial dictionary MLOpSupportLimits {
@@ -720,15 +733,15 @@ partial interface MLGraphBuilder {
720
733
};
721
734
722
735
dictionary MLLstmSupportLimits {
723
- MLSupportLimits input;
724
- MLSupportLimits weight;
725
- MLSupportLimits recurrentWeight;
726
- MLSupportLimits bias;
727
- MLSupportLimits recurrentBias;
728
- MLSupportLimits peepholeWeight;
729
- MLSupportLimits initialHiddenState;
730
- MLSupportLimits initialCellState;
731
- MLSupportLimits outputs;
736
+ MLTensorLimits input;
737
+ MLTensorLimits weight;
738
+ MLTensorLimits recurrentWeight;
739
+ MLTensorLimits bias;
740
+ MLTensorLimits recurrentBias;
741
+ MLTensorLimits peepholeWeight;
742
+ MLTensorLimits initialHiddenState;
743
+ MLTensorLimits initialCellState;
744
+ MLDataTypeLimits outputs;
732
745
};
733
746
734
747
partial dictionary MLOpSupportLimits {
@@ -754,15 +767,15 @@ partial interface MLGraphBuilder {
754
767
};
755
768
756
769
dictionary MLLstmCellSupportLimits {
757
- MLSupportLimits input;
758
- MLSupportLimits weight;
759
- MLSupportLimits recurrentWeight;
760
- MLSupportLimits hiddenState;
761
- MLSupportLimits cellState;
762
- MLSupportLimits bias;
763
- MLSupportLimits recurrentBias;
764
- MLSupportLimits peepholeWeight;
765
- MLSupportLimits outputs;
770
+ MLTensorLimits input;
771
+ MLTensorLimits weight;
772
+ MLTensorLimits recurrentWeight;
773
+ MLTensorLimits hiddenState;
774
+ MLTensorLimits cellState;
775
+ MLTensorLimits bias;
776
+ MLTensorLimits recurrentBias;
777
+ MLTensorLimits peepholeWeight;
778
+ MLDataTypeLimits outputs;
766
779
};
767
780
768
781
partial dictionary MLOpSupportLimits {
@@ -834,9 +847,9 @@ partial interface MLGraphBuilder {
834
847
};
835
848
836
849
dictionary MLPreluSupportLimits {
837
- MLSupportLimits input;
838
- MLSupportLimits slope;
839
- MLSupportLimits output;
850
+ MLTensorLimits input;
851
+ MLTensorLimits slope;
852
+ MLDataTypeLimits output;
840
853
};
841
854
842
855
partial dictionary MLOpSupportLimits {
@@ -936,10 +949,10 @@ partial interface MLGraphBuilder {
936
949
};
937
950
938
951
dictionary MLScatterSupportLimits {
939
- MLSupportLimits input;
940
- MLSupportLimits indices;
941
- MLSupportLimits updates;
942
- MLSupportLimits output;
952
+ MLTensorLimits input;
953
+ MLTensorLimits indices;
954
+ MLTensorLimits updates;
955
+ MLDataTypeLimits output;
943
956
};
944
957
945
958
partial dictionary MLOpSupportLimits {
@@ -1018,8 +1031,8 @@ partial interface MLGraphBuilder {
1018
1031
};
1019
1032
1020
1033
dictionary MLSplitSupportLimits {
1021
- MLSupportLimits input;
1022
- MLSupportLimits outputs;
1034
+ MLTensorLimits input;
1035
+ MLDataTypeLimits outputs;
1023
1036
};
1024
1037
1025
1038
partial dictionary MLOpSupportLimits {
@@ -1077,10 +1090,10 @@ partial interface MLGraphBuilder {
1077
1090
};
1078
1091
1079
1092
dictionary MLWhereSupportLimits {
1080
- MLSupportLimits condition;
1081
- MLSupportLimits trueValue;
1082
- MLSupportLimits falseValue;
1083
- MLSupportLimits output;
1093
+ MLTensorLimits condition;
1094
+ MLTensorLimits trueValue;
1095
+ MLTensorLimits falseValue;
1096
+ MLDataTypeLimits output;
1084
1097
};
1085
1098
1086
1099
partial dictionary MLOpSupportLimits {
0 commit comments