<table cellspacing="0" cellpadding="0" border="0"><tr><td valign="top" style="font: inherit;"><p>Hello Vikash,</p>
<p>this might not be correct since I have no deep insight into ITK an wether or not they have their own threading library but usually your OS, i.e. Windows or Linux, takes care of the distribution of threads.<br>
I don't know of any threading library that fixes threads to a certain Core or CPU since that is the idea behind threads: "Loadbalancing". <br>
Therefore it (OS or some hardware) attaches threads to a Core which is currently out of work.</p>
<p>Cheers,<br>
Willi</p>
</td></tr></table> <div id="_origMsg_">
<div style="font-family:arial, helvetica, sans-serif:font-size:10pt">
<br />
<div style="font-family:times new roman, new york, times, serif;font-size:12pt">
<font size="2" face="Tahoma">
<hr size="1">
<b>
<span style="font-weight:bold;">From:</span>
</b>
Vikash Gupta <vikash.gupta@inria.fr>; <br>
<b>
<span style="font-weight:bold:">To:</span>
</b>
itk <insight-users@itk.org>; <br>
<b>
<span style="font-weight:bold:">Subject:</span>
</b>
[Insight-users] ThreadedGenerateData() <br>
<b>
<span style="font-weight:bold;">Sent:</span>
</b>
Thu, Mar 21, 2013 8:02:22 PM <br>
</font>
<br>
<table cellspacing="0" cellpadding="0" border="0">
<tbody>
<tr>
<td valign="top" style="font:inherit;"><div style='font-family:times new roman, new york, times, serif;font-size:12pt;color:#000000;'>Dear Itk-Users, <br>This might be a naive question but I am pondering over it for some time. When the ThreadedGenerateData() function is called in an itk filter, the threads refer to the number of CPUs on a computer or the number of cores on each CPU. <br><br>For example, <span style="white-space:pre;">        </span>i have 8 cpus on my laptop with 4 cores on each, so if I call SetNumberOfThreads(4), these 4 cores will belong to the same CPU ? <br><br>On the next lever, if I divide the work on each cpu and then also do multithreading in each CPU, will the number of threads correspond to the number of cores on each CPU ?<br>Thanks a lot for any insight..<br><br>Vikash<br><br></div></td>
</tr>
</tbody>
</table>
</div>
</div>
</div>