Repository navigation
declearn v2.1.0
Release date: 02/03/2023
Release Highlights
Add proper GPU support and device-placement policy utils.
-
Add device-placement policy utils:
declearn.utils.DevicePolicy,declearn.utils.get_policyanddeclearn.utils.set_policy. -
Implement device-placement support in
TorchModel,TorchVector,TensorflowModelandTensorflowVector, according to shared API principles (some of which are abstracted intoModel). -
Add tests for these features, and automatic running of unit tests on both CPU and GPU when possible (otherwise, run on CPU only).
Add framework-specific TensorflowOptiModule and TorchOptiModule.
-
Enable wrapping framework-specific optimizer objects into a plug-in that may be used within a declearn
Optimizerand jointly with any combination of framework-agnostic plug-ins. -
Add functional tests that verify our implementations of the
Adam,AdagradandRMSpropoptimizers are equivalent to these of the Tensorflow and Torch frameworks.
Add declearn.metrics.RSquared metric to compute a regression's R^2.
Fix handling of frozen weights in TensorflowModel and TorchModel.
-
Add
trainable: bool=Falseparameter toModel.get_weightsandModel.set_weightsto enable excluding frozen weights from I/O. -
Use
Model.get_weights(trainable=True)inOptimizermethods, enabling to use loss-regularizationRegularizerplug-ins and weight decay with models that have some frozen weights. -
Use
Model.set_weights(trainable=True)and its counterpart to remove some unrequired communications and server-side aggregator and optimizer computations.
Fix handling of tf.IndexedSlices structures in TensorflowVector.
-
Avoid the (mostly silent, depending on tensorflow version) conversion of
tf.IndexedSlicesrow-sparse gradients to a dense tensor every time it can be avoided. -
Warn about that conversion when it happens (unless the contexts is known to require it, e.g. as part of noise-addition optimodules).
Full Release Notes
Release notes are available on our website and on the source GitLab repo.