Team:TU Darmstadt/Software

Software HoloPyGuy

Here, we present an universal software solution which we, the team iGEM TU Darmstadt, created for digital inline holographic microscopy (DIHM).
We therefore employ the open-source framework Holopy and extended the existing solution with a graphical user interface.
The resulting software includes the connection to a raspberry pi cam as well as a control element for a commonly used blue-ray laser.
The graphical user interface relies on the Qt5 framework and is written in Python. The solution
aims to be applicable for self-made DIHM and an ‘easy-to-use‘ hologram reconstruction suite. The project is hosted on GitHub under MIT License
and is also available for download. A complete user manual is provided in the following section.

HoloPyGuy - An Introduction

First, a reference picture, taken without a sample, needs to be provided in order to analyze a hologram. These reference pictures can be imported by choosing the panel ‘Open Background’.
Several background pictures, which are turned into one averaged hologram, is subtracted from the sample hologram, which can
be imported via the panel ‘Load Sample’.
A dark field image can be generated by taking a picture without laser light if you are concerned about residual light in your setup, but it is not obligatory for each setup. The settings for
reconstruction are controlled using the Boxes on the left. Reconstructing a hologram
can be easily accomplished by choosing the panel ‘Hologram’. The single settings provided will be further explained
in the section ‘controls’. The algorithm used for reconstruction is applicable for light coming from point sources only.

At first, a picture of the beam without sample serves as reference (left). A raw hologram has fringes around the objects of interest (middle). The reconstructed object is calculated
by substracting the reference picture from the raw hologram and then analyzed with reverse propagation.

Settings

All lengths are internal converted to meters. The preset values are corresponding to
our DIHM setup.

Parameters

Description

Distance

The distance between cam to light source in mm

Z min

Smallest distance from camera to calculate wavefronts

Z max

Greatest distance from camera to object of interest

Z steps

Number of calculate distances between Z min and Z max

Pixel out

Size of squared hologram reconstruction. Decrease for smaller resolution but shorter computational time

Distance between the center of two pixels. We show how to calculate it for our photosensor.

Download and further documentation

We provide the entire software as it is. You can get a copy of our repository by installing git and run in a terminal:
git clone https://www.github.com/iGEMDarmstadt/holopyguy.git
To set it up for running, we follow the getting started section from holopy. If you use a unix based operating system, please run the following lines in command-line:
sudo apt install condaconda install -c conda-forge holopy

That should set up the production branch of HoloPy. For Windows, the installation process is quite similar. Install Anaconda3 for your OS. Be aware that if you let the box checked in the installer, Anaconda overwirtes the default python interpreter. Then, run the following commands in the anaconda prompt:
anaconda search holopyanaconda show ralex0/holopyconda install -c conda-forge emceeconda install -c conda-forge h5netcdfconda install --channel https://conda.anaconda.org/ralex0 holopy
Install hologuy requirements (a converter from QImage to NdArray)conda install -c conda-forge qimage2ndarray
Download the latest version from hologuy and extract the filespython hologuy.py