msluszniak commited on
Commit
3a80a76
·
verified ·
1 Parent(s): aa50b70

Add XNNPACK int8 vector estimator and vocoder

Browse files
README.md CHANGED
@@ -59,7 +59,22 @@ library as ExecuTorch `.pte` programs, ready to run on device.
59
  | `xnnpack/duration_predictor_xnnpack_fp32.pte` | duration_predictor | xnnpack | fp32 |
60
  | `xnnpack/text_encoder_xnnpack_fp32.pte` | text_encoder | xnnpack | fp32 |
61
  | `xnnpack/vector_estimator_xnnpack_fp32.pte` | vector_estimator | xnnpack | fp32 |
 
62
  | `xnnpack/vocoder_xnnpack_fp32.pte` | vocoder | xnnpack | fp32 |
 
 
 
 
 
 
 
 
 
 
 
 
 
 
63
 
64
  ## Unshipped backends
65
 
@@ -104,11 +119,13 @@ vulkan/duration_predictor_vulkan_fp16.pte 1.7 MB
104
  vulkan/text_encoder_vulkan_fp16.pte 17.3 MB
105
  vulkan/vector_estimator_vulkan_fp16.pte 122 MB
106
  vulkan/vocoder_vulkan_fp16.pte 48.4 MB
107
- xnnpack/config.json 6.7 kB
108
  xnnpack/duration_predictor_xnnpack_fp32.pte 3.4 MB
109
  xnnpack/text_encoder_xnnpack_fp32.pte 34.5 MB
110
  xnnpack/vector_estimator_xnnpack_fp32.pte 245 MB
 
111
  xnnpack/vocoder_xnnpack_fp32.pte 96.7 MB
 
112
  ```
113
 
114
  ## Compatibility
 
59
  | `xnnpack/duration_predictor_xnnpack_fp32.pte` | duration_predictor | xnnpack | fp32 |
60
  | `xnnpack/text_encoder_xnnpack_fp32.pte` | text_encoder | xnnpack | fp32 |
61
  | `xnnpack/vector_estimator_xnnpack_fp32.pte` | vector_estimator | xnnpack | fp32 |
62
+ | `xnnpack/vector_estimator_xnnpack_int8.pte` | vector_estimator | xnnpack | int8 |
63
  | `xnnpack/vocoder_xnnpack_fp32.pte` | vocoder | xnnpack | fp32 |
64
+ | `xnnpack/vocoder_xnnpack_int8.pte` | vocoder | xnnpack | int8 |
65
+
66
+ ## XNNPACK int8
67
+
68
+ `xnnpack/vector_estimator_xnnpack_int8.pte` and `xnnpack/vocoder_xnnpack_int8.pte` are 8da8w
69
+ (int8 dynamic activations, int8 per-channel weights) on the Linear layers, with the ConvNeXt
70
+ pointwise convs moved onto Linears. The int8 set reuses the fp32 duration predictor and text
71
+ encoder. LibriSpeech test-clean texts, voice F1, 8 steps, WER of a whisper base.en round trip:
72
+
73
+ | | WER (57 short) | WER (8 long) |
74
+ | --- | --- | --- |
75
+ | fp32 | 3.36 | 3.32 |
76
+ | fp32, other noise seed | 3.26 | 3.80 |
77
+ | int8 | 3.74 | 3.01 |
78
 
79
  ## Unshipped backends
80
 
 
119
  vulkan/text_encoder_vulkan_fp16.pte 17.3 MB
120
  vulkan/vector_estimator_vulkan_fp16.pte 122 MB
121
  vulkan/vocoder_vulkan_fp16.pte 48.4 MB
122
+ xnnpack/config.json 13.1 kB
123
  xnnpack/duration_predictor_xnnpack_fp32.pte 3.4 MB
124
  xnnpack/text_encoder_xnnpack_fp32.pte 34.5 MB
125
  xnnpack/vector_estimator_xnnpack_fp32.pte 245 MB
126
+ xnnpack/vector_estimator_xnnpack_int8.pte 62.9 MB
127
  xnnpack/vocoder_xnnpack_fp32.pte 96.7 MB
128
+ xnnpack/vocoder_xnnpack_int8.pte 36.8 MB
129
  ```
130
 
131
  ## Compatibility
xnnpack/config.json CHANGED
@@ -304,6 +304,303 @@
304
  }
305
  }
306
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
307
  }
308
  ]
309
  }
 
304
  }
305
  }
306
  }
