https://github.com/GPflow/GPflow
Revision 056e59f2c5aa2b5021de9b7b91ce1cee2ea0bb92 authored by st-- on 06 February 2020, 17:06:04 UTC, committed by GitHub on 06 February 2020, 17:06:04 UTC
Parameter.__repr__ called .numpy() on the constrained and unconstrained representations - this throws an error when in graph mode (tf.function-wrapped), which can lead to errors-in-exception-handling, so this PR makes use of tf.eagerly_executing() to check whether we are in graph mode, and if so, only print shapes and dtype, not values.
1 parent 8dbf7ad
Tip revision: 056e59f2c5aa2b5021de9b7b91ce1cee2ea0bb92 authored by st-- on 06 February 2020, 17:06:04 UTC
fix Parameter.__repr__ behaviour within tf.function/graph mode (#1247)
fix Parameter.__repr__ behaviour within tf.function/graph mode (#1247)
Tip revision: 056e59f
File | Mode | Size |
---|---|---|
conditionals | ||
config | ||
covariances | ||
expectations | ||
inducing_variables | ||
kernels | ||
likelihoods | ||
models | ||
optimizers | ||
utilities | ||
__init__.py | -rw-r--r-- | 1.0 KB |
base.py | -rw-r--r-- | 9.5 KB |
ci_utils.py | -rw-r--r-- | 964 bytes |
kullback_leiblers.py | -rw-r--r-- | 4.7 KB |
logdensities.py | -rw-r--r-- | 3.0 KB |
mean_functions.py | -rw-r--r-- | 5.8 KB |
probability_distributions.py | -rw-r--r-- | 1.7 KB |
quadrature.py | -rw-r--r-- | 7.7 KB |
versions.py | -rw-r--r-- | 177 bytes |
Computing file changes ...