Commit c5c8fdee authored by Utkarsh Ayachit's avatar Utkarsh Ayachit
Browse files

Fixed BUG #12527. Fixed parallel read issue for unstructured grids.

Fixed the reader to only read unstructure grids on root node when reading in
parallel. For structured grids, the update extents are respected. While for
composite datasets, we distribute the leaves among processes.
parent 7522f14c
......@@ -83,6 +83,12 @@ vtkDataObject* vtkXdmfHeavyData::ReadData()
if (this->Domain->GetNumberOfGrids() == 1)
// There's just 1 grid. Now in serial, this is all good. In parallel, we
// need to be care:
// 1. If the data is structured, we respect the update-extent and read
// accordingly.
// 2. If the data is unstructrued, we read only on the root node. The user
// can apply D3 or something to repartition the data.
return this->ReadData(this->Domain->GetGrid(0));
......@@ -430,6 +436,11 @@ vtkDataObject* vtkXdmfHeavyData::ReadUnstructuredGrid(XdmfGrid* xmfGrid)
vtkSmartPointer<vtkUnstructuredGrid> ugData =
if (this->Domain->GetNumberOfGrids() == 1 && this->Piece != 0)
return ugData;
XdmfTopology* xmfTopology = xmfGrid->GetTopology();
XdmfArray* xmfConnectivity = xmfTopology->GetConnectivity();
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment