Commit a8577c159ff4bb5e9a85481b2903551ac33da134
1 parent
0d9c23cf
Fix the exmaples to use good locations of xml models and calibration
Showing
4 changed files
with
11 additions
and
11 deletions
examples/make_binned_analysis.py
| @@ -46,11 +46,11 @@ def pipeline_v1(): | @@ -46,11 +46,11 @@ def pipeline_v1(): | ||
| 46 | in a ftools-like approach. | 46 | in a ftools-like approach. |
| 47 | """ | 47 | """ |
| 48 | # Set script parameters | 48 | # Set script parameters |
| 49 | - model_name = "${GAMMALIB}/share/models/crab.xml" | 49 | + model_name = "${CTOOLS}/share/models/crab.xml" |
| 50 | events_name = "events.fits" | 50 | events_name = "events.fits" |
| 51 | cntmap_name = "cntmap.fits" | 51 | cntmap_name = "cntmap.fits" |
| 52 | result_name = "results.xml" | 52 | result_name = "results.xml" |
| 53 | - caldb = "${GAMMALIB}/share/caldb/cta" | 53 | + caldb = "${CALDB}/data/cta/dummy/bcf" |
| 54 | irf = "cta_dummy_irf" | 54 | irf = "cta_dummy_irf" |
| 55 | ra = 83.63 | 55 | ra = 83.63 |
| 56 | dec = 22.01 | 56 | dec = 22.01 |
| @@ -151,8 +151,8 @@ def pipeline_v2(): | @@ -151,8 +151,8 @@ def pipeline_v2(): | ||
| 151 | At the end, results are plotted (if matplotlib is installed) | 151 | At the end, results are plotted (if matplotlib is installed) |
| 152 | """ | 152 | """ |
| 153 | # Set script parameters | 153 | # Set script parameters |
| 154 | - model_name = "${GAMMALIB}/share/models/crab.xml" | ||
| 155 | - caldb = "${GAMMALIB}/share/caldb/cta" | 154 | + model_name = "${CTOOLS}/share/models/crab.xml" |
| 155 | + caldb = "${CALDB}/data/cta/dummy/bcf" | ||
| 156 | irf = "cta_dummy_irf" | 156 | irf = "cta_dummy_irf" |
| 157 | ra = 83.63 | 157 | ra = 83.63 |
| 158 | dec = 22.01 | 158 | dec = 22.01 |
examples/make_pull_at_sensitivity_limit.py
| @@ -61,7 +61,7 @@ def create_pull(loge, emin, emax, models, ntrials=100, duration=180000.0, \ | @@ -61,7 +61,7 @@ def create_pull(loge, emin, emax, models, ntrials=100, duration=180000.0, \ | ||
| 61 | pull.models(models) | 61 | pull.models(models) |
| 62 | pull["outfile"] = outfile | 62 | pull["outfile"] = outfile |
| 63 | pull["ntrials"] = ntrials | 63 | pull["ntrials"] = ntrials |
| 64 | - pull["caldb"] = "$GAMMALIB/share/caldb/cta" | 64 | + pull["caldb"] = "${CALDB}/data/cta/dummy/bcf" |
| 65 | pull["irf"] = "cta_dummy_irf" | 65 | pull["irf"] = "cta_dummy_irf" |
| 66 | pull["ra"] = 83.6331 | 66 | pull["ra"] = 83.6331 |
| 67 | pull["dec"] = 22.0145 | 67 | pull["dec"] = 22.0145 |
examples/make_ts_distributions.py
| @@ -65,12 +65,12 @@ def create_ts(loge, emin, emax, ntrials=100, duration=180000.0, \ | @@ -65,12 +65,12 @@ def create_ts(loge, emin, emax, ntrials=100, duration=180000.0, \ | ||
| 65 | tsdist = cstsdist() | 65 | tsdist = cstsdist() |
| 66 | tsdist["outfile"] = outfile | 66 | tsdist["outfile"] = outfile |
| 67 | tsdist["ntrials"] = ntrials | 67 | tsdist["ntrials"] = ntrials |
| 68 | - tsdist["caldb"] = "$GAMMALIB/share/caldb/cta" | 68 | + tsdist["caldb"] = "${CALDB}/data/cta/dummy/bcf" |
| 69 | tsdist["irf"] = "cta_dummy_irf" | 69 | tsdist["irf"] = "cta_dummy_irf" |
| 70 | tsdist["type"] = "point" | 70 | tsdist["type"] = "point" |
| 71 | tsdist["index"] = -2.48 | 71 | tsdist["index"] = -2.48 |
| 72 | tsdist["offset"] = 0.0 | 72 | tsdist["offset"] = 0.0 |
| 73 | - tsdist["bkg"] = "$GAMMALIB/share/models/bkg_dummy.txt" | 73 | + tsdist["bkg"] = "${CTOOLS}/share/models/bkg_dummy.txt" |
| 74 | tsdist["emin"] = float(emin) | 74 | tsdist["emin"] = float(emin) |
| 75 | tsdist["emax"] = float(emax) | 75 | tsdist["emax"] = float(emax) |
| 76 | tsdist["enumbins"] = int(enumbins) | 76 | tsdist["enumbins"] = int(enumbins) |
examples/make_unbinned_analysis.py
| @@ -49,11 +49,11 @@ def pipeline_v1(): | @@ -49,11 +49,11 @@ def pipeline_v1(): | ||
| 49 | in a ftools-like approach. | 49 | in a ftools-like approach. |
| 50 | """ | 50 | """ |
| 51 | # Set script parameters | 51 | # Set script parameters |
| 52 | - model_name = "${GAMMALIB}/share/models/crab.xml" | 52 | + model_name = "${CTOOLS}/share/models/crab.xml" |
| 53 | events_name = "events.fits" | 53 | events_name = "events.fits" |
| 54 | selected_events_name = "selected_events.fits" | 54 | selected_events_name = "selected_events.fits" |
| 55 | result_name = "results.xml" | 55 | result_name = "results.xml" |
| 56 | - caldb = "${GAMMALIB}/share/caldb/cta" | 56 | + caldb = "${CALDB}/data/cta/dummy/bcf" |
| 57 | irf = "cta_dummy_irf" | 57 | irf = "cta_dummy_irf" |
| 58 | ra = 83.63 | 58 | ra = 83.63 |
| 59 | dec = 22.01 | 59 | dec = 22.01 |
| @@ -143,8 +143,8 @@ def pipeline_v2(show_data): | @@ -143,8 +143,8 @@ def pipeline_v2(show_data): | ||
| 143 | FITS files on disk. All data is only hold in memory. | 143 | FITS files on disk. All data is only hold in memory. |
| 144 | """ | 144 | """ |
| 145 | # Set script parameters | 145 | # Set script parameters |
| 146 | - model_name = "${GAMMALIB}/share/models/crab.xml" | ||
| 147 | - caldb = "${GAMMALIB}/share/caldb/cta" | 146 | + model_name = "${CTOOLS}/share/models/crab.xml" |
| 147 | + caldb = "${CALDB}/data/cta/dummy/bcf" | ||
| 148 | irf = "cta_dummy_irf" | 148 | irf = "cta_dummy_irf" |
| 149 | ra = 83.63 | 149 | ra = 83.63 |
| 150 | dec = 22.01 | 150 | dec = 22.01 |