cvdlab / nn-segmentation-for-lar

Neural networks to segment some type of biomedical images
21 stars 15 forks source link

The accuracy of the training phase is very low #7

Closed tiantian-li closed 6 years ago

tiantian-li commented 6 years ago

I'm running the training phase of the code brain_tumor_segmentation_models.py,but i find the accuracy is very low,at about 0.2. I run the code with python2.7,and I have increased the number of patches to 100000 with augmentation. I guess the problem might be caused by labels,because the labels of the "more" file I got are all black, but i don't know the reason.How should i do to increase the accuracy? Could you please help me to solve the problem?Thanks

Cesarec88 commented 6 years ago

In the patch_library.py file you can handle the number of zero to extract by modifying the function find_patches at line 81, qith something like this: if patch.shape != (4, h, w) or len(np.argwhere(patch == 0)) > (2 * h * w): if class_num == 0 and patch.shape == (4, h, w) and len(np.argwhere(patch == 0)) < (3 * h * w): pass else: continue

That should prevent the code from extracting null patches,

up to you to decide how much plain it should be

The article was using an overall of patches between 150000 and 300000.

You can try byt augmenting with an angle of 90° , 60'000 patches i.e. 240'000 patches