Giter Site home page Giter Site logo

kevinczhou / deep-prior-diffraction-tomography Goto Github PK

View Code? Open in Web Editor NEW
16.0 3.0 4.0 25 KB

3D reconstruction code for deep prior diffraction tomography

License: MIT License

Python 75.75% Jupyter Notebook 24.25%
diffraction-tomography tensorflow deep-image-prior tomography fourier-ptychography dip regularizers

deep-prior-diffraction-tomography's Introduction

Diffraction tomography with a deep image prior

This repository contains python and tensorflow code that implements 3D diffraction tomography under a variety of priors/regularizers, including total variation (TV), positivity, and now, for the first time, the deep image prior (DIP). We call our technique deep prior diffraction tomography (DP-DT), which reparameterizes the reconstruction as the output of an untrained 3D convolutional neural network (CNN). We show that DP-DT outperforms traditional regularizers in terms of addressing the missing cone problem, which we demonstrate in a variety of samples and with two popular scattering models: the first Born approximation and the multi-slice model.

For more information on implementation and results, see our peer-reviewed paper at https://www.osapublishing.org/oe/abstract.cfm?uri=oe-28-9-12872 (or the arXiv version, https://arxiv.org/abs/1912.05330, which contains more simulation results in its appendix).

Data

We provide the raw multi-angle data stacks for all of our experimental results (Figs. 7-10). These include the 1-um bead sample, the 2-layer 2-um bead sample, and the starfish embryo sample, which can be downloaded from here as .mat files (~150 MB each). The jupyter notebook assumes these files are stored in DPDT_raw_data/ in the same directory as the python files.

Code

Run this code using Python 3, with the following libraries installed:

  • tensorflow (version 1.x, preferably the GPU version)
  • numpy
  • scipy
  • matplotlib
  • jupyter

After installing these libraries, start with the run_DPDT.ipynb jupyter notebook, which contains further instructions. This code should work with later versions of tensorflow (I've tested 1.14), but not with tensorflow 2, at least in its current state. The optimization gets a significant speedup with a GPU, so I recommend using one if you have one. Note that DP-DT can get memory intensive, as it needs to store both the diffraction tomography forward model and the 3D DIP. Thus, if your GPU doesn't have enough memory, try decreasing the field of view and/or the batch size. The default fields of view and batch sizes in the code can be supported by a 16-GB GPU.

Citation

If you find our code useful to your research, please consider citing the accompanying publication:

Kevin C. Zhou and Roarke Horstmeyer, "Diffraction tomography with a deep image prior," Opt. Express 28, 12872-12896 (2020)

deep-prior-diffraction-tomography's People

Contributors

kevinczhou avatar

Stargazers

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

Watchers

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