A simple streamlit based web application in order to find duplicates in a corpus of images using perceptual hashing, uploaded by the user.
- Simply run the command pip install -r requirements.txt in order to install the necessary dependencies.
- Clone this repository in your favourite directory.
- Simply run the command:
streamlit run app.py
- Navigate to http://localhost:8501 in your web-browser. This will launch the web app :
- By default, streamlit allows us to upload files of max. 200MB. If you want to have more size for uploading images, execute the command :
streamlit run app.py --server.maxUploadSize=1028
- Ensure you have Docker Installed and Setup in your OS (Windows/Mac/Linux). For detailed Instructions, please refer this.
- Navigate to the folder where you have cloned this repository ( where the Dockerfile is present ).
- Build the Docker Image (don't forget the dot!! π ):
docker build -f Dockerfile -t app:latest .
- Run the docker:
docker run -p 8501:8501 app:latest
This will launch the dockerized app. Navigate to http://localhost:8501/ in your browser to have a look at your application. You can check the status of your all available running dockers by:
docker ps
-
Navigate to the Heroku Platform and login using your E-mail. In case you don't have an account, you can sign-up using your E-mail.
-
After account creation and successful login, click on Create New App. The platform shall now ask you to choose a suitable name for the webapp and the corresponding region (Europe/United States)
-
Add a payment method and click on Create App. (Heroku's free tier plan for webapps deployment has ended. For more details, you can refer this.)
-
Open a new tab and login into your Github Account and create a git repository comprising of this entire directory's files and sub-directories. Ensure that your webapp's directory structure looks like this:
-
Switch back to the heroku app configuration and under the Deploy menu, select Github under the Deployment Method category.
-
You need to successfully authenticate and authorize access to your Github account by Heroku. After successful authorization, search for your git repository name and select Connect.
-
Go to Manual Deploys section and select the suitable branch name from the git repository which you wish to deploy.
-
Click Deploy Branch. This will launch the webapp deployment and you can view the build logs. This may take several minutes and upon completion, you should see a message stating:
Launching...
Released v1
https://<heroku app name>.herokuapp.com/ deployed to Heroku
- You can now navigate to the URL https://.herokuapp.com/ in order to view your deployed webapp. For any troubleshooting, you can refer their documentation.