Physical Scale
Physical Scale¤
neojax.data.scales.PhysicalScale
¤
Protocol for physical scaling logic.
Physical scales are used to non-dimensionalize inputs or outputs based on domain-specific physics (e.g., fluid dynamics, solid mechanics).
Info
To implement a custom scale, create a class
(an equinox.Module) that implements the get_scale method.
This method should return an array
compatible with the input shape x. The resulting scale object
can then be passed to a PhysicsNormalizer.
get_scale(x: Float[Array, ...], **kwargs: typing.Any) -> Array
¤
Returns the scaling factor(s) for the given input.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
x
|
Float[Array, ...]
|
The input array to be scaled. |
required |
**kwargs
|
Any
|
Additional parameters for the scaling logic. |
required |
Returns:
| Type | Description |
|---|---|
Array
|
The scaling array, which should be broadcast-compatible with |