Closed mrzhangzizhen123 closed 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!
Can this code be used for the 5 classification of diabetic retinopathy?
No, only binary (0,1) classification in this code.
Professor, is there any point in studying this dichotomy?Is it easier to get results in the five categories
I want to improve on your code, but there are a lot of difficulties.
Professor, one more question, why is the test folder in the log folder under TMP empty after training
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.
Professor, after training, why is the test folder in the log folder under TMP empty
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...
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-?.