This application allows users to download images from Google based on a specified keyword and send the images to a provided email address. It leverages the icrawler library for image downloading, streamlit for the user interface, and smtplib for sending emails with attachments.
-
Keyword-Based Image Downloading:
- Users can specify a keyword to search for images.
- The number of images to be downloaded can be customized.
-
Email Integration:
- The application sends the ZIP file as an email attachment to the user.
-
Interactive UI:
- Built with Streamlit, providing a clean and interactive user experience.
-
The user inputs:
- A keyword for the images (e.g., "beautiful landscapes").
- The desired number of images to download.
- Their email address to receive the images.
-
The application:
- Downloads the specified number of images using GoogleImageCrawler.
- Saves the images in a local directory.
- Compresses the images into a ZIP file.
- Sends the ZIP file to the provided email address.
- Python 3.7 or later
- Libraries:
streamliticrawlersmtplibemailpathlibzipfile
├── app.py
├── requirements.txt
├── README.md
Ensure you use a valid Gmail account for sending emails:
- Replace the
sender_emailandsender_passwordvariables in the script with your email and app-specific password.- Follow Google's guide to create an app-specific password.
- Images are saved in the default Downloads folder under a subdirectory named
downloaded_images. - The ZIP file is saved in the Downloads folder as
images.zip.
- GoogleImageCrawler may be rate-limited or blocked based on usage. Ensure you adhere to Google's terms of service.
- The provided Gmail account must have "Allow less secure apps" enabled or use an app-specific password.
- Add support for multiple email providers (e.g., Outlook, Yahoo).
- Allow users to select specific image formats (e.g., PNG, JPG).
- Provide progress tracking for image downloads.
- Include error handling for invalid email addresses or network interruptions.
This project was done in collaboration with https://github.com/arnavtiet.
- icrawler for simplifying image downloads.
- Streamlit for providing a robust platform for building interactive apps.