Giter VIP home page Giter VIP logo

Comments (5)

pvoigtlaender avatar pvoigtlaender commented on July 17, 2024

Hi,

I think that the cost is not supposed to become negative, not sure why this happens.
It could be that this points to a problem, or maybe it's just some unimportant thing like a wrong scale of the loss values.
Considering that the accuracy still increases, it might be that it will just work fine. It would be good if you can try to make a recognition with this model, and see if it works as usual.

from returnn.

albertz avatar albertz commented on July 17, 2024

What loss is that? Depending on the loss, it sure can become negative. For example, I think the CTC loss can become negative.

from returnn.

sharmaannapurna avatar sharmaannapurna commented on July 17, 2024

Its CTC loss that I am using. I have not made any changes to the loss function (using the same as given with returnn library). I will update the final results once the training stops...So far accuracy improving continuously(surprising!) and loss going more negative.

from returnn.

pvoigtlaender avatar pvoigtlaender commented on July 17, 2024

The CTC loss (Eq. 12 in ftp://ftp.idsia.ch/pub/juergen/icml2006.pdf ) cannot become negative: each summand is ln(p), where 0 <= p <= 1 which means that -infty <= ln(p) <= 0 which means the negative sum cannot become negative in theory. Don't know why it's happening here anyway, could be a bug. First let's see if you get good results anyway.

from returnn.

sharmaannapurna avatar sharmaannapurna commented on July 17, 2024

Hello, Thanks for the reply. I figures out that there was one character with single instance in the dataset. I guess, this was causing trouble. Once I remove that line image and took the revised character set, it is giving the desired behavior. I didnt expect the super-high imbalance in classes can result in such a disaster :(

Thanks!

from returnn.

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.