What’s New#
Attention
opinf
is a research code that is still in rapid development.
New versions may introduce substantial new features or API adjustments.
Changed in version 0.5.2: Significant updates to the pre
and basis
submodules.
Updates to pre
:
New
TransformerTemplate
class for defining custom transformers.Renamed
SnapshotTransformer
toShiftScaleTransformer
.Removed
SnapshotTransformerMulti
.New
TransformerMulti
class for joining multiple transformations.Renamed some attributes of the transformer classes:
n
->full_state_dimension
,ni
->variable_size
, etc.
Updates to basis
:
New
BasisTemplate
class for defining custom bases.Standardized arguments of
fit()
to always be the snapshots. Hyperparameters must come in the constructor.LinearBasis
now accepts an optional weight matrix.LinearBasis
raises a warning if the basis entries are not orthogonal (w.r.t. the weights).Updated
PODBasis
dimensionality properties. Useset_dimension()
to update the reduced state dimension on the fly.Removed
PODBasisMulti
.New
BasisMulti
multi class for joining multiple bases.Renamed some attributes of the basis classes (matching transformer syntax):
n
->full_state_dimension
,r
->reduced_state_dimension
, etc.
Added a new Literature page to the documentation listing Operator Inference publications.
New in version 0.5.1: New lift
module that defines a template class for implementing lifting transformations.
Changed in version 0.5.0:
Overhauled the
operators
module so that each operator class is responsible for its portion of the Operator Inference data matrix.New
StateInputOperator
for state-input bilinear interactions, \(\Nhat[\u\otimes\qhat]\).Operator classes now have
state_dimension
andinput_dimension
properties.Operator classes must implement
datablock()
andoperator_dimension()
methods to facilitate operator inference.
Renamed
roms
tomodels
and updated class names:ContinuousOpInfROM
toContinuousModel
DiscreteOpInfROM
toDiscreteModel
SteadyOpInfROM
toSteadyModel
Same for interpolated models.
Model classes now take a list of operators in the constructor. String shortcuts such as
"cAH"
are still valid, similar to the previousmodelform
argument. Theknown_operators
argument has been removed from thefit()
method.Model classes no longer have a
basis
attribute.The
basis
argument has been removed from thefit()
method.The
compress()
anddecompress()
methods have been removed from model classes.The dimensions
n
andr
have been replaced withstate_dimension
;m
is nowinput_dimension
.
Moved time derivative estimation tools to the new
ddt
submodule.Moved Kronecker product utilities to static methods of nonparametric operators.
utils.kron2c()
is nowQuadraticOperator.ckron()
utils.kron2c_indices()
is nowQuadraticOperator.ckron_indices()
utils.compress_quadratic()
is nowQuadraticOperator.compress_entries()
utils.expand_quadratic()
is nowQuadraticOperator.expand_entries()
utils.kron3c()
is nowCubicOperator.ckron()
utils.kron3c_indices()
is nowCubicOperator.ckron_indices()
utils.compress_cubic()
is nowCubicOperator.compress_entries()
utils.expand_cubic()
is nowCubicOperator.expand_entries()
Changed in version 0.4.5:
Moved basis classes and dimensionality reduction tools to a new
basis
submodule.Moved operator classes from
core.operators
to a newoperators
submodule.Renamed the
core
submodule toroms
.Moved time derivative estimation tools to the
utils
module.
Changed in version 0.4.4:
Fixed a bug in
SnapshotTransformer.load()
that treated thecentered_
attribute incorrectly.Removed the
transformer
attribute from basis classes.Renamed
encode()
tocompress()
anddecode()
todecompress()
.
Changed in version 0.4.2:
In the
fit()
method in ROM classes, replaced theregularizer
argument with asolver
keyword argument. The user should pass in an instantiation of a least-squares solver class from thelstsq
submodule.Hyperparameters for least-squares solver classes in the
lstsq
submodule are now passed to the constructor;predict()
must not take any arguments.Renamed the following least-squares solver classes in the
lstsq
submodule:SolverL2
->L2Solver
SolverL2Decoupled
->L2SolverDecoupled
SolverTikhonov
->TikhonovSolver
SolverTikhonovDecoupled
->TikhonovSolverDecoupled
Before:
>>> rom.fit(basis, states, ddts, inputs, regularizer=1e-2)
After:
>>> solver = opinf.lstsq.L2Solver(regularizer=1e-2)
>>> rom.fit(basis, states, ddts, inputs, solver=solver)
# The L2 solver is also the default if a float is given:
>>> rom.fit(basis, states, ddts, inputs, solver=1e-2)
Versions 0.4.0 and 0.4.1#
This version is a migration of the old rom_operator_inference
package, version 1.4.1.
See this page for the documentation.