mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 22:26:08 -04:00
Merge branch 'cylindermesh_to_vtk' of https://github.com/RemDelaporteMathurin/openmc into cylindermesh_to_vtk
This commit is contained in:
commit
8027b1622f
2 changed files with 2 additions and 2 deletions
|
|
@ -690,7 +690,7 @@ class RegularMesh(StructuredMesh):
|
|||
|
||||
# write the .vtk file
|
||||
writer = vtk.vtkStructuredGridWriter()
|
||||
writer.SetFileName(filename)
|
||||
writer.SetFileName(str(filename))
|
||||
writer.SetInputData(vtk_grid)
|
||||
writer.Write()
|
||||
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@ def test_write_data_to_vtk(mesh, tmpdir):
|
|||
# BUILD
|
||||
filename = tmpdir / "out.vtk"
|
||||
|
||||
data = np.random.random(mesh.dimension[0]*mesh.dimension[1]*mesh.dimension[2])
|
||||
data = np.random.random(mesh.num_mesh_cells)
|
||||
|
||||
# RUN
|
||||
mesh.write_data_to_vtk(filename=filename, datasets={"label1": data, "label2": data})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue