Code Monkey home page Code Monkey logo

mtg-aws-ocr's Introduction

mtg-aws-ocr

Small python3 project to recognize Magic The Gathering (MTG) cards from pictures taken, and lookup their prices on the market.

APIs used

How to use it

Clone the repo

$ git clone https://github.com/seriously24/mtg-aws-ocr
$ cd mtg-aws-ocr

Install python dependencies

$ pip install -r requirements.txt

Check that aws is correctly running and configured for your AWS account

$ aws configure
AWS Access Key ID [********************]:
AWS Secret Access Key [********************]:
Default region name [eu-west-1]:
Default output format [None]:

Init the sqlite3 database

$ python database.py -init

Run the main script, either for 1 image, or for a folder containing the images

$ python main.py -img "D:\My Images\OCR\my_best_mtg_card.jpg"
$ python main.py -dir "D:\My Images\OCR"

All the results go into mtg_cards.db, that you can open with an SQLite3 browser. Or you can choose to export the results as an Excel-like CSV.

$ python main.py -img "D:\My Images\OCR\my_best_mtg_card.jpg" -export
$ python main.py -dir "D:\My Images\OCR" -export

If anything went wrong and you want to start all over again, you can reset the database

$ python database.py -reset

About AWS

You can create a 1-year free account for AWS here. You will also need to create access tokens and IAM users with access to Rekognition and Comprehend Services. Please refer to AWS doc mentioned previously.

Limitation

This script can only fetch prices for the last edition of the card, there is no way for it to know the actual card's edition for now.

mtg-aws-ocr's People

Contributors

seriously24 avatar

Stargazers

Szilveszter Farkas avatar Marc Schuba avatar Jared Short avatar

Watchers

 avatar

Forkers

sponsfreixes

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.