Skip to content

rmcao/CalCIL

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

34 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CalCIL - gradient descent helper for computational image reconstruction via jax

Features

  • 🧠 brainless gradient descent-based image reconstruction
  • 🤓 fully customizable loss functions
  • 🫡 auto logging and visualization via tensorboard
  • 😬 flexible optimization parameters (variable specific settings, learning rate schedule, etc.)
  • 🤯 post-update custom functions
  • 🔮 handy helper functions for interactive 3/4D visualization on jupyter notebook

Why using jax?

Why not using jax?

  • Less commonly used than pytorch, so less community support
  • Pretty barebone, often need other libraries from jax ecosystem
  • The development of jax mainly relies on Google which may not be a good thing for some people

Installation

Detailed installation instructions can be found here.

# Create a virtual environment
conda create -n calcil python=3.9
conda activate calcil

# (optional, if needed) Install CUDA in conda virtual env
conda install -c conda-forge cudatoolkit~=11.8.0 cudnn~=8.8.0
conda install -c "nvidia/label/cuda-11.8.0" cuda-nvcc

# Install jaxlib for GPU
pip install jaxlib==0.3.18+cuda11.cudnn82 -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html

# Install this library
pip install git+https://github.com/rmcao/CalCIL.git

Tutorials

A step-by-step tutorial on how to use CalCIL for image reconstruction can be found here. Also, check out the example notebook for image deconvolution.

Usage

The following work is powered by CalCIL:

Citation

If you find this library useful, please consider citing the following papers:

@inproceedings{cao2022dynamic,
  title={Dynamic structured illumination microscopy with a neural space-time model},
  author={Cao, Ruiming and Liu, Fanglin Linda and Yeh, Li-Hao and Waller, Laura},
  booktitle={2022 IEEE International Conference on Computational Photography (ICCP)},
  pages={1--12},
  year={2022},
  organization={IEEE}
}

@article{cao2024neural,
  title={Neural space-time model for dynamic scene recovery in multi-shot computational imaging systems},
  author={Cao, Ruiming and Divekar, Nikita and Nu{\~n}ez, James and Upadhyayula, Srigokul and Waller, Laura},
  journal={bioRxiv 2024.01.16.575950},
  pages={2024--01},
  year={2024},
  publisher={Cold Spring Harbor Laboratory}
}

About

gradient descent helper for computational image reconstruction

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages