mikevoets / jama16-retina-replication

JAMA 2016; 316(22) Replication Study
https://doi.org/10.1371/journal.pone.0217541
MIT License
110 stars 37 forks source link

about #13

Closed mrzhangzizhen123 closed 5 years ago

mrzhangzizhen123 commented 5 years ago

I don't understand what needs to be done to prepare for the integrated network. Could you explain it in detail?

To create an ensemble of networks and evaluate the linear average of predictions, use the -lm parameter. To specify multiple models to evaluate as an ensemble, the model paths should be comma-separated or satisfy a regular expression. For example: -lm=./tmp/model-1,./tmp/model-2,./tmp/model-3 or -lm=./tmp/model-?.

mikevoets commented 5 years ago

To create an ensemble, you will need to train a couple of models and save the models to files, for example:

For the first model: python train.py -sm=./tmp/model-1 Second model: python train.py -sm=./tmp/model-2 And so forth...

Then you can evaluate a single model, for example model-1 on Messidor-2 with: python evaluate.py -m2 -lm=./tmp/model-1.

To create an ensemble network (re integrated network) with all your trained models, use the comma delimiter in the -lm parameter: python evaluate.py -m2 -lm=./tmp/model-1,./tmp/model-2.

Then the output from the evaluate.py script should contain something like this:

Numpy version: 1.16.4
Tensorflow version: 1.13.1

Evaluating: ./data/eyepacs/bin2/test,
Saving operating thresholds metrics at: ./tmp/test_op_pts.csv,
Using operating treshold: 0.5,

Trying to load model(s):
./tmp/model-1
./tmp/model-2
...

Hope this helps you!

mrzhangzizhen123 commented 5 years ago

Can this code be used for the 5 classification of diabetic retinopathy?

mikevoets commented 5 years ago

No, only binary (0,1) classification in this code.

mrzhangzizhen123 commented 5 years ago

Professor, is there any point in studying this dichotomy?Is it easier to get results in the five categories

mrzhangzizhen123 commented 5 years ago

I want to improve on your code, but there are a lot of difficulties.

mrzhangzizhen123 commented 5 years ago

Professor, one more question, why is the test folder in the log folder under TMP empty after training

mikevoets commented 5 years ago

The significance of this study is to show that reproducing deep learning method results is challenging when you do not have access to the original data and source code. This study is not about getting the best performing network to classify diabetic retinopathy.

Which folder do you mean? Please show 1) the exact commands you have run, 2) expected output, and 3) the actual output or error message.

mrzhangzizhen123 commented 5 years ago

Professor, after training, why is the test folder in the log folder under TMP empty

mikevoets commented 5 years ago

I'm not a professor by the way :-)

It'll be difficult to help you without knowing the exact command and what exact parameters you used...