Spaces:
Paused
Paused
| import subprocess | |
| import os | |
| # Prepare the command | |
| command = [ | |
| "python", | |
| "run_inference_server.py", | |
| "-m", "./models/ggml-model-i2_s.gguf", | |
| "--host", "0.0.0.0", | |
| "--port", "7860" | |
| ] | |
| # Run it as a subprocess | |
| try: | |
| subprocess.run("ls",check=True) | |
| subprocess.run(command, check=True) | |
| except subprocess.CalledProcessError as e: | |
| print(f"Error running inference server: {e}") | |