You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We could have a new class InitialConditionFromXDMF and remove the arguments label, time_step from InitialCondition.
This would make things less confusing and would make the implementation more straightforward, we now just have to check for the type of the initial condition object:
ifisintance(initial_condition, F.InitialConditon):
# do somethingelifisinstance(initial_condition, F.InitialConditionFromXDMF):
# do something else
The text was updated successfully, but these errors were encountered:
Currently we have the
InitialCondition
class that can be used for initialising fields with mathematical expressions or XDMF files.From an mathematical expression:
From a XDMFfile:
We then look check if
value
is a string and if it ends by.xdmf
and initialise fields accordingly:FESTIM/festim/concentration/concentration.py
Lines 43 to 47 in 31864c8
FESTIM/festim/temperature/temperature_solver.py
Lines 114 to 122 in 31864c8
Proposition
We could have a new class
InitialConditionFromXDMF
and remove the argumentslabel
,time_step
fromInitialCondition
.This would make things less confusing and would make the implementation more straightforward, we now just have to check for the type of the initial condition object:
The text was updated successfully, but these errors were encountered: