#!/bin/bash # Live Audio Singing Helper Pro - Startup Script # Version 2.0.0 echo "🎤 Live Audio Singing Helper Pro v2.0.0" echo "========================================" # Check if running in HuggingFace Spaces if [ "$SPACE_ID" ]; then echo "🚀 Running in HuggingFace Spaces: $SPACE_ID" else echo "🏠 Running locally" fi # Check Python version python_version=$(python3 --version 2>&1) echo "🐍 Python version: $python_version" # Check if requirements are installed echo "📦 Checking dependencies..." if python3 -c "import gradio, librosa, spleeter" 2>/dev/null; then echo "✅ Core dependencies found" else echo "❌ Missing dependencies. Installing..." pip install -r requirements.txt fi # Check system dependencies echo "🛠️ Checking system dependencies..." if command -v ffmpeg &> /dev/null; then echo "✅ FFmpeg found" else echo "⚠️ FFmpeg not found - audio processing may be limited" fi # Set environment variables for optimal performance export TF_CPP_MIN_LOG_LEVEL=2 export CUDA_VISIBLE_DEVICES=0 echo "" echo "🎵 Starting Live Audio Singing Helper Pro..." echo "💡 Access the application at: http://localhost:7860" echo "📚 Documentation available in the Help tab" echo "" # Start the application python3 app.py