Commit 02f82e70e06cc7bbf549cc671bc2090ed0c3b3af

Authored by Domenico Tiziani
1 parent 25718dff

Add stack parameter to ctbin

src/ctbin/ctbin.cpp
@@ -404,6 +404,7 @@ void ctbin::init_members(void) @@ -404,6 +404,7 @@ void ctbin::init_members(void)
404 // Initialise members 404 // Initialise members
405 m_outcube.clear(); 405 m_outcube.clear();
406 m_usepnt = false; 406 m_usepnt = false;
  407 + m_stack = true;
407 m_publish = false; 408 m_publish = false;
408 m_chatter = static_cast<GChatter>(2); 409 m_chatter = static_cast<GChatter>(2);
409 410
@@ -434,6 +435,7 @@ void ctbin::copy_members(const ctbin&amp; app) @@ -434,6 +435,7 @@ void ctbin::copy_members(const ctbin&amp; app)
434 // Copy attributes 435 // Copy attributes
435 m_outcube = app.m_outcube; 436 m_outcube = app.m_outcube;
436 m_usepnt = app.m_usepnt; 437 m_usepnt = app.m_usepnt;
  438 + m_stack = app.m_stack;
437 m_publish = app.m_publish; 439 m_publish = app.m_publish;
438 m_chatter = app.m_chatter; 440 m_chatter = app.m_chatter;
439 441
@@ -491,6 +493,9 @@ void ctbin::get_parameters(void) @@ -491,6 +493,9 @@ void ctbin::get_parameters(void)
491 // Get energy boundaries 493 // Get energy boundaries
492 m_ebounds = cube.ebounds(); 494 m_ebounds = cube.ebounds();
493 495
  496 + // Get stack parameter
  497 + m_stack = (*this)["stack"].boolean();
  498 +
494 // Get remaining parameters 499 // Get remaining parameters
495 m_publish = (*this)["publish"].boolean(); 500 m_publish = (*this)["publish"].boolean();
496 m_chatter = static_cast<GChatter>((*this)["chatter"].integer()); 501 m_chatter = static_cast<GChatter>((*this)["chatter"].integer());
src/ctbin/ctbin.hpp
@@ -91,6 +91,7 @@ protected: @@ -91,6 +91,7 @@ protected:
91 // User parameters 91 // User parameters
92 GFilename m_outcube; //!< Output counts map file name 92 GFilename m_outcube; //!< Output counts map file name
93 bool m_usepnt; //!< Use pointing instead of xref/yref parameters 93 bool m_usepnt; //!< Use pointing instead of xref/yref parameters
  94 + bool m_stack; //!< Output one stacked cube or multiple cubes
94 bool m_publish; //!< Publish counts cube? 95 bool m_publish; //!< Publish counts cube?
95 GChatter m_chatter; //!< Chattiness 96 GChatter m_chatter; //!< Chattiness
96 97
src/ctbin/ctbin.par
@@ -18,6 +18,7 @@ @@ -18,6 +18,7 @@
18 #=================== 18 #===================
19 inobs, f, a, events.fits,,, "Input event list or observation definition XML file" 19 inobs, f, a, events.fits,,, "Input event list or observation definition XML file"
20 outcube, f, a, cntcube.fits,,, "Output counts cube file" 20 outcube, f, a, cntcube.fits,,, "Output counts cube file"
  21 +stack, b, h, yes,,, "Stack events to one cube?"
21 22
22 # 23 #
23 # Energy binning parameters 24 # Energy binning parameters