Skip to content

Commit fbd44fb

Browse files
Change numerical evidence to log space.
1 parent 55c970e commit fbd44fb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

examples/rosenbrock.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -205,7 +205,7 @@ def run_example(
205205
"""
206206
Set up and run multiple simulations
207207
"""
208-
n_realisations = 1
208+
n_realisations = 100
209209
ln_evidence_inv_summary = np.zeros((n_realisations, 5))
210210
for i_realisation in range(n_realisations):
211211
if n_realisations > 1:
@@ -453,7 +453,7 @@ def run_example(
453453
if n_realisations > 1:
454454
save_name = (
455455
save_name_start
456-
+ "_rosenbrock_evidence_inv_T"
456+
+ "_rosenbrock_evidence_log_inv_T"
457457
+ str(temperature)
458458
+ "_realisations.dat"
459459
)
@@ -464,8 +464,8 @@ def run_example(
464464

465465
if ndim == 2:
466466
evidence_inv_analytic_summary = np.zeros(1)
467-
evidence_inv_analytic_summary[0] = 1.0 / evidence_numerical_integration
468-
save_name = save_name_start + "_rosenbrock_evidence_inv" + "_analytic.dat"
467+
evidence_inv_analytic_summary[0] = -np.log(evidence_numerical_integration)
468+
save_name = save_name_start + "_rosenbrock_evidence_log_inv" + "_analytic.dat"
469469
np.savetxt(
470470
save_name,
471471
evidence_inv_analytic_summary,

0 commit comments

Comments
 (0)