<br />

|---|
| [![](https://www.tensorflow.org/images/GitHub-Mark-32px.png) View source on GitHub](https://github.com/tensorflow/probability/blob/v0.25.0/tensorflow_probability/python/mcmc/hmc.py#L68-L172) |

Create a function implementing a step-size update policy. (deprecated)

    tfp.mcmc.make_simple_step_size_update_policy(
        num_adaptation_steps,
        target_rate=0.75,
        decrement_multiplier=0.01,
        increment_multiplier=0.01,
        step_counter=None
    )

### Used in the notebooks

| Used in the tutorials |
|---|
| - [Linear Mixed-Effect Regression in {TF Probability, R, Stan}](https://www.tensorflow.org/probability/examples/HLM_TFP_R_Stan) |

> [!WARNING]
> **Deprecated:** THIS FUNCTION IS DEPRECATED. It will be removed after 2019-05-22. Instructions for updating: Use tfp.mcmc.SimpleStepSizeAdaptation instead.

The simple policy increases or decreases the `step_size_var` based on the
average of `exp(minimum(0., log_accept_ratio))`. It is based on
[Section 4.2 of Andrieu and Thoms (2008)](https://people.eecs.berkeley.edu/%7Ejordan/sail/readings/andrieu-thoms.pdf).

The `num_adaptation_steps` argument is set independently of any burnin
for the overall chain. In general, adaptation prevents the chain from
reaching a stationary distribution, so obtaining consistent samples requires
`num_adaptation_steps` be set to a value [somewhat smaller](http://andrewgelman.com/2017/12/15/burn-vs-warm-iterative-simulation-algorithms/#comment-627745)
than the number of burnin steps. However, it may sometimes be helpful to set
`num_adaptation_steps` to a larger value during development in order to
inspect the behavior of the chain during adaptation.

<br />

<br />

<br />

| ## Args ||
|---|---|
| `num_adaptation_steps` | Scalar `int` `Tensor` number of initial steps to during which to adjust the step size. This may be greater, less than, or equal to the number of burnin steps. If `None`, the step size is adapted on every step (note this breaks stationarity of the chain!). |
| `target_rate` | Scalar `Tensor` representing desired `accept_ratio`. Default value: `0.75` (i.e., [center of asymptotically optimal rate](https://arxiv.org/abs/1411.6669)). |
| `decrement_multiplier` | `Tensor` representing amount to downscale current `step_size`. Default value: `0.01`. |
| `increment_multiplier` | `Tensor` representing amount to upscale current `step_size`. Default value: `0.01`. |
| `step_counter` | Scalar `int` `Variable` specifying the current step. The step size is adapted iff `step_counter < num_adaptation_steps`. Default value: if `None`, an internal variable `step_size_adaptation_step_counter` is created and initialized to `-1`. |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| `step_size_simple_update_fn` | Callable that takes args `step_size_var, kernel_results` and returns updated step size(s). |

<br />