Skip to content
Snippets Groups Projects

Vincent VDB Master Thesis


Creator: Vincent Vandenbroucke

Maintainer: Vincent Vandenbroucke (v.vdbroucke@student.uliege.be)

(Use issues when possible)

Creation date: 2021-02-22


This repository contains the entire code regarding my master thesis, excluding the data processing available in a submodule.


Contents of the repository

This repository contains a lot of different files and folders with different purposes. As a general rules, all the Python files in the main folders are meant to be used as script.

To begin with the folders:

  • segdata is a sub-repository (git submodule), it and all related information can be found at https://gitlab.uliege.be/mipi/segregostat/segdata----python
  • segmodels contains the files used to make the models themselves for the simulation. Briefly:
    • init.py is a required file for python modules.
    • contributions.py contains the different contributions that can be added to the differential equation of the model.
    • differential.py contains the Differential equations themselves, which are combinations of different contributions.
    • memory.py contains the Memory of the model; this includes the parameters and the required part of what happened in the past as well.
    • model.py contains the Model itself. A Model has a Memory and a Differential, and passes them to solve_ivp to create a solution as a Numpy array.
  • mcmc holds the base for the Metropolis-Hastings algorithm (and all Monte-Carlo methods, which for now is none) It is meant to be used with the MetroWrapper in the parent directory.

In the files, there is:

  • basic_kussel_ode.py is a basic Thattai and Van Oudenaarden or Kussel implementation, for demonstration.
  • explore.py and explore_obsolete.py are just wrappers to make a bunch of interesting graphs based on the data refered to in file_list.py.
  • file_list.py holds two lists of files, one is the current data from the segregostat/chemostat, the other is a list of files for the same experiments that were mis-calibrated or otherwise bad (the obsolete list).
  • The MetroWrapper is meant as a wrapper around the data and the models, that should let them be compared for use in the Metropolis-Hastings algorithm.
  • presentation_graphs is just a small script to make graphs from the data, for presentations.
  • quality_check is the failed script that was used to check whether the data was reasonably clean
  • scatter and scatter_obsolete are simple scripts to make scatter plots of the different datasets, with time sliders.
  • symbolyc_ODE.py, symbolyc_ODE_result.txt and symbolyc_ODE_result_treat.txt are results of symbolic calculations to solve the linearized Kussel system, treated to be a bit more readable. The Python file actually makes the calculations, while the two text files contain copies of the answers (which is necessary because they are very long).
  • test_model is a simple test for the model, making sure the files in segmodels work as expected.
  • testing_PCA is a script testing different things with a PCA analysis, it can show that using fluorescence/size is more indicative than fluorescence alone.
  • testing contains various tests that were made on the data
  • The metropolis, metropolis_chemostat, and metropolis_segregostat files are the ones that were run for the results of the master thesis.
  • All the results_metropolis*.py and TFE_plots*.py files were the ones used to prodused the plots found in the results and figures folders.

Install the repository

  • Make sure you have the required packages first:

    • Numpy
    • Matplotlib
    • Scipy
    • Tensorflow
    • Sympy for the symbolic calculation file
    • Sklearn for the PCA analysis
    • Pandas for segdata
    • fcsparser to read the segregostat data
  • Clone or download this repository

  • Clone the segdata repository

  • Rename it segdata

  • Add it to your Python path or put it in this repo (see the segdata repo for full instructions TODO)

Introduction to the repository

Describe the basic usage of the code in the repository, with a few examples. This is not the full documentation, more a general introduction and a cheatsheet

A full documentation is available in the documentation file.

If it makes sense, the full documentation may be somewhere else

random notes

test_metropolis.py

The memory required by the results is mostly negligible compared to the memory of the models, at least at first.