Inspiration

I wanted to give myself a challenge and build something with programming languages and libraries that I am not familiar with. I also wanted to learn web scrapping and how to use libraries to extract text from an image.

What it does

After the user uploads a picture of a word (screenshot or real-life picture), the app displays an image that describes the word.

How I built it

Using Pytesseract and OpenCV, a string is extracted from the image. Then, a web driver performs a Google search of this string and retrieves the first image using a Python library called BeautifulSoup (it looks for HTML elements with the "img" tag). The image is passed to the frontend and displayed.

Challenges I ran into

As I mentioned before, I was not familiar with the technologies I used. The installation was tedious (I installed many things that I realized were useless) and I had to go over so many web resources just to understand how to get started.

Accomplishments that I am proud of

I built my first Flask application without any prior knowledge (aside some experience in Python).

What I learned

How to link the backend to the frontend with Flask, how to read text from an image using Pytesseract and OpenCV and how to retrieve Google images with a webdriver.

What's next for Words and Pictures

Add more languages (the current app does not recognize arabic for instance) and allow users to upload text (display images on hover). Words and Pictures can also be extended to recommend books and/or to test someone's vocabulary and spelling with games and quizzes.

Share this project:

Updates