https://github.com/GPflow/GPflow
Revision c8e8f00e7d488784a09fe6d8fd8dc6632b6723bf authored by ilia-kats on 30 March 2020, 11:20:14 UTC, committed by GitHub on 30 March 2020, 11:20:14 UTC
Changes setattr_by_path to delete the attribute before setting it again.

When simply replacing a Parameter with tf.Constant, tensorflow
did not update its internal list of tracked variables, which prevented
deepcopying and pickling of frozen models. Explicitly deleting the
tracked variable before assigning a constant value forces tensorflow
to update its state.

Workaround for https://github.com/tensorflow/tensorflow/issues/37806
1 parent 0b9e1f0
History
Tip revision: c8e8f00e7d488784a09fe6d8fd8dc6632b6723bf authored by ilia-kats on 30 March 2020, 11:20:14 UTC
enable pickling of frozen models (#1338)
Tip revision: c8e8f00
File Mode Size
conditionals
config
covariances
expectations
inducing_variables
kernels
likelihoods
models
optimizers
utilities
__init__.py -rw-r--r-- 1.1 KB
base.py -rw-r--r-- 10.7 KB
ci_utils.py -rw-r--r-- 1.3 KB
kullback_leiblers.py -rw-r--r-- 5.8 KB
logdensities.py -rw-r--r-- 3.3 KB
mean_functions.py -rw-r--r-- 5.8 KB
monitor.py -rw-r--r-- 12.2 KB
probability_distributions.py -rw-r--r-- 1.7 KB
py.typed -rw-r--r-- 27 bytes
quadrature.py -rw-r--r-- 7.7 KB
versions.py -rw-r--r-- 177 bytes

back to top