Dnia Fri, 15 Jul 2011 22:15:15 -0700, Dennis Lee Bieber napisał(a):
> And (so far as I understand it) each process can claim its own CPU
> core, whereas threads share the active core.
I do not think so. AFAIK, threads may be distributed over differrent
CPUs (just like in any other programmin
On Sat, Jul 16, 2011 at 3:15 PM, Dennis Lee Bieber
wrote:
> And (so far as I understand it) each process can claim its own CPU
> core, whereas threads share the active core.
Threads can be put onto separate cores too, and can have their
affinities set. But because of the GIL, actual CPython code
2011/7/16 Lee Harr :
> I am not a multiprocessing expert, but I think the problem you
> are having is that Process is running your code in a separate
> process, so there is no way you could see those object changes
> in your main line code.
>
> In other words, Process is not an exact replacement fo
I see. Well I was hoping to see the same result in the multiprocessing
example as using the threading example. What you pointed out makes sense
though, but what I don't understand is how modifying the queue in the
example works fine in both. Possibly it was designed for that kind of use?
Brand
> I'm working on a tool that runs a number of process is separate thread.
> I've, up to this point, been using threading.Thread, but from what I
> read multiprocess will allow multiple processors to be used
> From the python docs on multiprocessing.
> leverage multiple processors on a giv