multi-block VTK output

Hi,

I have a block based AMR code which outputs cell centered coordinates and values. I made some initial attempts to convert that into a multi-block output (*.vtm),

However, the problem is that ParaView cannot figure out the connection between blocks, so there is a gap in between:

I am wondering what is a proper way to handle the data. Should I switch to the original node grid, or do some trick to let ParaView know the blocks are connected so that common filter can work?

my_vtm_file_1.vtr (962 Bytes) my_vtm_file_2.vtr (964 Bytes) my_vtm_file.vtm (353 Bytes)

Hello,

If you want common filters to work on your data set, you can use the MergeBlock filter to append all blocks in a single data set.
Notice that this filter wont “glue” your blocks. Do you also need blocks to be merged in terms of neighborhood ?

Hello,

I was just about to make a post with a similar issue. I have a multiblock terrain representation that I’d like to run some contour and volume simulations over. However, like henry2004y when I import the plot3D .xyz files there’s a distinguishable gap between the blocks (see attached picture).

I’d like to find a way to eliminate those gaps to allow for smooth animations at the block boundaries.

I’m thinking this has something to do with ghosting variables, but I’d appreciate someone’s insight into the problem!

Yes. The blocks should be merged, but simply with the merge block filter, I can apply common filters, but the gaps are still there. And also using the merge block filter converts the structured grid to unstructured grid, which is what I want to avoid actually.

Because there is no connection between the blocks.
Just make an actual connection and duplicate the point making the connection.

I see. But then if there are resolution changes between blocks (i.e. AMR), which means ghost cells are not overlapped, what will happen?

I found some pieces of information about AMR data structures in VTK, but I’m really not familiar with them…

Can you provide an example as to how to make a connection between the blocks? I tried the GroupDatasets filter followed by the Merge Blocks filter, but still cannot get Paraview to remove the space between blocks.

Thank you,
Anthony

You either need to use a AMR datastructures like vtkUniformGridAMR or vtkHyperTreeGrid.

Or you need to create cells like this :

1 Like

Do you know where is this vtkUniformGridAMR format described? I found one in the auto-generated https://vtk.org/doc/nightly/html/classvtkUniformGridAMR.html), and the C++ source code,
but I still have no clue how to generate this data structure myself.


https://www.paraview.org/ParaView/index.php/Multi-Resolution_Rendering_with_Overlapping_AMR

There is an AMRGaussianPulseSource in ParaView that you can use.