fix problem doc

This commit is contained in:
giovanni
2025-03-13 12:04:02 +01:00
committed by Nicola Demo
parent 3606d2ef10
commit 66b49ea438
10 changed files with 120 additions and 102 deletions

View File

@@ -1,4 +1,4 @@
"""TODO"""
"""Module for implemented problems."""
__all__ = [
"SupervisedProblem",

View File

@@ -16,7 +16,7 @@ class AdvectionEquation(Equation):
def __init__(self, c):
"""
Initialize the advection equation.
Initialization of the :class:`AdvectionEquation`.
:param c: The advection velocity parameter.
:type c: float | int
@@ -80,7 +80,7 @@ class AdvectionProblem(SpatialProblem, TimeDependentProblem):
def __init__(self, c=1.0):
"""
Initialize the advection problem.
Initialization of the :class:`AdvectionProblem`.
:param c: The advection velocity parameter.
:type c: float | int

View File

@@ -16,7 +16,7 @@ class HelmholtzEquation(Equation):
def __init__(self, alpha):
"""
Initialize the Helmholtz equation.
Initialization of the :class:`HelmholtzEquation` class.
:param alpha: Parameter of the forcing term.
:type alpha: float | int
@@ -75,7 +75,7 @@ class HelmholtzProblem(SpatialProblem):
def __init__(self, alpha=3.0):
"""
Initialize the Helmholtz problem.
Initialization of the :class:`HelmholtzProblem` class.
:param alpha: Parameter of the forcing term.
:type alpha: float | int

View File

@@ -2,12 +2,11 @@
from ..abstract_problem import AbstractProblem
from ... import Condition
from ... import LabelTensor
class SupervisedProblem(AbstractProblem):
"""
Definition of a supervised learning problem in PINA.
Definition of a supervised-learning problem.
This class provides a simple way to define a supervised problem
using a single condition of type
@@ -28,7 +27,7 @@ class SupervisedProblem(AbstractProblem):
self, input_, output_, input_variables=None, output_variables=None
):
"""
Initialize the SupervisedProblem class.
Initialization of the :class:`SupervisedProblem` class.
:param input_: Input data of the problem.
:type input_: torch.Tensor | LabelTensor | Graph | Data