Giter VIP home page Giter VIP logo

diffusercam's Introduction

DiffuserCam Algorithms

This code is based on the paper "DiffuserCam: Lensless Single-exposure 3D Imaging" available here. It implements the alternating direction method of multipliers (ADMM) algorithm described in the paper for recovering 3D volumes from 2D raw data captured with DiffuserCam. This code requires MATLAB.

Running the solver

In MATLAB, run the following:

xhat = DiffuserCam_main('DiffuserCam_settings.m');

The settings file contains all user-controlled parameters.

Data Files

Two files are necessary to use the solver.

  1. Stack of point spread functions (PSFs) taken at different axial distances, saved as '.mat' file with any background subtracted
  2. Raw data, saved as image (.png)

Paths to these files are specified in the settings file.

Included Example

To allow users to experiment with the code without building their own DiffuserCam system, we've provided an example PSF stack and raw data. The raw data is for a USAF resolution target, placed at an angle in front of the sensor. In this example, the target is imaged from the back, so you should see a mirror image of a USAF target after solving. Note that we've downsampled these images to reduce the file sizes and speed up the code, so the quality of the results is lower compared to higher resolutions.

diffusercam's People

Contributors

antipa avatar gracekuo01 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

diffusercam's Issues

psf shift question

psf = circshift(flip(psf,3),ceil(Nz/2)+2,3)/norm(psf(:)); %Shift impulse stack
I cant understand this code.
h(�, �;-z) = h(�, �; Nz - z) is a z-stack that is flipped in the zdirection.
Why circshift is needed?

Additional raw data

Could you please provide additional raw samples that have not been down-sampled? Something natural such as images out the window or faces with natural lighting.

Also a raw video (PNG per frame) if possible.

I'm running my own optimization routines w/ pytorch.

Demo providing strange result

Hi.
I have tested the code on Matlab for Linux. The only result that I get after 24 min of processing is the following (see picture):
results
Could please confirm if this is correct or an issue?
Thanks

Working example

Upload 512x512x32 PSF stack and USAF target data.
Rewrite main to point to default settings file
Change code to expect PSF and impulse stack to be same x and y dims
Add readme

I have a question about 3D algorithm of diffsercam.

I hope this mail find you well.

I am a student in japan. I have a question about 3D algorithm of diffsercam.

Row data doesn’t contain full data. In other word, because sensor size is small, the sensor can’t captures full data. If so, I can consider missed data? If I can take it into account, what should I do?

I hope I can hear from you soon.

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.