I'm trying to run multiple scripts to maintain the running speed.
I'm using two scripts that need each other to work, so I want another Python script like setup.py to run them:
import os
os.system('python script1.py && python script2.py')
But that doesn't work at the same time.
1 Answer 1
maybe you can use multithreading : Python - Multithreading
You will be able to run different python scripts in different threads.
That will allow you to execute them in the same time.
If your script doesnt require a lot of layers of data to process, then you can keep using your processor.
Otherwise you can use your GPU. For example cuda for NVIDIA GPU : See cuda here
script2.pydepends onscript1.py, the you cannot run them in parallel. (Or, at least not completely.) Is this the case or do you want to run both scripts together multiple times in parallel?