3b1b / videos

Code for the manim-generated scenes used in 3blue1brown videos
5.79k stars 1.55k forks source link

[QUESTION/HELP] - Wordle Solver #29

Closed therealOri closed 2 years ago

therealOri commented 2 years ago

I can't for the life of me figure out how to run and use/play with the wordle solver..Nothing here is understandable nor do I know what to do, what goes where, what to install, what to edit, what file to run, what commands to execute, etc...

The "wordle.py" file and it's related stuff is non existent now. Like it got deleted overnight. For idk what reason.. (Idk what file to run.)

A very simple step by step guide would be greatly appreciated for this difficult, confusing and mountainous mess of a repository.

Any help on how to get the wordle solver to run, such as commands and where to run said commands is what I'm looking for. (I'd ask this in a discussions area but that isn't enabled in this repo.)

God, the more I look at this repo, the code, and trying to figure out how anything works..the more confused and I get xD

therealOri commented 2 years ago

@3b1b

Any advice or help?

3b1b commented 2 years ago

Can you share more details on what happens if you go into the _2022/wordle/ folder and run "python simulations.py"?

To run the scenes from _2022/wordle/scenes.py, you'll have to have manim properly set up.

therealOri commented 2 years ago

@3b1b

Can you share more details on what happens if you go into the _2022/wordle/ folder and run "python simulations.py"?

To run the scenes from _2022/wordle/scenes.py, you'll have to have manim properly set up.



I get the following error:

Traceback (most recent call last):
  File "/home/ori/Desktop/videos/_2022/wordle/simulations.py", line 1, in <module>
    from manim_imports_ext import *
ModuleNotFoundError: No module named 'manim_imports_ext'

If I move manim_imports_ext and the custom folder (idk if it's needed) into the folder with simulations.py it'll start running and going through its games.

What do I do after it finishes? Like..what command(s) should I run and from where should they be ran? (I should also mention that I am in a virtual python environment.)

therealOri commented 2 years ago

After simulations.py finishes, I get the following error:

Traceback (most recent call last):                                                                       
  File "/home/ori/Desktop/videos/_2022/wordle/simulations.py", line 805, in <module>
    results, decision_map = simulate_games(
  File "/home/ori/Desktop/videos/_2022/wordle/simulations.py", line 796, in simulate_games
    path = os.path.join(get_directories()["data"], "wordle", file)
KeyError: 'data'
ItzMiracleOwO commented 2 years ago

I tried adding the manim_imports_ext into the path Now the command python scenes.py gives no output :/ @3b1b

image

ItzMiracleOwO commented 2 years ago

Oh image

ItzMiracleOwO commented 2 years ago

Oh image

Forget about that. it just completed. And python scenes.py still no output @3b1b

therealOri commented 2 years ago

@3b1b

I have found a way to get the .json files from running python simulations.py.

I do not know where those files should actually be as I just made the script output them in the "wordle" directory/folder. I don't know if they need to be moved somewhere else or kept there.

Also, I don't know what command(s) to run next or what to do in the python shell that is started after simulations.py finishes. If you could let me know what to do next or if you have any more advice/input on how to actually run the wordle solver then It'd be very appreciated.

therealOri commented 2 years ago

Anyone know how to run wordle?

ItzMiracleOwO commented 2 years ago

It's still a mystery

3b1b commented 2 years ago

You may want to look at https://github.com/3b1b/videos/issues/28

Also, I don't know what command(s) to run next or what to do in the python shell that is started after simulations.py finishes.

The simulations.py file just contains a lot of helper functions to run the Worlde-solving algorithm, and when you run it as a script all it is meant to do is run a simulation of all the games for a given configuration, depending on what you put into the if __name__ = "__main section.

The scenes themselves, with interactive demos etc., are part of the scenes.py folder, and need to be run with manimgl. You can find details on installing manimgl in its github page

In general, the code posted to this repo is rather scrappy. I put it here because people are curious to see what's behind the videos, but it may not always be the most friendly to actively work with.