Skip to content

Latest commit

 

History

History
43 lines (25 loc) · 1.6 KB

readme.md

File metadata and controls

43 lines (25 loc) · 1.6 KB

Selfie Image Background App with Flask + React

flask-logo react

Project Directory Strructre

  1. database - contains sqlite3.db file Will not be needed for production DB.
  2. image_store - uploaded and generated images store.
  3. src - main source code.
  4. static - html, css, Js files or react build.
  5. trained_model - ML model for image background removal.

Create virtual Environment or use the link for help.

Download The Pretained Model Files[onnx] from below Link.

  • Light weight model md5 = "8e83ca70e441ab06c318d82300c84806"

  • Reguler model md5 = "60024c5c889badc19c04ad937298a77b"

  • Place the downloaded model files in trained_model directory

To run the app

  • Set set FLASK_DEBUG=1 for DEBUG Mode and set set FLASK_DEBUG=0 for production mode
  • Set App Name set FLASK_APP=run.py
  • Run flask run --host 0.0.0.0 --port 5000 from cmd
  • Finally point ur browser to localhost:5000/

Some Optional Steps for development

  • Run Linter form cmd using flake8 --config .flake8 . -v
  • Code Formating form cmd using black . -v
  • For Cleaning run pyclean -v . & black -v . [ Deletes pycacche files]

React UI repository

Future Development needs to be done

1. Logging