Coder Social home page Coder Social logo

kevinczhou / optical-coherence-refraction-tomography Goto Github PK

View Code? Open in Web Editor NEW
29.0 6.0 11.0 185 KB

Code for optical coherence refraction tomography (OCRT)

License: Other

Python 89.09% Jupyter Notebook 10.91%
tensorflow optical-coherence-tomography tomography optical-imaging

optical-coherence-refraction-tomography's Introduction

Optical coherence refraction tomography

This repository contains Python code that implements optical coherence refraction tomography (OCRT), a technique which starts with low-resolution optical coherence tomography (OCT) images acquired from multiple angles, and through iterative optimization generates simultaneously 1) a high-resolution reconstruction, and 2) a refractive index map of the sample. For more details, you can read our paper at https://www.nature.com/articles/s41566-019-0508-1 (or, if you don't have a subscription to Nature Photonics, https://rdcu.be/bO6eQ).

More recently, we have extended OCRT to spectroscopic OCT (SOCT). The new technique, termed spectroscopic OCRT (SOCRT), circumvents the trade-off between axial resolution and spectral resolution in SOCT, thus enabling reconstructions with simultaneously high spatial and spectral resolution (https://www.osapublishing.org/ol/abstract.cfm?uri=ol-45-7-2091).

See also our 3D implementation of OCRT, featuring a new hardware and a new, more efficient, GPU-accelerated reconstruction algorithm: https://github.com/kevinczhou/3d-ocrt

Data

This code generates OCRT results similar to those in figures 4-6 of our paper, which feature 7 different biological samples:

  • mouse_vas_deferens1
  • mouse_vas_deferens2
  • mouse_femoral_artery
  • mouse_bladder
  • mouse_trachea
  • human_cornea
  • insect_leg

These 7 datasets can be downloaded from here as .mat files. They are 80-120 MB each.

Code

The code depends on the following libraries:

  • tensorflow (the CPU version is sufficient)
  • numpy
  • scipy
  • opencv
  • matplotlib
  • jupyter

With these libraries installed and the datasets downloaded into the data/ directory, you should be able to run the jupyter notebook as is.

I tested this code for all 7 datasets using Python 2.7 with TensorFlow 1.8 on a desktop running Ubuntu 16.04 with 48 GB of RAM. I expect that the code should work with later versions of TensorFlow (before 2.0) and in Python 3, though I did not test these as thoroughly as I did for Python 2/TensorFlow 1.8. Expect slightly different results.

Depending on the sample, this code could end up exceeding 40 GB of RAM usage, so I recommend using a machine with at least that much memory. With the default settings in the code, expect on the order of several hours to around a day (a few minutes per iteration) for the optimization loops to run. Also expect the saved TensorFlow graph to take up ~500 MB of disk space per sample.

As the authors have a currently-pending patent related to OCRT, you may only use this code for non-commercial purposes.

Citation

If you find our code and/or datasets useful to your research, please cite the following publication:

Zhou, K. C., Qian, R., Degan, S., Farsiu, S., & Izatt, J. A. Optical coherence refraction tomography. Nature Photonics, 13(11), 794-802 (2019).

optical-coherence-refraction-tomography's People

Contributors

kevinczhou 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

Watchers

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