DSatishchandra's picture
Update modules/streamlit_ui.py
5b7a8fd verified
import streamlit as st
def display_video_feed():
# Example code to capture a frame from a video feed (replace with your feed)
import cv2
cap = cv2.VideoCapture("thermal_video_feed.mp4") # Replace with live feed URL or file
ret, frame = cap.read()
if ret:
st.image(frame, channels="BGR", caption="Live Feed", use_column_width=True)
cap.release()
return frame
def display_alerts(faults):
""" Function to display alerts in Streamlit """
for fault in faults:
st.warning(f"ALERT: {fault}")