Git Product home page Git Product logo

Comments (5)

sangwoomo avatar sangwoomo commented on June 6, 2024

Hi, it seems that the code fails to read the mask. You'd better to check for which image/mask the code fails to read exactly, e.g., by printing the ID of the image before the failure.
#5 (comment)

from instagan.

bsahil29 avatar bsahil29 commented on June 6, 2024

Yeah it worked. There was an issue with reading some of the masks. Thanks! :)

from instagan.

kalai2033 avatar kalai2033 commented on June 6, 2024

Hi @sangwoomo and @bsahil29 I face the same issue...

I have printed the seg_paths ... Every time it breaks at random point. But i have corresponding mask images in both the train and train_seg folder with same name and same dimensions. I cant understand why it fails.

Can you please help me fix it?

from instagan.

sangwoomo avatar sangwoomo commented on June 6, 2024

I'm sorry but I have no idea since I had never encountered this problem.
Can you simply remove the problematic index?

from instagan.

jdunkelheit avatar jdunkelheit commented on June 6, 2024

In addition to missing masks, this issue can also happen when the masks have a wrong name. The mask cannot simply have the exact same name as the image.
Make sure the name of the masks is composed of "image name" + "_0". For example:

    ├── trainA
        ├── 1.png
        ├── 2.png
        └── ...
    ├── trainA_seg
        ├── 1_0.png
        ├── 2_0.png
        └── ...
    ├── trainB
        ├── 1.png
        ├── 2.png
        └── ...
    ├── trainB_seg
        ├── 1_0.png
        ├── 2_0.png
        └── ...

In case you have more than one mask for the same image, it will be like:

    ├── trainA
        ├── 1.png
        ├── 2.png
        └── ...
    ├── trainA_seg
        ├── 1_0.png
        ├── 1_1.png
        ├── 2_0.png
        ├── 2_1.png
        └── ...
    ├── trainB
        ├── 1.png
        ├── 2.png
        └── ...
    ├── trainB_seg
        ├── 1_0.png
        ├── 1_1.png
        ├── 2_0.png
        ├── 2_1.png
        └── ...

from instagan.

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.