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 (e2c17554c4e97ac5ee46925fa94b1a2e54419333)
- Edit README.md (979e7b6a2782926c934d39e6b7d39f8012665bb1)
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-lightweight-x2-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-lightweight-x2-64`.
|
16 |
```js
|
17 |
-
import { pipeline } from '@
|
18 |
|
19 |
// Create image-to-image pipeline
|
20 |
const upscaler = await pipeline('image-to-image', 'Xenova/swin2SR-lightweight-x2-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-lightweight-x2-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-lightweight-x2-64', {
|
21 |
+
dtype: 'fp32', // Change this line to use the non-quantized version
|
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:8711119d8bb84140aa1b6b15bb7a78d7b07600633f394b347ea277932fc3e54e
|
3 |
+
size 5604577
|
onnx/model_q4.onnx
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:b75c09757a7159f32ad279919a77fb185c3389676674cf226a467eaf2f7928f1
|
3 |
+
size 5675089
|
onnx/model_q4f16.onnx
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:494d7912760b8314c9f61c130ab520a6b601046cb34a00a3c895145a43523aeb
|
3 |
+
size 4041879
|
onnx/model_uint8.onnx
ADDED
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
1 |
+
version https://git-lfs.github.com/spec/v1
|
2 |
+
oid sha256:ba07a9e1d1759817ba74d40f605caaff08b44e566ae5ae9653e17b7e1eff28bf
|
3 |
+
size 5545300
|