CUQI-DTU / CUQIpy

https://cuqi-dtu.github.io/CUQIpy/
Apache License 2.0
48 stars 9 forks source link

Acceptance rate for NUTS #474

Open Naokikiki opened 3 months ago

Naokikiki commented 3 months ago

Is your feature request related to a problem? Please describe.

Acceptance rate is not implemented for NUTS.The code below does not give us scalar value(For other sampling methods, it works) Apparently NUTSNew does not have acceptance rate too.


NUTS_donut = NUTS(target=target_donut, x0=np.array([0,0]))
Ns = 100
Nb = 1
NUTS_donuts_samples = NUTS_donut.sample(Ns, Nb)
NUTS_donuts_samples.acc_rate

Describe the solution you'd like

Implement AR as method of samples as the other sampling methods do.