geoprior.params.LearnableQ#

class geoprior.params.LearnableQ(initial_value=0.0, name=None, trainable=True, **kws)[source]#

Bases: BaseLearnable

Learnable Source/Sink term (Q).

Indicates that the PINN’s source/sink term \(Q\) should be learned (trainable) if TensorFlow is available; otherwise acts as a fixed NumPy‐based parameter. Unlike K and Ss, Q may be positive or negative, so we learn it directly (no log‐transform). The user supplies an initial_value, and the object initializes:

(1)#\[Q \;=\; ext{initial\_value}.\]

Unconstrained: may be positive or negative.

Examples

>>> q = LearnableQ(0.0)
>>> q.get_value()
0.0
Parameters:
__init__(initial_value=0.0, name=None, trainable=True, **kws)[source]#
Parameters:

Methods

__init__([initial_value, name, trainable])

from_config(config)

Re-instantiate from get_config().

get_config()

Return a JSON-serialisable dict for tf.keras.

get_value()

Return raw \(Q\) value.

__init__(initial_value=0.0, name=None, trainable=True, **kws)[source]#
Parameters:
get_value()[source]#

Return raw \(Q\) value.

Returns:

Source/sink strength.

Return type:

Union[Tensor, float]