sing / run.sh
latterworks's picture
Rename RUN.SH to run.sh
cca720b verified
#!/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