You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+47-12Lines changed: 47 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -13,27 +13,62 @@ Morphological profiling using deep learning
13
13
14
14
## Contents
15
15
16
-
This projects provide tools and APIs to manipulate high-throughput images for deep learning. The dataset tools are the only ones currently implemented.
16
+
This project provides tools and APIs to manipulate high-throughput images for deep learning. The dataset tools are the only ones currently implemented. This project only supports Python 3.
17
17
18
-
## Dataset Tools
18
+
## Tools
19
19
20
-
To prepare microscopy datasets for deep learning we have implemented the following steps that should be run sequentially: 1) Collect illumination statistics, 2) Compress images, and 3) Create cell location indices. Prior to these three steps, we need to create a metadata file with image locations and labels.
20
+
All of the following commands require the --root flag to be set to the root project directory. They also require a configuration file to be present (excluding the setup command). The commands use the following syntax:
21
21
22
-
Any of these three steps requires a configuration file written in JSON format. With this file available for a particular dataset, you can run the dataset tools as follows:
Additionally, the --config flag can be used to manually specify a configuration file not in the config directory. See the project Wiki for documentation on configuration files.
27
+
28
+
### Setting up the project directory
29
+
30
+
The project directory can be set up automatically from a specified root directory:
23
31
24
32
<pre>
25
-
python dataset --config=data.json metadata
26
-
python dataset --config=data.json illumination
27
-
python dataset --config=data.json compression
28
-
python dataset --config=data.json locations
33
+
python deepprofiler --root=[project root] setup
29
34
</pre>
30
35
31
-
These commands take some time to get your dataset ready. After that, you can launch the learning commands [under construction].
36
+
A configuration file is not necessary for this step, but you can specify one with the --config flag after deepprofiler if you want to use existing directories.
37
+
38
+
### Preparing the dataset
32
39
33
-
## Learning Tools
40
+
The dataset can be optionally preprocessed with illumination correction and compression, as specified in the configuration file, with one command:
34
41
35
-
Learn a convolutional network from single cell data using the following convention:
42
+
<pre>
43
+
python deepprofiler --root=[project root] prepare
44
+
</pre>
45
+
46
+
### Training the model
47
+
48
+
To train your model on the dataset:
36
49
37
50
<pre>
38
-
python learning --config=learn.json training
51
+
python deepprofiler --root=[project root] train
39
52
</pre>
53
+
54
+
You may optionally specify the --epoch and --seed flags after train, to set the current epoch or the random seed.
55
+
56
+
### Extracting features
57
+
58
+
To extract single-cell features for profiling:
59
+
60
+
<pre>
61
+
python deepprofiler --root=[project root] profile
62
+
</pre>
63
+
64
+
You will need to specify the name of the model checkpoint to use in the configuration file.
65
+
66
+
### Hyperparameter optimization
67
+
68
+
Optionally, you may run DeepProfiler's hyperparameter optimization feature (which uses GPyOpt) to find optimal values for your model's hyperparameters:
This may take a while as it will train a model for the number of epochs specified for each step in the process. It is recommended to decrease the epochs and steps to manageable values when running this command.
0 commit comments