Reputation: 675
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.
Upvotes: 0
Views: 690
Reputation: 3496
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
Upvotes: 1