I don't have any problem running Median or Gradient on image of type<br>double. If you are allowed to share your data, I may give a try here.<br><br>Maybe are you running out of memory? You can try to extract a subset<br>
of your data and see if the segfault occurs.<br><br>Jerome<br><br><div class="gmail_quote">2011/5/20 Dominik Szczerba <span dir="ltr"><<a href="mailto:dominik@itis.ethz.ch">dominik@itis.ethz.ch</a>></span><br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
Hi Jerome,<br>
<br>
Thanks for the references, but there does not to be any solution in there?<br>
And yes, "strange extents" are also taking place in some cases, i.e.,<br>
extents are actually correct, but the content of the image data is<br>
smaller if the new spacing is finer than the original.<br>
Due to the lack of detailed description of this whole mechanism I can<br>
not say if this is my lack of knowledge or a bug.<br>
<br>
Regarding segfaults, the only non-standard thing I can say about my<br>
input image data is that it contains a scalar type "double". The said<br>
filters will work with image generated by Sources/Wavelet, but the<br>
type of that one is float. I am afraid something is hardcoded<br>
somewhere.<br>
<br>
Regards,<br>
<font color="#888888">Dominik<br>
</font><div><div></div><div class="h5"><br>
On Fri, May 20, 2011 at 8:25 AM, Jérôme <<a href="mailto:jerome.velut@gmail.com">jerome.velut@gmail.com</a>> wrote:<br>
> Hi,<br>
> regarding the vtkImageSlice exposition in ParaView, you should take<br>
> a look at these threads:<br>
> - issue report:<br>
> <a href="http://www.mail-archive.com/paraview@paraview.org/msg02225.html" target="_blank">http://www.mail-archive.com/paraview@paraview.org/msg02225.html</a><br>
> <a href="http://www.mail-archive.com/paraview@paraview.org/msg08260.html" target="_blank">http://www.mail-archive.com/paraview@paraview.org/msg08260.html</a><br>
> - issue deep explanation:<br>
> <a href="http://www.cmake.org/pipermail/paraview/2010-June/017738.html" target="_blank">http://www.cmake.org/pipermail/paraview/2010-June/017738.html</a><br>
><br>
> regarding the segfault, I feel surprise ! I use Median and Gradient very<br>
> often, and I never noticed a bug. Can you give the step to reproduce ?<br>
><br>
> Best regards,<br>
> Jerome<br>
><br>
><br>
> 2011/5/19 Dominik Szczerba <<a href="mailto:dominik@itis.ethz.ch">dominik@itis.ethz.ch</a>><br>
>><br>
>> I think my theory that it has to do with threading may be correct...<br>
>><br>
>> I just tried instead of my custom plugin to run the built-in Gradient<br>
>> or Median on my vtkImageData and Paraview (3.11) silently segfaults.<br>
>> Both these built-in filters derive from vtkThreadedImageAlgorithm.<br>
>> Built-in vtkExtractVOI. however, works correctly, just as my other<br>
>> custom plugins deriving from vtkImageAlgorithm.<br>
>><br>
>> Any pointers in this bug hunting are appreciated.<br>
>><br>
>> Dominik<br>
>><br>
>> On Thu, May 19, 2011 at 9:30 PM, Dominik Szczerba <<a href="mailto:dominik@itis.ethz.ch">dominik@itis.ethz.ch</a>><br>
>> wrote:<br>
>> > So far I was able to add a few simple custom plugins, but am slowly<br>
>> > losing the grip.<br>
>> > I am trying to resample an image like this:<br>
>> ><br>
>> > <SourceProxy name="ImageResample" class="vtkImageResample"<br>
>> > label="ImageResample"><br>
>> > <InputProperty name="Input" command="SetInputConnection"><br>
>> > <ProxyGroupDomain name="groups"><br>
>> > <Group name="sources"/><br>
>> > <Group name="filters"/><br>
>> > </ProxyGroupDomain><br>
>> > <DataTypeDomain name="input_type"><br>
>> > <DataType value="vtkImageData"/><br>
>> > </DataTypeDomain><br>
>> > </InputProperty><br>
>> > <DoubleVectorProperty name="Magnification Factor"<br>
>> > command="SetAxisMagnificationFactor" number_of_elements="3"<br>
>> > number_of_elements_per_command="1" repeat_command="1" use_index="1"<br>
>> > default_values="1 1 1"/><br>
>> ><br>
>> > I get these 2 problems:<br>
>> ><br>
>> > 1) There appear two (!) outputs (named Output-0 and Output-1). I get<br>
>> > this message:<br>
>> ><br>
>> > ERROR: In<br>
>> > /home/dsz/pack/ParaView/VTK/Filtering/vtkDemandDrivenPipeline.cxx,<br>
>> > line 827<br>
>> > vtkPVPostFilterExecutive (0x3aa4f60): Input for connection index 0 on<br>
>> > input port index 0 for algorithm vtkPVPostFilter(0x2cfb850) is of type<br>
>> > vtkImageStencilData, but a vtkDataSet is required.<br>
>> ><br>
>> > 2) The first output has the expected Spacing, but it does not contain<br>
>> > the same scalar array as in the input. Instead, it contains a new<br>
>> > array ImageScalars ranging [0,0]. I get this message:<br>
>> ><br>
>> > Warning: In<br>
>> > /home/dsz/pack/ParaView/ParaViewCore/VTKExtensions/vtkTexturePainter.cxx,<br>
>> > line 179<br>
>> > vtkTexturePainter (0x339fa70): Failed to locate selected scalars. Will<br>
>> > use image scalars by default.<br>
>> ><br>
>> > I have been so far successful with other image algorithms, however<br>
>> > they were all deriving from vtkImageAlgorithm. This one derives from<br>
>> > vtkThreadedImageAlgorithm - could this have anything to do here?<br>
>> > Could anyone point me into the right direction? After inspection of<br>
>> > the xml files in the ParaView source tree I am still clueless.<br>
>> ><br>
>> > Thanks and regards,<br>
>> > Dominik<br>
>> ><br>
>> _______________________________________________<br>
>> Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
>><br>
>> Visit other Kitware open-source projects at<br>
>> <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
>><br>
>> Please keep messages on-topic and check the ParaView Wiki at:<br>
>> <a href="http://paraview.org/Wiki/ParaView" target="_blank">http://paraview.org/Wiki/ParaView</a><br>
>><br>
>> Follow this link to subscribe/unsubscribe:<br>
>> <a href="http://www.paraview.org/mailman/listinfo/paraview" target="_blank">http://www.paraview.org/mailman/listinfo/paraview</a><br>
><br>
><br>
</div></div></blockquote></div><br>