ycbq999 / OpenCV_Streamlit_APP

Try to make an online application with Streamlit App combined with modern vision ML technology, YOLO, OpenCV. Deploy it on Azure with CI/CD.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Deployment TBD

OpenCV_Streamlit_APP

Try to make an online application with Streamlit App combined with modern vision ML technology, YOLO, OpenCV. Deploy it on Azure with CI/CD.

Running Locally

  • create virtual environment in current folder

    virtualenv .venv

  • start virtual environment

    source .venv/bin/activate

  • deactivate virtual environment

    deactivate

Automatically go to virtual vironment in VSCode:

  • first setting all up and activate your virtual environment

  • then choose file --> Preference -->settings select workspace tab then click open setting json icon from top right

  • put this code in

    { "python.terminal.activateEnvInCurrentTerminal": true, "python.defaultInterpreterPath": "/home/ycbq999/face_recognition_venv/bin/python" }

  • see reference [https://www.youtube.com/watch?v=g7bg2ADfx4c&ab_channel=JohnSolly]

Streamlit

  • I include stream tutorial folder called 3_Streamlit_crash_course

  • Streamlit treats multiple apps as pages, you need to make a fold named "pages" exactly to activate this feature. also name 1_,2_,--- infront of each page name so it will detect sequence. Remember that

see reference in udemy [https://www.udemy.com/course/yolo-custom-object-detection/learn/lecture/33903494#notes]

Web Video Streaming

We will first use google colab to train the model

Later we will use azure to train and deploy the model.

-reference [https://learn.microsoft.com/en-us/azure/machine-learning/tutorial-train-model?view=azureml-api-2]

-webrtc may not work in this environment due the security on the network. but still can deploy for image object detection.

HTTPS
streamlit-webrtc uses getUserMedia() API to access local webcams, and this method does not work in an insecure context.

This document says

A secure context is, in short, a page loaded using HTTPS or the file:/// URL scheme, or a page loaded from localhost.

So, when hosting your app on a remote server, it must be served via HTTPS.

About

Try to make an online application with Streamlit App combined with modern vision ML technology, YOLO, OpenCV. Deploy it on Azure with CI/CD.


Languages

Language:Jupyter Notebook 77.3%Language:Python 22.0%Language:Dockerfile 0.5%Language:Makefile 0.3%