Giter VIP home page Giter VIP logo

Comments (6)

Vanny-Chuck avatar Vanny-Chuck commented on July 27, 2024

BigInteger might be your answer!

from chess-challenge.

Vanny-Chuck avatar Vanny-Chuck commented on July 27, 2024

#26 (comment)

from chess-challenge.

mcthouacbb avatar mcthouacbb commented on July 27, 2024

You could try packing the data into 128 bit integers and use buffer.blockcopy to convert it into the format your model uses, but other than that, there's no way to get around the limitation. You'll just have to use a smaller model or try some other method.

from chess-challenge.

BigBadE avatar BigBadE commented on July 27, 2024

For machine learning, since there is a max of 1024 tokens, the best data storage medium is 64 bits (the ways of getting around the limit have been disallowed or never worked in the first place.). The NNUE model uses 64 (king square)*64 (piece square)*5 (piece type minus king)*2 (piece color) = 40960 inputs (assuming you use the same weights for each color and rotate the board). That's 10240 64 bit values for just the inputs. You can simplify this (and weaken the model) by removing the king square, for 160 64 bit values for the input neurons. I haven't trained a model to see how good one would be with those few inputs, but in theory that's the easiest way for it to work.

Maybe it could be possible to store numbers in some other approximate form, which would be super heavy on the theory but possible for finding some sort of tradeoff of extra neurons for accuracy. Good luck if anyone tries to do this.

from chess-challenge.

Ciekce avatar Ciekce commented on July 27, 2024

The NNUE model uses 64 (king square)*64 (piece square)*5 (piece type minus king)*2 (piece color) = 40960 inputs (assuming you use the same weights for each color and rotate the board). That's 10240 64 bit values for just the inputs.

That is one way, yes, but plenty of NNUE engines (most, even) just use flat 12 pieces * 64 squares inputs, or some bucketing system with a lot fewer than 64 king buckets. Still a lot of weights, but there's absolutely no need for 64 buckets, or even any buckets at all.

from chess-challenge.

AugsEU avatar AugsEU commented on July 27, 2024

Is this really an issue with the code?

from chess-challenge.

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.