I am using the vtk library in python to importe a netcdf file.
The netcdf file contains data of two variables for different time steps.
It will be converted into a vtkStructuredGrid
The vtkStructuredGrid then should have PointData for different time steps.
This might get really verbose and slow in Python, so I’d recomend just using the netCDF4 Python package (or another library like xarray that can handle your data format) to load your netCDF files into NumPy arrays.
Then if you want to create a structured grid for visualization, use the vtkStructuredGrid from the vtk.vtkNetCDFCFReader like you have above and simply update the array using the numpy arrays loaded directly using netCDF4.
FYI: PyVista makes managing numpy arrays and VTK datasets super streamlined