This won't work. To write a dataset in parallel, you need to use a partitioning filter such as D3 (vtkDistributedDataFilter). Try opening the example dataset in ParaView, applying D3 and then saving as pvtu. Ideally, you would directly write the data partitioned from the simulation. One partition per rank maybe or you could sub-group using MPI to have fever files. This is where you would get most scalability out of ParaView if you are running it in parallel.<div>
<br></div><div>-berk<br><br><div class="gmail_quote">On Wed, Jan 5, 2011 at 2:38 AM, Guenter Bartsch <span dir="ltr"><<a href="mailto:guenter.bartsch@googlemail.com">guenter.bartsch@googlemail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">robert,<br>
<br>
thanks for your quick response<br>
<div class="im"><br>
On Tue, Jan 4, 2011 at 6:16 PM, Robert Maynard<br>
<<a href="mailto:robert.maynard@kitware.com">robert.maynard@kitware.com</a>> wrote:<br>
> Hi,<br>
><br>
> This is a known issue when a VTK XML file has an appended data section<br>
> larger than 2GB(<a href="http://public.kitware.com/Bug/view.php?id=6938" target="_blank">http://public.kitware.com/Bug/view.php?id=6938</a>).<br>
<br>
</div>ah, that explains it<br>
<div class="im"><br>
> To work around the problem you can look at writing out the file as any of<br>
> the following:<br>
><br>
> Partitioned VTK XML<br>
> Ensight Gold Binary<br>
> Exodus II ( Will require you too link to the exodus library found<br>
> at <a href="http://sourceforge.net/projects/exodusii/" target="_blank">http://sourceforge.net/projects/exodusii/</a> )<br>
<br>
</div>tried the first option for now - i assume partitioned vtk == parallel vtk?<br>
<div class="im"><br>
vtkSmartPointer<vtkUnstructuredGridReader> reader =<br>
vtkSmartPointer<vtkUnstructuredGridReader>::New();<br>
reader->SetFileName(filename);<br>
<br>
</div> char *ofilename = "foo.pvtu";<br>
<div class="im"> cout << "Output filename: " << ofilename << "\n";<br>
</div> vtkSmartPointer<vtkXMLPUnstructuredGridWriter> writer =<br>
vtkSmartPointer<vtkXMLPUnstructuredGridWriter>::New();<br>
writer->SetFileName(ofilename);<br>
writer->SetNumberOfPieces(8);<br>
<div class="im"> writer->SetInputConnection(reader->GetOutputPort());<br>
writer->Write();<br>
<br>
</div>and it works nicely for a smaller dataset (although it writes only one<br>
piece in that case). but, when i run it on the large data set, i get a<br>
segfault:<br>
<br>
(gdb) run /home/alex/projekte/1231/WP1/windfolding/windfolding1/windfield.vtk<br>
Starting program: /home/guenter/projects/vtk/vtk2xml<br>
/home/alex/projekte/1231/WP1/windfolding/windfolding1/windfield.vtk<br>
[Thread debugging using libthread_db enabled]<br>
Input filename:<br>
/home/alex/projekte/1231/WP1/windfolding/windfolding1/windfield.vtk<br>
Output filename: foo.pvtu<br>
<br>
Program received signal SIGSEGV, Segmentation fault.<br>
0x00000000006225a5 in vtkUnstructuredGrid::SetCells(int*, vtkCellArray*) ()<br>
(gdb) where<br>
#0 0x00000000006225a5 in vtkUnstructuredGrid::SetCells(int*, vtkCellArray*) ()<br>
#1 0x00000000005b33fd in<br>
vtkUnstructuredGridReader::RequestData(vtkInformation*,<br>
vtkInformationVector**, vtkInformationVector*) ()<br>
#2 0x00000000005d4252 in<br>
vtkDataReader::ProcessRequest(vtkInformation*, vtkInformationVector**,<br>
vtkInformationVector*) ()<br>
#3 0x00000000006077ca in vtkExecutive::CallAlgorithm(vtkInformation*,<br>
int, vtkInformationVector**, vtkInformationVector*) ()<br>
#4 0x000000000060279d in<br>
vtkDemandDrivenPipeline::ExecuteData(vtkInformation*,<br>
vtkInformationVector**, vtkInformationVector*) ()<br>
#5 0x00000000006066fa in<br>
vtkDemandDrivenPipeline::ProcessRequest(vtkInformation*,<br>
vtkInformationVector**, vtkInformationVector*) ()<br>
#6 0x000000000061f9fd in<br>
vtkStreamingDemandDrivenPipeline::ProcessRequest(vtkInformation*,<br>
vtkInformationVector**, vtkInformationVector*) ()<br>
#7 0x0000000000609a72 in vtkExecutive::ForwardUpstream(vtkInformation*) ()<br>
#8 0x0000000000606675 in<br>
vtkDemandDrivenPipeline::ProcessRequest(vtkInformation*,<br>
vtkInformationVector**, vtkInformationVector*) ()<br>
#9 0x000000000061f9fd in<br>
vtkStreamingDemandDrivenPipeline::ProcessRequest(vtkInformation*,<br>
vtkInformationVector**, vtkInformationVector*) ()<br>
#10 0x0000000000606249 in vtkDemandDrivenPipeline::UpdateData(int) ()<br>
#11 0x000000000061e4ad in vtkStreamingDemandDrivenPipeline::Update(int) ()<br>
#12 0x00000000006081ab in vtkExecutive::Update() ()<br>
#13 0x0000000000604815 in vtkDemandDrivenPipeline::Update() ()<br>
#14 0x00000000006169c1 in vtkStreamingDemandDrivenPipeline::Update() ()<br>
#15 0x00000000005e9d68 in vtkAlgorithm::Update() ()<br>
#16 0x00000000005c50fd in vtkXMLWriter::Write() ()<br>
#17 0x00000000005b18a5 in main (argc=2, argp=0x7fffffffcd58) at<br>
/home/guenter/projects/vtk/vtk2xml.cxx:41<br>
<br>
is this a bug or am i using the parallel writer incorrectly?<br>
<br>
thanks again and best regards,<br>
<div><div></div><div class="h5"><br>
guenter<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 <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: <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>
</div></div></blockquote></div><br></div>