mlboydaisuke commited on
Commit
d2f5a46
·
verified ·
1 Parent(s): 1cfa7cf

Upload README.md with huggingface_hub

Browse files
Files changed (1) hide show
  1. README.md +47 -0
README.md ADDED
@@ -0,0 +1,47 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ tags:
4
+ - executorch
5
+ - xnnpack
6
+ - pte
7
+ - on-device
8
+ - image-segmentation
9
+ ---
10
+ # dis_isnet — ExecuTorch XNNPACK
11
+
12
+ - **Source**: xuebinqin/DIS + NimaBoscarino/IS-Net_DIS-general-use weights
13
+ - **License**: Apache-2.0
14
+ - **Input**: [[1, 3, 1024, 1024]] — RGB, scaled to [-1,1] (x/255 then (x-0.5)/0.5), 1024x1024
15
+ - **Output**: alpha mask [1,1,1024,1024] 0-1 (sigmoid)
16
+
17
+ ## Variants
18
+
19
+ All variants take and return fp32 tensors — swap the `.pte` file, keep your app code.
20
+
21
+ | precision | file | size (MB) | parity vs fp32 eager (worst corr) | Mac median (ms)* |
22
+ |-----------|------|-----------|------------------------------------|------------------|
23
+ | fp32 | `dis_isnet_xnnpack_fp32.pte` | 176.1 | 1.000000 | 169.0 |
24
+ | int8 | `dis_isnet_xnnpack_int8.pte` | 44.3 | 0.987820 | 70.1 |
25
+
26
+ \*Mac arm64, single process, median of 10 — a reference point for relative cost
27
+ only, not a device number (torch eager fp32 on the same machine: 392.2 ms).
28
+
29
+ ### Precisions that did not earn a slot
30
+
31
+ - **fp16 is not shipped**: worst-output corr 0.986 against fp32 eager, below the 0.995 bar for this precision. The file converts and runs; the numbers do not hold up, so it is left out rather than shipped with a warning.
32
+
33
+ ## Verification (executorch 1.4.0, torch 2.13.0)
34
+
35
+ Parity is measured against the fp32 eager model on real image input; `corr` is
36
+ the correlation over all elements of each output tensor.
37
+
38
+ | output | shape | max_abs_diff | corr |
39
+ |--------|-------|--------------|------|
40
+ | 0 | [1, 1, 1024, 1024] | 8.941e-07 | 1.000000 |
41
+
42
+ XNNPACK delegate coverage (fp32): 100.0% (468/468 ops)
43
+
44
+ ## Conversion
45
+
46
+ torch.export -> to_edge_transform_and_lower(XnnpackPartitioner) -> .pte
47
+ (conversion scripts: [executorch-models](https://github.com/john-rocky/executorch-models))