Skip to content
WebAI

Transformers.js · Model

Swin2SR (real-world x4)

The successor to SwinIR, and the one with a published ONNX export: a transformer super-resolution model trained on real-world degradation rather than clean bicubic downsampling. SwinIR itself ships no browser build.

Upstream browser example

Catalog comparison

Entries include models, tools and applications. An upstream example documents a browser integration, not a test on your device. Missing versions, measurements and licenses remain unverified. Historical estimates are not benchmark results.

Catalog comparison
EntryEntry typeFrameworkResourcesLicenseBrowser evidenceLinks

Swin2SR (real-world x4)

The successor to SwinIR, and the one with a published ONNX export: a transformer super-resolution model trained on real-world degradation rather than clean bicubic downsampling. SwinIR itself ships no browser build.

Tasks: Super resolution

ModelTransformers.js

q4f16: 14.8 MiB

q8: 20.4 MiB

fp16: 30.9 MiB

fp32: 50.3 MiB

Code license: Apache-2.0

Weight license: Apache-2.0

Upstream browser example

Reference ↗

Source review is not a browser execution test.

Sources and comparison details
Exact model ID
Xenova/swin2SR-realworld-sr-x4-64-bsrgan-psnr
Natural languages
Not specified
Programming languages
Not specified
Other reported capabilities
4x upscale, Real-world degradation
Package
Not verified
Runtime version
@huggingface/transformers@4.3.0
Execution backend
Not verified
Code license
Apache-2.0
Weight license
Apache-2.0
Legacy license label (unverified)
Apache-2.0

Deployment variants

q4f16
Download size: 14.8 MiB
Peak runtime memory: Not measured
Quantization / precision: q4f16
Weight revision: d0e9926970c93e472ce2392373d72597fc849027
Weight artifact ↗
q8
Download size: 20.4 MiB
Peak runtime memory: Not measured
Quantization / precision: q8
Weight revision: d0e9926970c93e472ce2392373d72597fc849027
Weight artifact ↗
fp16
Download size: 30.9 MiB
Peak runtime memory: Not measured
Quantization / precision: fp16
Weight revision: d0e9926970c93e472ce2392373d72597fc849027
Weight artifact ↗
fp32
Download size: 50.3 MiB
Peak runtime memory: Not measured
Quantization / precision: fp32
Weight revision: d0e9926970c93e472ce2392373d72597fc849027
Weight artifact ↗

Performance and compatibility measurements

Compare only results with the same task, input, hardware, browser and precision. No ranking is inferred from model size.

Not measured

Running Swin2SR (real-world x4) in the browser

Swin2SR (real-world x4) sits under Vision / Super resolution and is listed as a Model running on Transformers.js. Its verified weight size is 14.8 MiB. The evidence is an upstream browser example; this site has not tested it yet.

The typical way to load weights like these is to serve quantised ONNX from a CDN or your own origin, run them through the in-page runtime, and fall back to WebAssembly when WebGPU is unavailable. Code licence: Apache-2.0; weight licence: Apache-2.0 — check the original repository before commercial use.

Swin2SR (real-world x4): common questions

Can Swin2SR (real-world x4) be used commercially?
This catalogue records “Apache-2.0 / Apache-2.0”. Terms come from the model repository; the label here only reflects what was checked. If no licence is stated, do not ship it commercially.
How large are Swin2SR (real-world x4) weights?
The recorded size is 14.8 MiB. Quantisation variants differ a lot, so prefer the int8 or 4-bit build for the browser.
How do I call Swin2SR (real-world x4) from a project?
Most entries load through Transformers.js: host the weights somewhere the browser can fetch, initialise the runtime on the page, then submit text, image or audio for the task. The exact API lives in the model repository and the runtime docs.
Does running a model here upload my data?
The demos on this site infer inside the tab, so inputs never reach a server. Weights and runtimes are fetched from a CDN on first use and then served from the browser cache.

Super resolution