<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/experimental/distributions/marginal_fns.py#L23-L48) |

Make a function that tries Cholesky then the user-specified function.

    tfp.experimental.distributions.marginal_fns.make_backoff_cholesky(
        alternate_cholesky, name='BackoffCholesky'
    )

> [!WARNING]
> **Warning:** This function uses an XLA-compiled [`tf.linalg.cholesky`](https://www.tensorflow.org/api_docs/python/tf/linalg/cholesky) to capture factorization failures.

<br />

<br />

<br />

| ## Args ||
|---|---|
| `alternate_cholesky` | A callable with the same signature as [`tf.linalg.cholesky`](https://www.tensorflow.org/api_docs/python/tf/linalg/cholesky). |
| `name` | Python `str` name prefixed to Ops created by this function. Default value: 'BackoffCholesky'. |

<br />

<br />

<br />

<br />

| ## Returns ||
|---|---|
| `run_backoff` | An function that attempts a standard Cholesky, and then tries `alternate_cholesky` on failure. |

<br />