-
Notifications
You must be signed in to change notification settings - Fork 24
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
GMSH workflow #885
GMSH workflow #885
Conversation
added GMSH workflow
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #885 +/- ##
==========================================
- Coverage 99.56% 99.55% -0.01%
==========================================
Files 61 60 -1
Lines 2750 2717 -33
==========================================
- Hits 2738 2705 -33
Misses 12 12 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @celyneira for this great contribution! As you can see on this link the documentation didn't compile properly:
https://festim--885.org.readthedocs.build/en/885/userguide/mesh.html#meshes-from-gmsh
I've added a bunch of comments with corrections.
You can alos check that the docs compile correctly locally by following the Documentation Guide
docs/source/userguide/mesh.rst
Outdated
import festim as F | ||
|
||
model = F.Simulation() | ||
|
||
model.mesh = F.MeshFromXDMF(volume_file ="volume_mesh.xdmf", boundary_file = "surface_mesh.xdmf") | ||
|
||
model.materials = [F.Material(id=1, D_0=1, E_D=0), | ||
F.Material(id=2, D_0=5, E_D=0)] | ||
|
||
model.T = F.Temperature(800) | ||
|
||
model.boundary_conditions = [F.DirichletBC(surfaces = [top_id], value = 1, field = 0), | ||
F.DirichletBC(surfaces = [inner_cylinder_surface_id], value = 0, field = 0)] | ||
|
||
model.exports = [F.XDMFExport("solute")] | ||
|
||
model.settings = F.Settings( | ||
absolute_tolerance=1e-10, | ||
relative_tolerance=1e-10, | ||
transient=False, | ||
) | ||
|
||
model.initialise() | ||
model.run() | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you format this code using black please?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks much better! I'll still need to run the tutorial to test things.
Could you format the python code blocks so that it conforms with black? Don't hesitate if you don't know how to do it
A few more comments
Co-authored-by: Rémi Delaporte-Mathurin <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested locally and confirm it works! Thanks so much @celyneira !!! 🎉
added GMSH workflow
Proposed changes
Describe the big picture of your changes here to communicate to the maintainers why we should accept this pull request. If it fixes a bug or resolves a feature request, be sure to link to that issue.
Types of changes
What types of changes does your code introduce to FESTIM?
Checklist
Further comments
If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...