skillfed

resize-right

Resize Right

resize-right v0.0.2 198.7K downloads/30d#9,721 on PyPI566
Permissive license MIT Abandoned released

What it is and what it does

ResizeRight is a tensor resizing library designed for machine learning and image enhancement tasks. It supports both NumPy and PyTorch tensors seamlessly, automatically choosing the framework based on input type, and performs fully differentiable operations suitable for training. The package addresses what the author identifies as correctness issues in existing resizers: it produces results matching MATLAB's imresize for simple cases, implements anti-aliasing for downscaling to prevent artifacts, and crucially handles the non-integer scaling case by accepting both scale-factor and output-size parameters to maintain consistency and centering.

The library offers multiple interpolation methods (cubic, linear, Lanczos, box), supports N-dimensional tensors with M-dimensional resizing, and can apply different scale-factors per dimension. For rational scale-factors with small numerators, it can use efficient convolution-based calculation. It includes flexible padding modes and allows custom interpolation methods. However, the package has been abandoned since mid-2023 with no updates or maintenance.

Use it for:

  • Preprocessing images for super-resolution models where consistent scale-factor and output-size handling is critical for training stability.
  • Downscaling high-resolution images while preserving detail through anti-aliasing, avoiding artifacts common in other resizing libraries.
  • Building differentiable image processing pipelines where gradients must flow through the resizing operation.
  • Implementing zero-shot super-resolution or other learning-based image enhancement tasks requiring precise, centered resizing.
  • Batch processing large tensors efficiently using convolution-based resizing when scale-factors are rational with small numerators.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Resizes images or tensors in NumPy or PyTorch with differentiable operations, supporting anti-aliasing, multiple interpolation methods, and flexible scale-factor or output-size specification.

Yes, if you need differentiable resizing with anti-aliasing and are willing to accept an abandoned package with no ongoing maintenance. The core algorithm appears sound for its stated use cases (super-resolution, image restoration), but expect no bug fixes, no compatibility updates, and no support. Suitable for research or one-off projects; risky for production systems or long-term codebases.

Install

resize-right on PyPI

pip

pip install resize-right

uv

uv add resize-right

poetry

poetry add resize-right

Installing resize-right

Before you install

Low install friction with no runtime dependencies; however, the package is abandoned (last commit 2023-07-13, no releases since 2022-05-05), so expect no maintenance or bug fixes going forward.

License in practice

MIT license is permissive, allowing commercial and private use with minimal restrictions—you may use, modify, and distribute this package freely as long as you include the license notice.

Quickstart

pip install resize-right

import resize_right

resized = resize_right.resize(input, scale_factors=0.5)

Requires either NumPy or PyTorch installed; the package itself has no hard dependency but will not function without at least one of them.

Verify before relying

  • Whether the package's claimed correctness advantages over MATLAB and other resizers hold up under real-world use cases beyond the author's test cases.
  • Current compatibility with modern Python versions beyond 3.6, given the package is abandoned and has not been tested recently.
  • Performance characteristics and memory efficiency when processing very large batches or high-resolution tensors with the convolution-based optimization.

Package facts

License MIT (permissive)
Python support not specified
Install friction low — pure-Python wheel
Runtime dependencies none
Maintenance abandoned — 1,562 days since the last release
Last repo commit
First released
Downloads 198,695/month — #9,721 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: resize_right-0.0.2-py3-none-any.whl

Keywords: deep learning, image resize

Development Status :: 4 - BetaIntended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseProgramming Language :: Python :: 3.6Topic :: Scientific/Engineering :: Artificial Intelligence

Tags

image resize numpy pytorchdifferentiable tensor resizinganti-aliasing downscalingsuper-resolution preprocessingimage restoration resizingbicubic interpolation tensorsscale-factor output-size resize
image-processingdifferentiable-opsabandoned

More Artificial Intelligence packages