| import subprocess | |
| scripts = [ | |
| "extract_frames.py", | |
| "eval2.py", | |
| "create_submission.py" | |
| ] | |
| def run_script(script): | |
| print(f"\nπ Running {script}...") | |
| result = subprocess.run(["python", script], capture_output=True, text=True) | |
| if result.returncode == 0: | |
| print(f"β {script} completed successfully.\n") | |
| print(result.stdout) | |
| else: | |
| print(f"β {script} failed with error:\n{result.stderr}") | |
| exit(1) | |
| if __name__ == "__main__": | |
| for script in scripts: | |
| run_script(script) | |
| print("π All scripts completed successfully!") | |