Giter Club home page Giter Club logo

Comments (5)

jeya-maria-jose avatar jeya-maria-jose commented on June 5, 2024

Hi @wcoool , "Assertion t >= 0 && t < n_classes failed" - this happens because the ground truth segmentation maps contain other pixels than 0 or 1 ( in case of binary segmentation ). So, when you use GLAS dataset, before calculating loss, you can include a couple of lines of code where you make all the pixels above 127 in the ground truth as 1 and the rest as 0. This should solve the error.

y_batch[y_batch>=127] = 1
y_batch[y_batch<127] = 0

You can also do this alternatively by running a separate code to make all the ground truth segmentation labels 0 or 1 separately initially and using the new folder of labels as the train and test path.

from kiu-net-pytorch.

wcoool avatar wcoool commented on June 5, 2024

I am very glad that you could help me solve the problem. In the paper ,you said that you set 85 images for training and 80 images for testing in GLAS dataset. However, It has validation data in this code, Could you tell my that the numbers of training images, validation images and test images which you set in GLAS dataset.

from kiu-net-pytorch.

jeya-maria-jose avatar jeya-maria-jose commented on June 5, 2024

As the number of images is very less, only train and test datasets were used for the experiments. You can just give the test dataset directory in val_dataset variable.

from kiu-net-pytorch.

wcoool avatar wcoool commented on June 5, 2024

when i use GLAS dataset. the output of the prediction the array of the image is o ,how to solve it?

from kiu-net-pytorch.

jeya-maria-jose avatar jeya-maria-jose commented on June 5, 2024

Can you please check if you have processed the data according to the Notes ( meaning background is 0 and gland segmentation is 1) because I just retrained it and seems to work for me.

from kiu-net-pytorch.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.