INFEST for kINematic oF lESion developmenT. This plugin was used to compute the kinematic of lesion caused by the necrotrophic fungus Sclerotinia sclerotiorum. INFEST was developed for QIP (quantitative immunity in plant) @ LIPM (Lab of plant microbes interaction) in Toulouse by Adelin Barbacci. INFEST was founded by Sylvain Raffaele's ERC varywim. Feel free to use it.
For academics use please cite :
Barbacci, A., Navaud, O., Mbengue, M., Barascud, M., Godiard, L., Khafif, M., Lacaze, A., Raffaele, S., 2020 Rapid identification of an Arabidopsis NLR gene conferring susceptibility to Sclerotinia sclerotiorum using real-time automated phenotyping. Rev.
usage: infest.py [-h] [-f FIRST] [-l LAST] mpath
positional arguments:
mpath Path to the directory containing pictures
optional arguments:
-h, --help show this help message and exit
-f FIRST, --first FIRST
Number of the first picture
-l LAST, --last LAST Number of the last picture
output
analyse.txt
file created in thempath
directory containing 3 columns: the Id of leaf, the time extracted from pictures name and the size of the Lesion
python infest.py mpath -f 0 -l 400
python infest.py mpath -f 0
python infest.py mpath
usage: fit_INFEST.py [-h] [-ft FIRST] [-g] path_in path_out
positional arguments:
path_in the path to the file containing temporal data computed
by INFEST
path_out the path to the file containing LDT and Latency
optional arguments:
-h, --help show this help message and exit
-ft FIRST, --first FIRST
the first time to consider for the computation of the
LDT
-g, --graph monitoring the fit of the curve
output
txt file specified in
path_out
directory containing 9 columns: the Id of leaf, the parameters a1 to a5 resulting from the fit, the residuals of the fit, the lesion doubling time LDT, and the Latency
- Version 1 available
This version has been developed and tested under ubuntu 18.10 with python 2.7. The dependancies are:
- backports-functools-lru-cache==1.5
- cloudpickle==1.2.2
- cycler==0.10.0
- decorator==4.4.0
- kiwisolver==1.1.0
- matplotlib==2.2.4
- networkx==2.2
- numpy==1.16.5
- pillow==6.2.1
- pyparsing==2.4.2
- python-dateutil==2.8.0
- pytz==2019.3
- pywavelets==1.0.3
- scikit-image==0.14.5
- scipy==1.2.2
- six==1.12.0
- subprocess32==3.5.4
- argparse==1.1
- pandas==0.23.3
Dependancies are listed in the env_Infest.yml
file
Install conda
- Jpeg images stored in a directory and named by an integer e.g.
1.jpg
toN.jpg
corresponding to the time course. - the layout file
grid_layout.layout
in the subdirectorygrid_layout
of the directory containing pictures (e.g.my_pictures/grid_layout/grid_layout.layout
c.f. tutorial) - The layout file provide the Id and the bounding boxes of leaves e.g.
id_leaf_1\tymin\txmin\tymax\txmax\n
id_leaf_1\tymin\txmin\tymax\txmax\n
id_leaf_3\t...
with \t
a tabulation.
- manually, using git
$ git clone https://github.com/A02l01/INFEST.git
Creation of a conda environment called INFEST from the yaml file . In bash
- Check that
env_Infest.yml
file is in your working directory $ conda env create -n INFEST -f env_Infest.yml
- Initialize your shell
$ conda init bash
- To activate INFEST env:
$ conda activate INFEST
- To deactivate INFEST env:
$ conda deactivate
This tutorial was designed for linux users. It is easily transposable for macOS and Windows users by replacing most of command lines by fastidious mouse clicks.
In this short tutorial we will use INFEST to compute the kinematic of lesion development of a single detached leaf of Arabidopsis thaliana coined Col-0_154.
Data are in the data_tuto/
directory. Download and extract data with git:
$ git clone https://github.com/A02l01/tuto.git
Other kinematics can be computed by adding bounding boxes of leaves in the grid_layout.layout
file.
- Downloaded data contains yet a layout file but in the general case you must generate this file and put in the right directory
- If needed creates a directory in the pictures directory and the file
grid_layout.layout
ingrid_layout/
e.g../tuto/data_tuto/pictures/grid_layout/grid_layout.layout
. Fillgrid_layout.layout
with the coordinates of the bounding rectangles of leaves. We used ImageJ to obtain coordinates. In this example the single line added in thegrid_layout.layout
file is
Col-0_154 1410 2574 1497 2721
with:
Col-0_154
the Id of the leaf,1410
ymin of the rectangle,2574
xmin of the rectangle,1497
ymax of the rectangle,2721
xmax of the rectangle.
Items are separeted by a tabulation.
- In the directory containing infest. py file, activate conda environment (to create the INFEST conda environment please see instructions here)
$ conda activate INFEST
$ python infest.py '../tuto/data_tuto/pictures/' -f 0 -l 270
results are stored in '../tuto/data_tuto/pictures/analyse.txt'
We show that LDT is a good proxy of the level of plant resistance in Barbacci et al. 2020. Nevertheless other proxy could be derived from the kinematics computed by INFEST.
To extract the lesion doubling time (LDT) from the kinematic of lesion development using the python script fit_INFEST.py
:
$ python fit_INFEST.py '../tuto/data_tuto/pictures/analyse.txt' '../tuto/data_tuto/pictures/ldt.txt' -g -ft 400
leading to
## ### ### ##
# ### ### #
# #
# ### ### ### #
# ### ### ### #
# # # # #
## # # # ##
QiP Team LIPM Toulouse