Hi @luisroque
Please, can you run it like this?
with pm.Model() as basic_model:
theta = pm.Uniform('theta', lower=0, upper=1)
y = pm.Uniform('y', lower=0, upper=theta,
observed=[0.49131995252993826, 0.2774397121516236, 0.5381935236905224, 0.19753121107715765])
print(basic_model.check_test_point())
trace = pm.sample(1000, progressbar=True, chains=1, random_seed=1)
With that dataset, check_test_point returns the following:
theta_interval__ -1.39
y -inf
Name: Log-probability of test_point, dtype: float64
and when I do the sampling I get SamplingError("Bad initial energy").
I´ll update the original questions to use this code.
By the way, I took the model from the following example in the book Introduction to Probability by Bertsekas and Tsitsiklis (pp 414)
Romeo and Juliet start dating, but Juliet will be late on any
date by a random amount X, uniformly distributed over the interval [0,
theta]. The parameter theta is unknown and is modeled as the value of a random variable,
uniformly distributed between zero and one hour. Assuming that Juliet was late by
an amount x on their first date, how should Romeo use this information to update
the distribution of theta?
I can solve this problem analytically and I want to compare the analytical result with the one obtained by PyMC3.
Thanks