Spaces:
Configuration error
Configuration error
| # Init script for Myanmar TTS Space | |
| echo "Initializing Myanmar TTS Space..." | |
| # Clone the repository if needed | |
| if [ ! -d "myanmar-tts" ]; then | |
| echo "Cloning repository..." | |
| git clone https://github.com/hpbyte/myanmar-tts.git | |
| fi | |
| # Create model directory if needed | |
| if [ ! -d "trained_model" ]; then | |
| echo "Creating model directory..." | |
| mkdir -p trained_model | |
| fi | |
| # Check if model files exist | |
| if [ ! -f "trained_model/checkpoint_latest.pth.tar" ] || [ ! -f "trained_model/hparams.yml" ]; then | |
| echo "Creating placeholder model files..." | |
| echo "This is a placeholder. Replace with actual model file." > trained_model/checkpoint_latest.pth.tar | |
| echo "# This is a placeholder. Replace with actual hparams.yml" > trained_model/hparams.yml | |
| echo "WARNING: Model files are missing. You need to upload them to the 'trained_model' directory." | |
| echo "Required files:" | |
| echo "1. trained_model/checkpoint_latest.pth.tar" | |
| echo "2. trained_model/hparams.yml" | |
| fi | |
| # Set up Python path | |
| export PYTHONPATH=$PYTHONPATH:$(pwd):$(pwd)/myanmar-tts | |
| # Run the setup script | |
| python setup_repo.py | |
| echo "Initialization complete." |