<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=iso-8859-1"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Sprechblasentext Zchn";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";
        mso-fareast-language:EN-US;}
span.E-MailFormatvorlage17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.SprechblasentextZchn
        {mso-style-name:"Sprechblasentext Zchn";
        mso-style-priority:99;
        mso-style-link:Sprechblasentext;
        font-family:"Tahoma","sans-serif";}
.MsoChpDefault
        {mso-style-type:export-only;
        mso-fareast-language:EN-US;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 2.0cm 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=DE link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Hi to everyone,<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal><span lang=EN-US>could someone recommend me a class for fast calculation of the histogram from a 3d data set?<br><br><o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>Right know we use vtkImageAccumulate. But it takes up a lot of time. The data sets are several gigabytes big.<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoNormal style='text-autospace:none'><span lang=EN-US>I tried ScalarImageToHistogramGenerator and ImageToHistogramFilter (with </span><span lang=EN-US style='font-size:9.5pt;font-family:Consolas'>HistogramType::SizeType size(1); </span><span lang=EN-US>).<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span lang=EN-US>ScalarImageToHistogramGenerator is slower than ImageToHistogramFilter. And both are slower than vtkImageAccumulate.<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoNormal style='text-autospace:none'><span lang=EN-US>The results are below (in ms):<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span lang=EN-US>VoxelCount: 1052494100, DataType: unsigned short, Min value 0, Max value 65535, Bins 1024<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span lang=EN-US>Time for calculating histogram (VTK) 17498<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>Time for calculating histogram (ITK) 62093<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US>Time for calculating histogram (ITK scalar) 111687<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span lang=EN-US>Thanks in Advance,<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:8.0pt;font-family:"Arial","sans-serif";mso-fareast-language:DE'>Mustafa Arikan<b><br>FH OÖ Forschungs- &amp; Entwicklungs GmbH<br></b>Stelzhamerstraße 23 <br>4600 Wels / Austria<br>Tel: +43 (0)50804-44407<o:p></o:p></span></p><p class=MsoNormal><span lang=EN-US style='font-size:8.0pt;font-family:"Arial","sans-serif";mso-fareast-language:DE'>E-Mail: M</span><span style='font-size:8.0pt;font-family:"Arial","sans-serif";mso-fareast-language:DE'>ustafa.Arikan@fh-wels.at<o:p></o:p></span></p><p class=MsoNormal style='margin-bottom:12.0pt'><span lang=DE-AT style='font-size:8.0pt;font-family:"Arial","sans-serif";mso-fareast-language:DE'>Web: www.3dct.at</span><span style='font-size:8.0pt;font-family:"Arial","sans-serif";mso-fareast-language:DE'><o:p></o:p></span></p><p class=MsoNormal style='margin-bottom:12.0pt'><span style='font-size:8.0pt;mso-fareast-language:DE'><img width=275 height=41 id="Bild_x0020_1" src="cid:image001.png@01CE5179.F222E970" alt="iCT_E-mail_Banner-2014_FINAL"></span><span lang=DE-AT style='mso-fareast-language:DE'><o:p></o:p></span></p><p class=MsoNormal><a href="http://www.fh-ooe.at/"><span style='font-size:8.0pt;font-family:"Arial","sans-serif";color:windowtext;mso-fareast-language:DE;text-decoration:none'><img border=0 width=275 height=41 id="Bild_x0020_2" src="cid:image002.jpg@01CE5179.F222E970" alt="Studieren probieren 16 11 2012"></span></a><span style='font-size:8.0pt;font-family:"Arial","sans-serif";mso-fareast-language:DE'><o:p></o:p></span></p><p class=MsoNormal><span lang=DE-AT style='font-size:8.0pt;font-family:"Arial","sans-serif";color:gray;mso-fareast-language:DE'>Firmenbuchgericht/Court of registry: Landesgericht Wels</span><span style='font-size:8.0pt;font-family:"Arial","sans-serif";mso-fareast-language:DE'><o:p></o:p></span></p><p class=MsoNormal><span lang=DE-AT style='font-size:8.0pt;font-family:"Arial","sans-serif";color:gray;mso-fareast-language:DE'>Firmenbuchnummer/Company registration: FN 236733 m</span><span style='font-size:8.0pt;font-family:"Arial","sans-serif";mso-fareast-language:DE'><o:p></o:p></span></p><p class=MsoNormal><o:p>&nbsp;</o:p></p></div></body></html>