Skip to content

Commit ce008e6

Browse files
committed
add calibration of uncertainty method and link the appropriate images to readme
1 parent 4a11840 commit ce008e6

19 files changed

Lines changed: 122 additions & 45 deletions

papers/tutorial/calibration/README.md

Lines changed: 23 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -37,44 +37,52 @@ The following plots should be generated. The first one shows the training and te
3737
</p>
3838

3939

40-
## Calibration
40+
## Calibration with optimized likelihood uncertainty
4141

4242
For the calibration, we can use the true function or the surrogate model. The objective PDF is assumed to be noiseless. Even though the observation is noiseless, an uncertainty is computed to account for the missing physics.
43+
The likelihood uncertainty that represents the missing physics is optimized to ensure an uncertainty band overlap
4344

44-
Calibrate without a surrogate for `alpha=5, beta=5`: `python tut_calibration_all.py --alpha 5 --beta 5`
45+
Calibrate without a surrogate for `alpha=5, beta=5`: `python tut_calibration.py --alpha 5 --beta 5`
46+
Calibrate with a surrogate for `alpha=5, beta=5`: `python tut_calibration.py -useNN --alpha 5 --beta 5`
4547

4648
<p align="center">
47-
<img src="/papers/tutorial/calibration/assets/True_a_5_b_5_prop.png" width="225" height="187.5"/>
48-
<img src="/papers/tutorial/calibration/assets/True_a_5_b_5_corner.png" width="225" height="187.5"/>
49+
<img src="/papers/tutorial/calibration/assets/True_opt_a_5.0_b_5.0_prop.png" width="225" height="187.5"/>
50+
<img src="/papers/tutorial/calibration/assets/Surr_opt_a_5.0_b_5.0_prop.png" width="225" height="187.5"/>
4951
</p>
5052

5153

52-
Calibrate without a surrogate for `alpha=2, beta=5`: `python tut_calibration_all.py --alpha 2 --beta 5`
54+
Calibrate without a surrogate for `alpha=2, beta=5`: `python tut_calibration.py --alpha 2 --beta 5`
55+
Calibrate with a surrogate for `alpha=2, beta=5`: `python tut_calibration.py -useNN --alpha 2 --beta 5`
5356

5457

5558
<p align="center">
56-
<img src="/papers/tutorial/calibration/assets/True_a_2_b_5_prop.png" width="225" height="187.5"/>
57-
<img src="/papers/tutorial/calibration/assets/True_a_2_b_5_corner.png" width="225" height="187.5"/>
59+
<img src="/papers/tutorial/calibration/assets/True_opt_a_2.0_b_5.0_prop.png" width="225" height="187.5"/>
60+
<img src="/papers/tutorial/calibration/assets/Surr_opt_a_2.0_b_5.0_prop.png" width="225" height="187.5"/>
5861
</p>
5962

6063
Clearly, the amount of missing physics vary depending on the observations.
6164

62-
Then the same exercise can be done when using a neural net surrogate. Note that this step will not run if the `Building the surrogate` step was not done first
65+
Using surrogate gives similar predictions as when not using a surrogate. But the surrogate was constructed with 200 forward simulations.
66+
67+
## Calibration with calibrated likelihood uncertainty
6368

64-
Calibrate with a surrogate for `alpha=5, beta=5`: `python tut_calibration_all.py --useNN --alpha 5 --beta 5`
69+
The same suite can be done by calibrating the likelihood uncertainty in lieu of optimizing it (with a bissection search). This has the advantage of rapid calibration since only one calibration is needed. Here the uncertainty minimizes the negative log likelihood.
70+
71+
Calibrate without a surrogate for `alpha=5, beta=5`: `python tut_calibration.py -cal_err --alpha 5 --beta 5`
72+
Calibrate with a surrogate for `alpha=5, beta=5`: `python tut_calibration.py -useNN -cal_err --alpha 5 --beta 5`
6573

6674
<p align="center">
67-
<img src="/papers/tutorial/calibration/assets/Surr_a_5_b_5_prop.png" width="225" height="187.5"/>
68-
<img src="/papers/tutorial/calibration/assets/Surr_a_5_b_5_corner.png" width="225" height="187.5"/>
75+
<img src="/papers/tutorial/calibration/assets/True_cal_a_5.0_b_5.0_prop.png" width="225" height="187.5"/>
76+
<img src="/papers/tutorial/calibration/assets/Surr_cal_a_5.0_b_5.0_prop.png" width="225" height="187.5"/>
6977
</p>
7078

7179

72-
Calibrate with a surrogate for `alpha=2, beta=5`: `python tut_calibration_all.py --useNN --alpha 2 --beta 5`
80+
Calibrate without a surrogate for `alpha=2, beta=5`: `python tut_calibration.py -cal_err --alpha 2 --beta 5`
81+
Calibrate with a surrogate for `alpha=2, beta=5`: `python tut_calibration.py -useNN -cal_err --alpha 2 --beta 5`
7382

7483

7584
<p align="center">
76-
<img src="/papers/tutorial/calibration/assets/Surr_a_2_b_5_prop.png" width="225" height="187.5"/>
77-
<img src="/papers/tutorial/calibration/assets/Surr_a_2_b_5_corner.png" width="225" height="187.5"/>
85+
<img src="/papers/tutorial/calibration/assets/True_cal_a_2.0_b_5.0_prop.png" width="225" height="187.5"/>
86+
<img src="/papers/tutorial/calibration/assets/Surr_cal_a_2.0_b_5.0_prop.png" width="225" height="187.5"/>
7887
</p>
7988

80-
Using surrogate gives similar predictions as when not using a surrogate. But the surrogate was constructed with 200 forward simulations.
-16.6 KB
Binary file not shown.
-52.7 KB
Binary file not shown.
-15.9 KB
Binary file not shown.
-49.1 KB
Binary file not shown.
52.8 KB
Loading
48 KB
Loading
52.8 KB
Loading
48.9 KB
Loading
-16.4 KB
Binary file not shown.

0 commit comments

Comments
 (0)