Skip to content

MoMA configuration file

Michael Mell edited this page Sep 24, 2023 · 4 revisions

WARNING: THIS IS A DRAFT VERSION. IT IS NOT YET READY FOR USE.

  • TODO: merge this with MoMA-Properties-New.md

Introduction

This page explains how to configure MoMA.

The mm.properties config file

MoMA settings are stored within a single configuration file. By default MoMA uses the configuration file located at:

$HOME/.moma/mm.properties

This file will be used, when the user does not specify a configuration file, e.g. when running:

moma -i /path/to/intput/image.tiff

Users can specify a specific configuration file using the option `-p CONFIG_FILE`:

moma -p /path/to/other/mm.properties -i /path/to/intput/image.tiff

Obtaining the mm.properties file used for an analysis

In general, it is advisable to create a configuration file specifically for your analysis and to use it with the option `-o`. This ensures that you are using the correct setting for your analysis and also allows you to keep a copy of mm.properties for later reference and to continue the analysis, if needed.

Furthermore, MoMA creates a copy of the `mm.properties` file in the export folder during export. This copy is used, when reloading the curation state of a GL, and can also be used to continue the analysis of the experiment or similar data.

Explanation of individual settings

This section explains the setting in mm.properties in detail. I categorize the settings conceptually in setting that affect:

  • graphical user interface (GUI)
  • generation of components/segmentation
  • generation and optimization of the tracking problem
  • exporting the results

The default config file for MoMA is shown below (template). It lies in the directory `.moma` in home folder of the user.

import_path=/scicore/home/nimwegen/GROUP/MM_Data/Theo/20210428/preprocess/20210428_Theo_process_positions__output__20210503-161334/Pos21/Pos21_GL17/20210428_glc_spcm_1_MMStack_Pos21_GL17.tiff   

GUI_NUMBER_OF_SHOWN_TIMESTEPS=23
GUI_SHOW_GROUND_TRUTH_EXPORT_FUNCTIONALITY=0

SEGMENTATION_MODEL_PATH=/scicore/home/nimwegen/GROUP/Moma/MM_Artifacts/unet_models/model_20210715_5b27d7aa/current_tensorflow_model.zip
CELL_DETECTION_ROI_OFFSET_TOP=120
THRESHOLD_FOR_COMPONENT_GENERATION=0.5
THRESHOLD_FOR_COMPONENT_SPLITTING=1.0
THRESHOLD_FOR_COMPONENT_MERGING=0.5
MAXIMUM_DOWNWARD_MOVEMENT=50

GUROBI_TIME_LIMIT=15.0
GUROBI_MAX_OPTIMALITY_GAP=0.99
ASSIGNMENT_COST_CUTOFF=2.0
LYSIS_ASSIGNMENT_COST=10.0
MAXIMUM_GROWTH_RATE=1.5
GL_OFFSET_TOP=-1000

CELL_LABELS=dead;dying;fading;shrinking;dividing
EXPORT_ASSIGNMENT_COSTS=0
EXPORT_SPINE_MEASUREMENT=0
EXPORT_ORIENTED_BOUNDING_BOX_MEASUREMENT=1
SPINE_MEASUREMENT_MEDIALLINE_OFFSET_FROM_CONTOUR_ENDS=3.5
SPINE_MEASUREMENT_ENDPOINT_ORIENTATION_AVERAGING_WINDOWSIZE=5
SPINE_MEASUREMENT_POSITION_AVERAGING_MAXIMUM_WINDOWSIZE=21
SPINE_MEASUREMENT_POSITION_AVERAGING_MINIMUM_WINDOWSIZE=5
INTENSITY_FIT_RANGE_IN_PIXELS=100
INTENSITY_FIT_ITERATIONS=500
INTENSITY_FIT_PRECISION=0.001
INTENSITY_FIT_INITIAL_WIDTH=5.5


OPTIMISATION_INTERVAL_LENGTH=-1
GUI_CONSOLE_WIDTH=600
GUI_POS_Y=24
GUI_POS_X=0
GUI_HEIGHT=1056
GL_WIDTH_IN_PIXELS=20
GUI_WIDTH=1920
DEFAULT_PATH=/home/micha
GUI_OPTIMIZE_ON_ILP_CHANGE=0

I categorize the settings conceptually in setting that affect:

  • graphical user interface (GUI)
  • generation of components/segmentation
  • generation and optimization of the tracking problem
  • exporting the results

Explanation:

  • graphical user interface:
    • GUI_NUMBER_OF_SHOWN_TIMESTEPS []
    • GUI_OPTIMIZE_ON_ILP_CHANGE: Controls if optimization will be performed on each user-modification during curation.
  • GUROBI_TIME_LIMIT: Time limit for the tracking optimization.
  • EXPORT_ASSIGNMENT_COSTS: Controls if assignment costs should be exported. This is a developer option and should not be modified.
  • THRESHOLD_FOR_COMPONENT_SPLITTING: Sets an upper threshold for component generation. Pixel probabilities above this threshold will be set to 1. Reducing this below 1 can avoid the generation of spurious child components and thus reduce the depth of the component tree, which is particularly useful for dataset with filamenting cells. However, setting this value too low can create issues, when correct child components are not generated. A good initial value is >0.99 when using this option.
  • SPINE_MEASUREMENT_POSITION_AVERAGING_MINIMUM_WINDOWSIZE: Minimum windows size for the window averaging the medial line positions in the calculation of the spine-length measurement.
  • SPINE_MEASUREMENT_POSITION_AVERAGING_MAXIMUM_WINDOWSIZE: Maximum windows size for the window averaging the medial line positions in the calculation of the spine-length measurement.
  • SPINE_MEASUREMENT_MEDIALLINE_OFFSET_FROM_CONTOUR_ENDS: Minimal distance between the end of the medial line and the cell contour at either end of the cell.
  • THRESHOLD_FOR_COMPONENT_GENERATION [0.5; DO NOT CHANGE]: The threshold that is used to generate components.  This value should not be changed from the default of .5, because it affects the measured cell-area/-size.
  • MAXIMUM_DOWNWARD_MOVEMENT: (added in version v0.9.3) This parameter sets by how many pixel a cell is allowed to move downwards. Assignments with a position difference larger than this (between source and target) will not be considered. The unit pixels. If the parameter is not set in the config-file, it will default to 50.