How does Paraview recieves data for plotting?

I have a dataset on astrophysics containing density values in a 3D array, and I’d like to plot these in paraview. The data is originally in spherical coordinates, and before uploading them into paraview they were transformed to cartesian. However, even after this transformation, the plot doesn’t make any sense. Since them I’m trying to understand what paraview expects to receive as input in order to interpret correctly each datapoint and each density value. To convert this data for plotting, I use VTKStructureGrid because from what I’ve read in the documentation it is the best suiting function for my data. What I haven’t found is information on what StructureGrid wants as input format. Does it expect the dataset to contain as columns the values of x, and y, and z, and another for density; or does it expect one of the columns to be the sum of x, y, and z, and the density values are within another file, etc.
I’ve looked in files and websites with documentations and examples of applications of paraview as well as VTK, but I didn’t find any clear information about these specifically.

Hi @Melissa_Freitas

You never mention which data format you are using. vtkStructuredGrid is a type of dataset, not an actual on disk format. vtkStructuredGrid are usually stored as .vts file but other formats can be used.

Best,

Hi @mwestphal, sorry for the missing information. So, my dataset format is .h5, i needed to convert to .vts using pyevtk and vtkStructuredGrid because the times I tried put my dataset directly on Paraview i received just a error message. When i convert the data format to .vts, the dataset works and the plot show but not in a way that make sense.

Hi @Melissa_Freitas

.h5 is not a format per se, but just a container that supports different format. How was it generated ?

However ParaView support many .h5 formats, so you may be able to open your file directly with ParaView.

You say that you tried that already, but you did not share the error message you have.
Ideally, please share your data.

Please also share your converted data.