简体   繁体   中英

How to run multiple programs in different consoles in Python

I have two folders, 1 and 2 . Each folder has a Python file with the same name: 220_beta_1e-2_47_53ND.py . How do I run both the Python files simultaneously on different consoles? I mostly use Spyder.

on powershell (replace XYZ with your python version)

 Invoke-Item C:\PythonXYZ\python.exe pathtoscript1; Invoke-Item C:\PythonXYZ\python.exe pathtoscript2; 

or rather create a third script in python that launches 2 processes

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM