Giter VIP home page Giter VIP logo

Comments (4)

juntang-zhuang avatar juntang-zhuang commented on August 28, 2024 1

You can not simply use the pretrained weights, because class definition is totally different for your dataset. The dataloader and dataset class is highly customized for different datasets, you'll definitely need to re-write your own. Perhaps simply changing the number of classes and putting 255 for the rest will fail.

from shelfnet.

juntang-zhuang avatar juntang-zhuang commented on August 28, 2024

When you get nan, clearly something very weird happens. I suggest checking your dataloader and class definition etc first. Seems not a problem with the network, I guess it's the problem with data (e.g. dataloader). Even a quite simple FCN should not generate this type of results.
I'm sorry I might not be able to provide further help, since you are dealing with a private dataset, and I have stopped segmentation projects long time ago.

from shelfnet.

poornimajd avatar poornimajd commented on August 28, 2024

Thank you for the reply.
I did not change the dataloader ,I just used the Indian Driving Dataset images in place of cityscape dataset.
I will look into it.
My only question which remains is that in my case I have only 4 classes,so either I should change the number of classes in the network,but then I doubt if I can use the pretrained weights(because it is trained on 19 classes),or the other hack which I did was to put 255 as the id for all the classes which I need to ignore.
basically I am not sure how to handle different number of classes and classes which the model is not trained on.
Any suggestion is appreciated.

I'm sorry I might not be able to provide further help, since you are dealing with a private dataset, and I have stopped segmentation projects long time ago.

I get it.
Thank you

from shelfnet.

poornimajd avatar poornimajd commented on August 28, 2024

Thanks for the reply!.
I have arranged my data in cityscapes format and hence the dataloader will remain the same right.But I changed the cityscape_config.json to the ids expected by the Indian Driving Dataset.I used 19 classes only this time and using the pretrained weights I still get nan.I expected that after training for a few iterations at least the model should be able to adapt to the new dataset.Most of the classes of the dataset which I am using are the same as that of cityscape,except 2 new classes.But the total number of classes still remains as 19.

from shelfnet.

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.