I am developing a multiprocess application in Python with the purpose of studying the communication between a large number of non-synchronized objects that I have called neurons. These neurons are members of a larger class called a network and this network is controlled by a third class that is a user interface called UI.
In order to make my neurons work, I made them inherited from the Thread class, as I did from the network class. The point is that when I launch my application with a hundred neurons (therefore a hundred threads), my user interface becomes very slow and I want to avoid this.
I suppose this is due to how GIL manages the concurrency of threads. So I think I can solve this problem by making the UI run on a different processor or kernel. But I really do not know how to do such a thing and if it really is a good solution for my problem. I also read a bit about multiprocessing the Python module, but I do not know what I should use in this
Can anyone give me an opinion on this solution and some tips on how to use the multiprocessing module? Thank you