Commit d8fcfdf3c98ca08e800d737b9aadbebe1887f7ba
1 parent
fbc4599d
Query energy dispersion cube before background cube
Showing
2 changed files
with
4 additions
and
4 deletions
src/support/ctool.cpp
| ... | ... | @@ -985,6 +985,10 @@ void ctool::set_obs_response(GCTAObservation* obs) |
| 985 | 985 | // Get filenames |
| 986 | 986 | GFilename expcube((*this)["expcube"].filename()); |
| 987 | 987 | GFilename psfcube((*this)["psfcube"].filename()); |
| 988 | + GFilename edispcube; | |
| 989 | + if (query_edisp) { | |
| 990 | + edispcube = (*this)["edispcube"].filename(); | |
| 991 | + } | |
| 988 | 992 | GFilename bkgcube((*this)["bkgcube"].filename()); |
| 989 | 993 | |
| 990 | 994 | // Extract stacked response information if available |
| ... | ... | @@ -1004,9 +1008,6 @@ void ctool::set_obs_response(GCTAObservation* obs) |
| 1004 | 1008 | // query it now |
| 1005 | 1009 | if (query_edisp) { |
| 1006 | 1010 | |
| 1007 | - // Get filename | |
| 1008 | - GFilename edispcube((*this)["edispcube"].filename()); | |
| 1009 | - | |
| 1010 | 1011 | // If filename is valid then use energy dispersion ... |
| 1011 | 1012 | if ((gammalib::toupper(edispcube.url()) != "NONE") && |
| 1012 | 1013 | !edispcube.is_empty()) { | ... | ... |