Spaces:
Runtime error
Runtime error
import subprocess | |
import os | |
# Clone the repository | |
subprocess.run(['git', 'clone', 'https://github.com/abacaj/replit-3B-inference.git']) | |
# Change directory | |
os.chdir('replit-3B-inference') | |
# Create and activate virtual environment | |
subprocess.run(['python', '-m', 'venv', 'env']) | |
subprocess.run(['env/bin/activate']) | |
# Update submodules | |
subprocess.run(['git', 'submodule', 'update', '--init', '--recursive']) | |
# Install requirements | |
subprocess.run(['pip', 'install', '-r', 'requirements.txt']) | |
# Download the model | |
subprocess.run(['python', 'download_model.py']) | |
# Run inference | |
subprocess.run(['python', 'inference.py']) | |