Introduce devito.Zero to replace sympy.Zero in the FD layer
FabioLuporini opened this issue · comments
this way we avoid annoying try-excepts such as
try:
theta = model.theta
except AttributeError:
theta = 0
or
if theta != 0:
<expr>
It's not that simple
- first case has nothing do with FD layer, just the case where the model doesn't have a theta attribute only option is
try/catch
orgetattr
The second case has so many possibilities tracking them all would be quite a pain