torchsr
Super Resolution Networks for pytorch
What it is and what it does
torchsr is a PyTorch library that bundles pretrained models for image super-resolution—the task of increasing image resolution by inferring missing details using trained neural networks. It includes five model architectures (EDSR, CARN, RDN, RCAN, NinaSR) with different size-to-accuracy tradeoffs, ranging from 0.10M to 40.7M parameters. The library also provides common super-resolution datasets (DIV2K, Set5, Set14, B100, Urban100, RealSR, Flicr2K, REDS) with automatic download, data augmentation utilities, and a unified training script.
You load a pretrained model, pass low-resolution images through it, and receive upscaled output. The package is designed for researchers and practitioners who want to apply or benchmark super-resolution without building models from scratch. It depends only on torch and torchvision, making it straightforward to integrate into existing PyTorch workflows.
Use it for:
- Upscale low-resolution photographs or screenshots to higher resolution for archival or display purposes
- Benchmark different super-resolution architectures on standard datasets to compare accuracy and speed tradeoffs
- Fine-tune a pretrained model on custom degraded image data for domain-specific super-resolution tasks
- Integrate super-resolution preprocessing into image analysis pipelines to improve downstream model performance on low-quality inputs
- Research super-resolution techniques by training models on provided datasets with the unified training script
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Provides pretrained neural network models for image super-resolution (upscaling low-resolution images to higher resolution) using PyTorch, including EDSR, CARN, RDN, RCAN, and NinaSR architectures.
Yes, if you need pretrained super-resolution models and can tolerate dormant maintenance. The package is stable, has no known vulnerabilities, and low install friction. However, verify that pretrained weights remain accessible and that it works with your PyTorch version—no updates have landed since August 2022, so compatibility with very recent PyTorch releases is uncertain.
Install
torchsr on PyPI
pip
pip install torchsruv
uv add torchsrpoetry
poetry add torchsrInstalling torchsr
Before you install
Low install friction with only torch and torchvision as runtime dependencies. Maintenance is dormant—last release was 2022-08-21 and last commit 2023-12-23, over a year ago, though the repository remains active and unarchived.
License in practice
MIT license is permissive, allowing commercial and private use with minimal restrictions.
Quickstart
pip install torchsr
from torchsr.models import ninasr_b0
from torchsr.datasets import Div2K
model = ninasr_b0(scale=2, pretrained=True)
dataset = Div2K(root="./data", scale=2, download=True)
hr, lr = dataset[0]
Verify before relying
- Whether pretrained model weights are still accessible and not hosted on deprecated servers
- Compatibility with recent PyTorch and torchvision versions released after 2023-12-23
- Whether the package will receive maintenance or security updates in the future
Package facts
| License | MIT (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 2 — torch, torchvision |
| Maintenance | dormant — 1,454 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 85,066/month — #13,955 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: torchsr-1.0.4-py3-none-any.whl
Keywords: superresolution, pytorch, edsr, rcan, ninasr
Tags
More Artificial Intelligence packages
LiteLLM provides a unified Python interface to…
permissive · top 100 on PyPI
huggingface-hubClient library and CLI tool for downloading,…
permissive · top 100 on PyPI
langchainLangChain provides a framework for building…
permissive · top 1,000 on PyPI
hf-xethf-xet provides chunk-based deduplication and…
permissive · top 1,000 on PyPI
tokenizersTokenizers converts raw text into token…
permissive · top 1,000 on PyPI
transformersTransformers provides a unified framework for…
permissive · top 1,000 on PyPI
basicsrBasicSR is a PyTorch-based toolbox for image…
permissive · top 15,000 on PyPI
pytorchcvProvides a collection of pretrained computer…
unclear · top 15,000 on PyPI
pytorch-forecastingPyTorch Forecasting provides neural network…
permissive · top 15,000 on PyPI
torchPyTorch provides GPU-accelerated tensor…
permissive · top 1,000 on PyPI
pytorch-msssimComputes fast, differentiable SSIM and MS-SSIM…
permissive · top 15,000 on PyPI
spandrel-extra-archesRegisters additional PyTorch model…
permissive · top 15,000 on PyPI
pytorch_revgradImplements a gradient reversal layer for…
permissive · top 15,000 on PyPI
pretrainedmodelsProvides a unified interface to load pretrained…
permissive · top 15,000 on PyPI
efficientnet-pytorchLoads and runs pretrained EfficientNet image…
permissive · top 15,000 on PyPI
spandrelSpandrel loads and runs pre-trained PyTorch…
permissive · top 5,000 on PyPI