posedet/config.py
2025-06-20 15:01:39 +08:00

27 lines
859 B
Python

import streamlit as st
# Check for Pygame availability for audio playback
try:
import pygame
PYGAME_AVAILABLE = True
except ImportError:
PYGAME_AVAILABLE = False
st.warning("Pygame not installed, video will play without sound. To install: pip install pygame")
# Check for MoviePy availability for audio extraction
try:
from moviepy import VideoFileClip
MOVIEPY_AVAILABLE = True
except ImportError:
MOVIEPY_AVAILABLE = False
if PYGAME_AVAILABLE:
st.warning("MoviePy not installed, audio extraction from video is disabled. To install: pip install moviepy")
# Check for RealSense SDK availability
try:
import pyrealsense2 as rs
REALSENSE_AVAILABLE = True
except ImportError:
REALSENSE_AVAILABLE = False
st.warning("Intel RealSense SDK (pyrealsense2) not found. The app will use a standard USB camera.")