Update VisIt bridge to properly handle ghost information
Now that there's consistency between how ghost cells are marked between VisIt and VTK (https://blog.kitware.com/ghost-and-blanking-visibility-changes/) it seems like it should be simple enough to do automatically convert any avtGhostNodes or avtGhostZones to the proper vtkGhostType array (but then again there could be some gnarly stuff to deal with underneath the covers). I have some .silo data that I was trying to deal with in PV 5.6 and saw the avtGhostZones array in it and use the following in the Script portion of a Programmable Filter to convert the arrays the rectilinear grid blocks:
input = self.GetInput() output = self.GetOutput() import vtk if input.IsA("vtkMultiBlockDataSet"): output.CopyStructure(input) iter = input.NewIterator() iter.UnRegister(None) iter.InitTraversal() while not iter.IsDoneWithTraversal(): curInput = iter.GetCurrentDataObject() curOutput = curInput.NewInstance() curOutput.UnRegister(None) output.SetDataSet(iter, curOutput) curOutput.ShallowCopy(curInput) arr = vtk.vtkUnsignedCharArray() arr.SetNumberOfTuples(curOutput.GetNumberOfCells()) arr2 = vtk.vtkUnsignedCharArray.SafeDownCast(curInput.GetCellData().GetArray("avtGhostZones")) arr.DeepCopy(arr2) arr.SetName("vtkGhostType") curOutput.GetCellData().AddArray(arr) curOutput.UpdateCellGhostArrayCache() iter.GoToNextItem()
The other thing when I do this with the following pipeline in the GUI is that I see multiple updates to the Cell Data to Point Data filter when pvserver is running with multiple MPI processes:
- SILO reader
- Programmable Filter with above script (probably should have had stuff in the request information about ghost information as well).
- Cell Data to Point Data filter
- Contour filter
- Merge Blocks filter (seems to update the CD 2 PD filter)
- Extract Surface filter (also seems to update the CD 2 PD filter)
I'll share some data with @cory.quammen to test with since it's fairly big. Restrictions on the data is US citizens and permanent residents only, internal to Kitware only.