GithubHelp home page GithubHelp logo

dream-winter / bicubic-interpolation Goto Github PK

View Code? Open in Web Editor NEW

This project forked from rootpine/bicubic-interpolation

0.0 0.0 0.0 626 KB

Bicubic interpolation for images (Python)

License: Apache License 2.0

Python 100.00%

bicubic-interpolation's Introduction

Bicubic-interpolation

This repository is for simple implementation of 'Bicubic-interpolation for images' (Python3).

Table of contents

Formulation

  • Interpolation kernel [1]
    Formulation

  • Interpolation
    Use the values of 16 pixels around the new pixel dst(x,y) [1][2]. (x,y) shows the location of pixels. Formulation2
    Here, f means the values of pixels. x1, x2, x3, x4 are the distance of x direction from new pixel to near 16 pixels. y1, ... are the distance of y direction.

Example

  • Upscale input image 2 times (ratio = 2)
    The 'butterfly' image is from [3].
    Input image
    ↑ Input image (256x256)
    Output image
    ↑ Output image (512x512)

Requirement

  • Python 3.5.2 or more

Installation

$ git clone https://github.com/rootpine/Bicubic-interpolation.git

Usage

  1. $ python3 bicubic.py

Reference

  1. R. Keys, "Cubic convolution interpolation for digital image processing," in IEEE Transactions on Acoustics, Speech, and Signal Processing, vol. 29, no. 6, pp. 1153-1160, December 1981. URL: http://ieeexplore.ieee.org/stamp/stamp.jsp?tp=&arnumber=1163711&isnumber=26156
  2. 奥富正敏ら, "ディジタル画像処理[改定新版]", CG-ARTS協会, pp. 170-171, 2016.
  3. M. Bevilacqua, A. Roumy, C. Guillemot and ML. Alberi, "Low-Complexity Single-Image Super-Resolution based on Nonnegative Neighbor Embedding",BMVC 2012.
  4. https://github.com/yunabe/codelab/blob/master/misc/terminal_progressbar/progress.py to show the progress.

Author

@rootpine

bicubic-interpolation's People

Contributors

rootpine avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.