Skip to content

Commit

Permalink
add doc strings
Browse files Browse the repository at this point in the history
  • Loading branch information
aradermacher committed Oct 18, 2023
1 parent 63e425a commit 4eb6cc2
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions amworkflow/meshing/meshing.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,16 +128,16 @@ def create(
return

def create_mesh(self, mesh, cell_type: str, prune_z: bool = False) -> meshio.Mesh:
"""Convert msh file to xdmf file for fenic
"""Convert meshio mesh to fenics compatible mesh.
based on https://jsdokken.com/dolfinx-tutorial/chapter3/subdomains.html?highlight=read_mesh
Args:
mesh:
cell_type:
prune_z:
mesh: Mesh read by meshio from msh file (meshio.read(file_msh)).
cell_type: Type of cell to be meshed (e.g. 'tetra','triangle' ...).
prune_z: True for 2D meshes - removes z coordinate.
Returns:
out_mesh: Mesh which can be saved as xdmf file. (meshio.write(file_xdmf, out_mesh))
"""
cells = mesh.get_cells_type(cell_type)
cell_data = mesh.get_cell_data("gmsh:physical", cell_type)
Expand Down

0 comments on commit 4eb6cc2

Please sign in to comment.