Coder Social home page Coder Social logo

baozhiqiang1978 / computer-vision-demosaicingimage Goto Github PK

View Code? Open in Web Editor NEW

This project forked from nehay06/computer-vision-demosaicingimage

0.0 0.0 0.0 1.01 MB

in digital cameras the red, blue, and green sensors are interlaced in the Bayer pattern (Figure 2). The missing values are interpolated to obtain a full color image

MATLAB 100.00%

computer-vision-demosaicingimage's Introduction

Computer-Vision-demosaicingImage

Recall that in digital cameras the red, blue, and green sensors are interlaced in the Bayer pattern (Figure 2). The missing values are interpolated to obtain a full color image. This project implemenst several interpolation algorithms. The input to the algorithm is a single image im, a NxM array of numbers between 0 and 1. These are measurements in the format shown in Figure 2, i.e., top left im(1,1) is red, im(1,2) is green, im(2,1) is green, im(2,2) is blue, etc. Included code creates a single color image C from these measurements.

Bayer Patter The code loads images from the data directory (in data/demosaic), artificially mosaics them (mosaicImage.m file), and provides them as input to the demosaicing algorithm (demosaicImage.m file). By comparing the result with the input we can also compute the reconstruction error measured as the distance between the reconstructed image and the true image. This is what the algorithm reports.

demosaicImage(im, ’baseline’) is implemented which simply replaces all the missing values for a channel with the average value of that channel. Following functions are implemented in the file:

  • demosaicImage(im, ’nn’) – nearest-neighbour interpolation.
  • demosaicImage(im, ’linear’) – linear interpolation.
  • demosaicImage(im, ’adagrad’) – adaptive gradient interpolation.

run the evalDemosaic.m and you should see the output.

computer-vision-demosaicingimage's People

Contributors

nehay06 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.