307
+ },
308
+ {
309
+ "file": null,
310
+ "components": {
311
+ "duration_predictor": "duration_predictor_xnnpack_fp32.pte",
312
+ "text_encoder": "text_encoder_xnnpack_fp32.pte",
313
+ "vector_estimator": "vector_estimator_xnnpack_int8.pte",
314
+ "vocoder": "vocoder_xnnpack_int8.pte"
315
+ },
316
+ "precision": "int8",
317
+ "methods": {
318
+ "duration_predictor": {
319
+ "forward": {
320
+ "inputs": [
321
+ {
322
+ "shape": [
323
+ 1,
324
+ -1
325
+ ],
326
+ "dtype": "int64"
327
+ },
328
+ {
329
+ "shape": [
330
+ 1,
331
+ 8,
332
+ 16
333
+ ],
334
+ "dtype": "float32"
335
+ },
336
+ {
337
+ "shape": [
338
+ 1,
339
+ 1,
340
+ -1
341
+ ],
342
+ "dtype": "float32"
343
+ }
344
+ ],
345
+ "outputs": [
346
+ {
347
+ "shape": [
348
+ 1
349
+ ],
350
+ "dtype": "float32"
351
+ }
352
+ ]
353
+ },
354
+ "get_dynamic_dims_forward": {
355
+ "inputs": [],
356
+ "outputs": [
357
+ {
358
+ "shape": [
359
+ 2,
360
+ 3
361
+ ],
362
+ "dtype": "int32"
363
+ },
364
+ {
365
+ "shape": [
366
+ 3,
367
+ 3
368
+ ],
369
+ "dtype": "int32"
370
+ },
371
+ {
372
+ "shape": [
373
+ 3,
374
+ 3
375
+ ],
376
+ "dtype": "int32"
377
+ }
378
+ ]
379
+ }
380
+ },
381
+ "text_encoder": {
382
+ "forward": {
383
+ "inputs": [
384
+ {
385
+ "shape": [
386
+ 1,
387
+ -1
388
+ ],
389
+ "dtype": "int64"
390
+ },
391
+ {
392
+ "shape": [
393
+ 1,
394
+ 50,
395
+ 256
396
+ ],
397
+ "dtype": "float32"
398
+ },
399
+ {
400
+ "shape": [
401
+ 1,
402
+ 1,
403
+ -1
404
+ ],
405
+ "dtype": "float32"
406
+ }
407
+ ],
408
+ "outputs": [
409
+ {
410
+ "shape": [
411
+ 1,
412
+ 256,
413
+ -1
414
+ ],
415
+ "dtype": "float32"
416
+ }
417
+ ]
418
+ },
419
+ "get_dynamic_dims_forward": {
420
+ "inputs": [],
421
+ "outputs": [
422
+ {
423
+ "shape": [
424
+ 2,
425
+ 3
426
+ ],
427
+ "dtype": "int32"
428
+ },
429
+ {
430
+ "shape": [
431
+ 3,
432
+ 3
433
+ ],
434
+ "dtype": "int32"
435
+ },
436
+ {
437
+ "shape": [
438
+ 3,
439
+ 3
440
+ ],
441
+ "dtype": "int32"
442
+ }
443
+ ]
444
+ }
445
+ },
446
+ "vector_estimator": {
447
+ "forward": {
448
+ "inputs": [
449
+ {
450
+ "shape": [
451
+ 1,
452
+ 144,
453
+ -1
454
+ ],
455
+ "dtype": "float32"
456
+ },
457
+ {
458
+ "shape": [
459
+ 1,
460
+ 256,
461
+ -1
462
+ ],
463
+ "dtype": "float32"
464
+ },
465
+ {
466
+ "shape": [
467
+ 1,
468
+ 50,
469
+ 256
470
+ ],
471
+ "dtype": "float32"
472
+ },
473
+ {
474
+ "shape": [
475
+ 1,
476
+ 1,
477
+ -1
478
+ ],
479
+ "dtype": "float32"
480
+ },
481
+ {
482
+ "shape": [
483
+ 1,
484
+ 1,
485
+ -1
486
+ ],
487
+ "dtype": "float32"
488
+ },
489
+ {
490
+ "shape": [
491
+ 1
492
+ ],
493
+ "dtype": "float32"
494
+ },
495
+ {
496
+ "shape": [
497
+ 1
498
+ ],
499
+ "dtype": "float32"
500
+ }
501
+ ],
502
+ "outputs": [
503
+ {
504
+ "shape": [
505
+ 1,
506
+ 144,
507
+ -1
508
+ ],
509
+ "dtype": "float32"
510
+ }
511
+ ]
512
+ },
513
+ "get_dynamic_dims_forward": {
514
+ "inputs": [],
515
+ "outputs": [
516
+ {
517
+ "shape": [
518
+ 3,
519
+ 3
520
+ ],
521
+ "dtype": "int32"
522
+ },
523
+ {
524
+ "shape": [
525
+ 3,
526
+ 3
527
+ ],
528
+ "dtype": "int32"
529
+ },
530
+ {
531
+ "shape": [
532
+ 3,
533
+ 3
534
+ ],
535
+ "dtype": "int32"
536
+ },
537
+ {
538
+ "shape": [
539
+ 3,
540
+ 3
541
+ ],
542
+ "dtype": "int32"
543
+ },
544
+ {
545
+ "shape": [
546
+ 3,
547
+ 3
548
+ ],
549
+ "dtype": "int32"
550
+ },
551
+ {
552
+ "shape": [
553
+ 1,
554
+ 3
555
+ ],
556
+ "dtype": "int32"
557
+ },
558
+ {
559
+ "shape": [
560
+ 1,
561
+ 3
562
+ ],
563
+ "dtype": "int32"
564
+ }
565
+ ]
566
+ }
567
+ },
568
+ "vocoder": {
569
+ "forward": {
570
+ "inputs": [
571
+ {
572
+ "shape": [
573
+ 1,
574
+ 144,
575
+ -1
576
+ ],
577
+ "dtype": "float32"
578
+ }
579
+ ],
580
+ "outputs": [
581
+ {
582
+ "shape": [
583
+ 1,
584
+ -1
585
+ ],
586
+ "dtype": "float32"
587
+ }
588
+ ]
589
+ },
590
+ "get_dynamic_dims_forward": {
591
+ "inputs": [],
592
+ "outputs": [
593
+ {
594
+ "shape": [
595
+ 3,
596
+ 3
597
+ ],
598
+ "dtype": "int32"
599
+ }
600
+ ]
601
+ }
602
+ }
603
+ }
604
  }
605
  ]
606
  }
xnnpack/vector_estimator_xnnpack_int8.pte ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5998c9e45ff2639337a9985d3d825dbebb491c8f21f04dfa537fc350f74c8712
3
+ size 65983360
xnnpack/vocoder_xnnpack_int8.pte ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3a04e6fa13d648d0d2e624350ab7d9bdce1de6fc481fc114d429b67c6cd21448
3
+ size 38614400