Giter Club home page Giter Club logo

Comments (5)

kochsebastian avatar kochsebastian commented on June 2, 2024

I'm not that fond of mss. For me it's also sometime throws weird bugs. Forcing int's sound like a good idea. Maybe the chessboard detection also detects the region or something is wrong with the coordinate scaling etc.
What you could also consider is to switch to pyautogui screenshots instead. This is a little slower, but still fast.

from chessvisionbot.

rokopi avatar rokopi commented on June 2, 2024

Thank you for your response.

I've noticed that if I manually identify the chessboard coordinates, force them to be int, and set all the scaling factors to 1, the rest of the program, including mss, functions as I expected (or maybe even better than I expected!). I've made a few slight adjustments to have better control of the engine strength, but overall I am very thrilled with the quality of this program.

I'm still unable to get the "find chessboard from image" functions to work on full screenshots though, unfortunately. They still select the above image as a chessboard (this pic was the resized_chessboard variable). I have to admit that the ML methodology for chessboard location identification is a bit beyond me.

from chessvisionbot.

kochsebastian avatar kochsebastian commented on June 2, 2024

Finding the chessboard is actually not an ML algorithm but an optimization algorithm. It looks for a description of the chessboard which looks for the most coherent description of the chessboard.
But in the chessboard detection file should also be some legacy code which just looks for 64 squares and then calculates the convex hull. This is an inferior approach, but maybe it's more stable for you

from chessvisionbot.

kochsebastian avatar kochsebastian commented on June 2, 2024

PR's with improvements are also always welcome!

from chessvisionbot.

rokopi avatar rokopi commented on June 2, 2024

Thank you. I've been busy recently, but will try to make some PRs soon.

With the help of your iPython notebook, I think I found the problem with chessboard identification. If the chessboard is too small, the hough gradient Y is very weak. Interestingly, this is not a problem with the hough gradient X. I wonder what the issue is here.

hough_gradients

from chessvisionbot.

Related Issues (15)

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.