Download Specific Images from Reddit using an AI model, Google Vision
This script will take three inputs from the user
- a subreddit name
- a thing you want to search
- number of pictures you want saved
This script will then search for any pictures in the subreddit. Those pictures are run through Google Vision's API and are downloaded to a users computer in a folder called "SavedReddit/" + name of search. The pictures are only downloaded if Google Vision's API returns a list of labels or descriptors that match the keyword the user wants.
- the program will validate the existence of a subreddit. If a user types a subreddit that does not exist, the program will ask for a valid one.
- the program will stop searching after a certain constraint in order to not spam Reddit's API
- Not only can the user can search a specific object, but also a specific color. The script will compare the rgb values of Google Vision's dominant colors
- when comparing dominant colors, the script will only compare a certain amount to limit incorrect color matching
Right now I am limited to a command line interface; however, in the future, I plan to change this.
Right now, this script is more of a personal use; however, in the future, I hope to expand its capabilities.
- Python in VSC
- Google API service account
- Reddit API credentials
- allowing user to enter multiple words
- more use of Google Vision API such as people detection, only downloading images of a high resolution, etc)
- a website/better distributable implementation of this script (a website that could allow users to access the Reddit API and Google API without needed the licenses themselves)

