def one_step(self, current_state, previous_kernel_results):
with tf.compat.v1.name_scope(<EOL>name=mcmc_util.make_name(self.name, '<STR_LIT>', '<STR_LIT>'),<EOL>values=[<EOL>self.step_size, self.max_doublings, self._seed_stream,<EOL>current_state, previous_kernel_results.target_log_prob<EOL>]):<EOL><INDENT>with tf.compat.v1.name_scope('<STR_LIT>'):<EOL><INDENT>[<EOL>current_state_parts,<EOL>step_sizes,<EOL>current_target_log_prob<EOL>] = _prepare_args(<EOL>self.target_log_prob_fn,<EOL>current_state,<EOL>self.step_size,<EOL>previous_kernel_results.target_log_prob,<EOL>maybe_expand=True)<EOL>max_doublings = tf.convert_to_tensor(<EOL>value=self.max_doublings, dtype=tf.int32, name='<STR_LIT>')<EOL><DEDENT>independent_chain_ndims = distribution_util.prefer_static_rank(<EOL>current_target_log_prob)<EOL>[<EOL>next_state_parts,<EOL>next_target_log_prob,<EOL>bounds_satisfied,<EOL>direction,<EOL>upper_bounds,<EOL>lower_bounds<EOL>] = _sample_next(<EOL>self.target_log_prob_fn,<EOL>current_state_parts,<EOL>step_sizes,<EOL>max_doublings,<EOL>current_target_log_prob,<EOL>independent_chain_ndims,<EOL>seed=self._seed_stream()<EOL>)<EOL>def maybe_flatten(x):<EOL><INDENT>return x if mcmc_util.is_list_like(current_state) else x[<NUM_LIT:0>]<EOL><DEDENT>return [<EOL>maybe_flatten(next_state_parts),<EOL>SliceSamplerKernelResults(<EOL>target_log_prob=next_target_log_prob,<EOL>bounds_satisfied=bounds_satisfied,<EOL>direction=direction,<EOL>upper_bounds=upper_bounds,<EOL>lower_bounds=lower_bounds<EOL>),<EOL>]<EOL><DEDENT>
Runs one iteration of Slice Sampler.

        Args:
          current_state: `Tensor` or Python `list` of `Tensor`s representing the
            current state(s) of the Markov chain(s). The first `r` dimensions
            index independent chains,
            `r = tf.rank(target_log_prob_fn(*current_state))`.
          previous_kernel_results: `collections.namedtuple` containing `Tensor`s
            representing values from previous calls to this function (or from the
            `bootstrap_results` function.)

        Returns:
          next_state: Tensor or Python list of `Tensor`s representing the state(s)
            of the Markov chain(s) after taking exactly one step. Has same type and
            shape as `current_state`.
          kernel_results: `collections.namedtuple` of internal calculations used to
            advance the chain.

        Raises:
          ValueError: if there isn't one `step_size` or a list with same length as
            `current_state`.
          TypeError: if `not target_log_prob.dtype.is_floating`.