DebeshJha / 2020-CBMS-DoubleU-Net

Official implementation of DoubleU-Net for Semantic Image Segmentation in TensorFlow & Pytorch (Nominated for Best Paper Award (IEEE CBMS))
https://arxiv.org/pdf/2006.04868.pdf
237 stars 69 forks source link

Image pre-processing #4

Closed YassineElbouchaibi closed 4 years ago

YassineElbouchaibi commented 4 years ago

Hey,

Sorry to ask such a silly question but could you help me with my images pre-processing to use your model and weights

Here is what I did :

  1. I downloaded the CVC-ClinicDB dataset. (images and masks are in tiff format)
  2. I cloned your repo and added your weights to ./files/
  3. I changed your data.py -> main() to the following :

    def main():
    np.random.seed(42)
    path = "../CVC-ClinicDB/"
    test_x = glob(os.path.join(path, "Original/*"))
    test_y = glob(os.path.join(path, "Ground Truth/*"))
    
    create_dir("new_data/test/image/")
    create_dir("new_data/test/mask/")
    
    augment_data(test_x, test_y, "new_data/test/", augment=False)

    At this point I had 2 folders with images in JPEG (.jpg) format but when I run the prediction, I get results like this : 43_0 73_0

When I do the same with ETIS-LaribPolypDB dataset, I get results like these : 7_0 30_0

Do you know what I'm doing wrong? Do you have any code examples to process an image and run a prediction? Or do you have a pre-processed image dataset?

FYI: I'm working on a school project where I want to use your model and weights as a backend and build a web gui to run predictions and have some cool gui features

YassineElbouchaibi commented 4 years ago

Ah, I believe this is because I used the weights for the Lesion Boundary challenge... Would you have weights for MICCAI 2015 Segmentation challenge ?

DebeshJha commented 4 years ago

@YassineElbouchaibi

I have now uploaded the weight file for the CVC-ClinicDB (2015 MICCAI sub-challenge on automatic polyp detection dataset). For the (2015 MICCAI sub-challenge on automatic polyp detection dataset), please test with the ETIS-Larib Dataset. 2015 MICCAI sub-challenge on automatic polyp detection dataset

All the best for your project!

Best regards, Debesh Jha

YassineElbouchaibi commented 4 years ago

@DebeshJha Thanks!! You're amazing!

YassineElbouchaibi commented 3 years ago

@DebeshJha Hey just wanted to give you an update on my school project if you wanted to see the outcome. Its now done. It was made possible by the awesome work you had done here! You can check out a demo here : https://medica-vue.netlify.app/

And the source code here :

I made sure to mention your projet in the about/credits section of the website!

Thank you!