Sekiryu
Sekiryu copied to clipboard
Change from multi-threading to multiprocessing
Python's Global Interpreter Lock (GIL) limits the execution of multiple threads in parallel due to its restrictions on simultaneous thread execution, especially for CPU-bound tasks. For CPU-bound operations, using the multiprocessing module might be more effective since it bypasses the GIL by spawning separate processes.
https://docs.python.org/3/library/multiprocessing.html