Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrap mesh tags from Python #2522

Merged
merged 52 commits into from
Feb 10, 2023
Merged

Wrap mesh tags from Python #2522

merged 52 commits into from
Feb 10, 2023

Conversation

garth-wells
Copy link
Member

@garth-wells garth-wells commented Feb 7, 2023

Wrap MeshTags from Python. Fixes #2519.

Also, a major simplification of building lists of entities to integrate over in fem::Form. This will allow changes on the Python side that will be more forgiving of (mesh tag) marker type.

@garth-wells garth-wells marked this pull request as ready for review February 7, 2023 09:54
@garth-wells garth-wells added bug Something isn't working enhancement New feature or request labels Feb 7, 2023
jpdean
jpdean previously requested changes Feb 7, 2023
cpp/dolfinx/fem/Form.h Outdated Show resolved Hide resolved
cpp/dolfinx/fem/Form.h Outdated Show resolved Hide resolved
cpp/dolfinx/fem/Form.h Show resolved Hide resolved
cpp/dolfinx/fem/Form.h Show resolved Hide resolved
cpp/dolfinx/fem/utils.h Outdated Show resolved Hide resolved
cpp/dolfinx/fem/utils.h Outdated Show resolved Hide resolved
@francesco-ballarin
Copy link
Member

Thanks @garth-wells, I'll test this with multiphenicsx and RBniCSx and leave my review afterwards.


new_meshtag = _cpp.refinement.transfer_cell_meshtag(meshtag, fine_mesh, parent_cell)

new_meshtag = _cpp.refinement.transfer_cell_meshtag(meshtag._cpp_object, fine_mesh, parent_cell)
Copy link
Sponsor Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess this indicates that we should wrap up refinement.transfer_cell_meshtag and refinement.transfer_facet_meshtag in the Python Layer.
This would probably be true for plaza_refine_data, as it returns a cpp.Mesh, which should be wrapped as a Python mesh.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This will need further work to sort out.

python/dolfinx/io/utils.py Outdated Show resolved Hide resolved
python/dolfinx/fem/forms.py Outdated Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Need to add dolfinx.mesh.MeshTagsMetaClass.mesh to python layer
4 participants