https://github.com/pravj/semantris-solver
Automated solver for Semantris using OpenCV and Word Embeddings
https://github.com/pravj/semantris-solver
google-experiment hack ocr opencv semantris tesseract word-embedding word2vec
Last synced: 3 days ago
JSON representation
Automated solver for Semantris using OpenCV and Word Embeddings
- Host: GitHub
- URL: https://github.com/pravj/semantris-solver
- Owner: pravj
- Created: 2018-09-29T07:51:44.000Z (about 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-08T02:54:57.000Z (almost 3 years ago)
- Last Synced: 2025-03-30T07:17:56.574Z (7 months ago)
- Topics: google-experiment, hack, ocr, opencv, semantris, tesseract, word-embedding, word2vec
- Language: Jupyter Notebook
- Homepage: https://hackpravj.com/blog/solving-semantris-opencv-word2vec/
- Size: 281 KB
- Stars: 15
- Watchers: 2
- Forks: 2
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
semantris-solver
================
> Automated solver for [Semantris](https://research.google.com/semantris/) using OpenCV and Word Embeddings---
#### Setup
###### Clone the repository
```
git clone git@github.com:pravj/semantris-solver.git
```###### Setup Python environment with the required packages
```
pip install -r requirements.txt
```###### Setup OpenCV and Tesseract
- Install OpenCV and Tesseract for your OS###### Setup word embeddings
- Download [pre-trained word2vec](https://github.com/mmihaltz/word2vec-GoogleNews-vectors) from Google News corpus
- Set the model path as an environment variable *SEMANTRIS_SOLVER_WORD2VEC_PATH*
```
export SEMANTRIS_SOLVER_WORD2VEC_PATH=/path/to/GoogleNews-vectors-negative300.bin
```---
#### Usage
```
Semantris SolverUsage:
main.py play [--mode=] [--verbose]
main.py (-h | --help)
main.py --versionOptions:
-h --help Show this screen
--version Show version
--verbose Print game activity logs
--mode= Semantris game mode [default: arcade]
```- For now it only supports the `arcade` mode of the game.
- Using the `--verbose` flag will enable the verbose logging configuration.
```
python main.py play --mode=arcade --verbose
```
- It will take 5-10 minutes to load the word embedding model
- Start the `arcade` version (in `blue` color theme) of the game in a full screen mode
- Put the cursor in the game input field for the system to enter the suggestions
- Wait for the ~~magic~~ model to load :tada:---
#### Arcade mode
[](https://www.youtube.com/watch?v=E8QSteLOuns)
---
[Pravendra Singh](https://hackpravj.com)