Giter Site home page Giter Site logo

fcup-vc's Introduction

Rubik's Cube Solver

We develop a Rubik’s cube solver that uses computer vision techniques to detect and analyze the colors on each face of the cube and then generate a sequence of moves to solve it.

Installation

Python 3 must be installed, and the following libraries are required:

How to run

python3 main.py

How to use

  • Run the script, and it will initialize the camera to capture the Rubik's cube.

  • Hold the Rubik's cube in front of the camera and click on a square of each color in the requested order using the mouse.

  • Following that, ensure that each face is detected and highlighted in this order and orientation:

    Face Detection Face Detection
    1. Begin with any side facing the camera (U 1).
    2. Show the face on your left (R 2);
    3. Show the front face (F 3);
    4. Show the bottom face (D 4);
    5. Show the right face (L 5);
    6. Finally, show the back face (B 6).
  • Once all six faces are detected, the solution will be displayed, and the steps to solve the Rubik's cube will be shown in real time. You have to show the F face in the orientation you showed before for the solution to be shown correctly. You must first show the F face in the correct orientation so that the solution is presented correctly.

  • If you've done the steps above correctly, you should have your cube solved.

Troubleshooting

  • If the camera is not detected or the script encounters any issues, check the camera connection and make sure the required libraries are installed.

  • If the cube is not detected and highlighted, you will probably need to re-run the calibration process or change the Lab color ranges in main.py in the showPixelValue function.

fcup-vc's People

Contributors

danielatomas avatar icweiner avatar

Watchers

 avatar

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.