ODEFlow
ODEFlow(score, lx=1.0, **kwargs)
Bases: GenericModelMixin, Model
Deterministic non-autonomous flow with linear degradation.
Parameters:
-
score(callable) –Score model kept for API consistency.
-
lx(float, default:1.0) –Linear degradation coefficient.
-
**kwargs(dict, default:{}) –Forwarded to
pfi.base.Model.
dim_output()
Return network output dimension.
Returns:
-
int–Spatial output dimension.
dim_spatial()
Return number of spatial dimension of the wrapped network.
Returns:
-
int–Number of spatial dimension in net_ (by definition the first dimensions).
evaluate_net(x)
Evaluate network with dimension selection, scaling, and transform.
Parameters:
-
x(Tensor) –Full input tensor including spatial coordinates and, by convention, time in the last coordinate.
Returns:
-
Tensor–Final model output after preprocessing and postprocessing.
init_model(X, generator=None)
Initialize network and normalization statistics from batched data.
Parameters:
-
X(Tensor) –Batched inputs with last dimension corresponding to features. By convention, time is stored in the last coordinate.
-
generator(Generator or None, default:None) –Optional RNG for reproducible weight initialization.
Returns:
-
Model–The initialized model instance.
is_autonomous()
Return False for non-autonomous models.
Returns:
-
bool–Always
False.
is_gradient()
Return False for non-gradient models.
Returns:
-
bool–Always
False.