Open sebastian-hogeweg opened 5 months ago
Applying the suggested workflow on an actual geological model (see first screenshot) results in a weird geometry (see second screenshot)
Method used for extracting the grid:
`def spatialProperties(self, properties): print(sr3_reader.list_spatial_properties(self.sr3)) (sp_ind, sp) = sr3_reader.get_spatial_properties(self.sr3, properties) t_sp = self.sr3.times["Days"].iloc[sp_ind]
# The dimensions of grid nodes (+1 to the cells' dimensions) dim = np.array(self.sr3.grid.cart_dims) + 1 # Create the pyvista grid representation grid = pv.ExplicitStructuredGrid(dim, self.sr3.grid.cells.corners) grid = grid.compute_connectivity() grid = grid.compute_connections() grid = grid.compute_cell_sizes(length=False, area=False, volume=True) # Hide inactive cells grid.hide_cells(self.sr3.grid.cells.inactive, inplace=True) for property in properties: grid.cell_data[property] = sp[property][0] grid.scale([1, 1, 40], inplace=True) # Hide inactive cells grid.hide_cells(self.sr3.grid.cells.inactive, inplace=True) return grid`
Hi Sebastian, the current version does not support corner-point grids as the one you are using. But you are welcome to contribute :)
Applying the suggested workflow on an actual geological model (see first screenshot) results in a weird geometry (see second screenshot)
Method used for extracting the grid:
`def spatialProperties(self, properties): print(sr3_reader.list_spatial_properties(self.sr3)) (sp_ind, sp) = sr3_reader.get_spatial_properties(self.sr3, properties) t_sp = self.sr3.times["Days"].iloc[sp_ind]