From 5338ae3244b90f3fdd0cf10094937c09eb40fab9 Mon Sep 17 00:00:00 2001 From: Srinivas Vasudevan Date: Tue, 4 Oct 2022 09:41:56 -0700 Subject: [PATCH] Use tfp.random.rademacher as tfp.math.random_rademacher is deprecated. PiperOrigin-RevId: 478812076 --- examples/no_u_turn_sampler/nuts.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/no_u_turn_sampler/nuts.py b/examples/no_u_turn_sampler/nuts.py index 54475a2e..2de06b61 100644 --- a/examples/no_u_turn_sampler/nuts.py +++ b/examples/no_u_turn_sampler/nuts.py @@ -127,7 +127,7 @@ def kernel(target_log_prob_fn, # Grow the No-U-Turn Sampler trajectory by choosing a random direction and # simulating Hamiltonian dynamics in that direction. This extends either # the forward or reverse state. - direction = tfp.math.random_rademacher([1], seed=seed_stream()) + direction = tfp.random.rademacher([1], seed=seed_stream()) if direction < 0: [ reverse_state,