Add/update the quantized ONNX model files and README.md for Transformers.js v3 (#1)
Browse files- Add/update the quantized ONNX model files and README.md for Transformers.js v3 (5faccfb677976e422900dd9f88c7fb4ac9383476)
Co-authored-by: Yuichiro Tachibana <[email protected]>
- README.md +4 -4
- onnx/model_bnb4.onnx +3 -0
- onnx/model_q4.onnx +3 -0
- onnx/model_q4f16.onnx +3 -0
- onnx/model_uint8.onnx +3 -0
README.md
CHANGED
@@ -7,18 +7,18 @@ https://huggingface.co/caidas/swin2SR-classical-sr-x4-64 with ONNX weights to be
|
|
7 |
|
8 |
## Usage (Transformers.js)
|
9 |
|
10 |
-
If you haven't already, you can install the [Transformers.js](https://huggingface.co/docs/transformers.js) JavaScript library from [NPM](https://www.npmjs.com/package/@
|
11 |
```bash
|
12 |
-
npm i @
|
13 |
```
|
14 |
|
15 |
**Example:** Upscale an image with `Xenova/swin2SR-classical-sr-x4-64`.
|
16 |
```js
|
17 |
-
import { pipeline } from '@
|
18 |
|
19 |
// Create image-to-image pipeline
|
20 |
const upscaler = await pipeline('image-to-image', 'Xenova/swin2SR-classical-sr-x4-64', {
|
21 |
-
|
22 |
});
|
23 |
|
24 |
// Upscale an image
|
|
|
7 |
|
8 |
## Usage (Transformers.js)
|
9 |
|
10 |
+
If you haven't already, you can install the [Transformers.js](https://huggingface.co/docs/transformers.js) JavaScript library from [NPM](https://www.npmjs.com/package/@huggingface/transformers) using:
|
11 |
```bash
|
12 |
+
npm i @huggingface/transformers
|
13 |
```
|
14 |
|
15 |
**Example:** Upscale an image with `Xenova/swin2SR-classical-sr-x4-64`.
|
16 |
```js
|
17 |
+
import { pipeline } from '@huggingface/transformers';
|
18 |
|
19 |
// Create image-to-image pipeline
|
20 |
const upscaler = await pipeline('image-to-image', 'Xenova/swin2SR-classical-sr-x4-64', {
|
21 |
+
dtype: 'fp32', // Replaces quantized: false
|
22 |
});
|
23 |
|
24 |
// Upscale an image
|
onnx/model_bnb4.onnx
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:b60fa2954295571929ccde8a6f760bf04bd0cb99c29dc424bdb03d4e9e1cc3e1
|
3 |
+
size 22814480
|
onnx/model_q4.onnx
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:683009ccaebef5cc5674dbbe5886a3f2ed0ed2faa82a780219e9fc59ffba7eaa
|
3 |
+
size 23784608
|
onnx/model_q4f16.onnx
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:a6caf298e53a9738404b28ea45f0dc55cc8eae1a52ee5a49f09bd4df45380367
|
3 |
+
size 15908383
|
onnx/model_uint8.onnx
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:c6ae25a4a6d2102c625712bbff2c7c0d2a25af3bf5afec488d5a0d3a1e2a4c75
|
3 |
+
size 19183439
|