pihnn.utils.scalar_loss#
- pihnn.utils.scalar_loss(boundary, model, t)#
Called by
pihnn.utils.PIHNNloss()if one aims to solve the Laplace or biharmonic problem.- Parameters:
boundary (
pihnn.geometries.boundary) – Domain boundary, needed to extract training and test points.model (
pihnn.nn.PIHNN/pihnn.nn.DD_PIHNN) – Neural network model.t (str) – Option for ‘training’ or ‘test’.
- Returns:
loss (float) - Computed loss.