Journals

Last updated: November 13th, 2019

Journals

Image analysis workflows to identify objects are configured inside journals, human readable text files configuring input/output folders, the sequence of LOBSTER functions to apply to each input image and their associated parameters. Journals can be launched from LOBSTER Panel, or by typing JENI in the console. There are 3 kinds of journals: 2D images (.jl), 3D images (.jls) and 2D/3D time-lapses (.jm).

2D journals are flexible to handle multiple channels and perform image quality check prior to processing (skip bad images), which is often useful for large scale automated acquisition. 3D journals are designed to process large images, and offer multiple exploration and visualization options. Time-lapse journals are designed to process images by pair of consecutive time points, mainly for object tracking. These specificities are reflected by a slightly different syntax and configuration options.

In the following section we focus on 2D journals, please refer to LOBSTER documentation, section Dissecting a 3D journal and section Dissecting a 2D/3D time-lapse journal for complementary information.

For every input image, LOBSTER applies a sequence of image processing functions (workflows) to identify objects. LOBSTER functions are stored in LOBSTER /Code/_Functions folder. You do not need to know much about the internals of LOBSTER functions but it is important to understand that they have a standard interface with associated parameters, and that they transform one or several input images into one or several output images of same size.

Let’s inspect the journal file 'Tissue_SegWaterTiles.jl'.

InputFolder = './Images/Tissue/';
OutputFolder = './Results/Images/Tissue/';

@iA = '*.tif';

@fxg_mWaterTiles [iA] > [M];
params.GRad = 4;
params.ExtendedMinThr = 5;
/endf

/show iA > M;
/keep M > tif;

Configuration

The first two lines of a journal are compulsory, they set paths to input and output image folders. Paths can be absolute (e.g. 'E:/LOBSTER') or relative to LOBSTER installation folder (starts by ./).

Images are sequentially processed from input folder: @iA declares the current input image (now on iA in the journal) and associates it to an image filter. In this example, the filter configures JENI to exclusively process TIFF files from the input folder. The character * is a wildcard (replaces any string in file name).

LOBSTER Functions

LOBSTER functions are called in the order they appear in a journal; they are identified by the special character @f, for instance: @fxg_mWaterTiles [iA] > [M] calls the function fxg_mWaterTiles transforming input image iA into image M. Function arguments can be either input image variables (here iA) or temporary images (here M). Function parameters are configured in the structure params and the function declaration ends by /endf.

Right clicking on the function fxg_mWaterTiles in MATLAB script editor and selecting Help on Selection brings this window:

screenshot

The input images are first Gaussian blured to mitigate noise (the strength of the filter is set by the parameter GRad), and objects are segmented into tiles (hopefully a single tile per object). The tile detection tolerance is set by the parameter ExtendedMinThr.

Image View/Export

To display every input image iA and overlay the resulting object mask M:

/show iA > M

To exporting object mask M to output folder:

/keep M > tif

Sequencing Functions

Multiple functions can be sequenced to achieve more complex operations, such as in the sample journal /Journals/'NucleiCytoo_GradWaterTilesMerge.jl'.

InputFolder = './Images/NucleiCytoo/';
OutputFolder = './Results/Images/NucleiCytoo/';
Fill = 1;
Lbl = 1;

@iA = '*C00*.tif';

@fxg_mGradWaterTiles [iA] > [L];
params.GaussianRadInt = 2;
params.ExtendedMinThr = 1.8;
/endf

@fxm_lTilesMerge [L, iA] > [L2];
params.GaussianRad = 2;
params.MinObjArea = 175;
...
/endf

/show iA > L2;
/keep L2 > tif;

Here, the first function is the same as before and the second attempts to merge these regions into concave bright particles.

The first function transforms input image iA (input image) into image L.

The second function tranforms image L and input image iA into image L2.

The input image filter configures than only TIFF files containing the text string ‘C00’ are processed; this is required to process a specific channel when images from several channels are mixed in the same folder.

Finally, lines 3 and 4 set options to alter the display of the results. The use of these settings is demonstrated in this video. See LOBSTER cheat sheet for more information.