Feature #1483

flag to distinguished background events from sources events

Added by Rodriguez Fernandez Gonzalo over 9 years ago. Updated over 7 years ago.

Status:ClosedStart date:06/26/2015
Priority:NormalDue date:
Assigned To:Knödlseder Jürgen% Done:

100%

Category:-
Target version:1.3.0
Duration:

Description

Hello,

I am using a python script to simulate a set of events using ctools.ctobssim (simulate_events.py).
After the simulation I can access to the events.
events = sim.obs()[0].events().copy()

where I have the energy and direction, ecc.

It would be very useful to know if the event was generated from background or from the source.
I would suggest to add a flag to distinguished events from background and sources.

Gonzalo.


Recurrence

No recurrence.

History

#1 Updated by Knödlseder Jürgen over 8 years ago

  • Target version set to 1.2.0

#2 Updated by Knödlseder Jürgen almost 8 years ago

  • Target version changed from 1.2.0 to 1.3.0

#3 Updated by Knödlseder Jürgen over 7 years ago

  • Status changed from New to In Progress
  • Assigned To set to Knödlseder Jürgen
  • % Done changed from 0 to 90
The following methods have been added to GammaLib to trace Monte Carlo information in an CTA event list:
  • GCTAEventList::has_mc_id(bool&): Signal availability of Monte Carlo information in an event list
  • GCTAEventList::has_mc_id(): Returns true if Monte Carlo information in an event list is available
  • GCTAEventList::set_mc_id_names(std::vector<int>&, std::vector<std::string>&): Set correspondance between Monte Carlo identifiers and model names
  • GCTAEventAtom::mc_id(int&): Set Monte Carlo identifier for an event
  • GCTAEventAtom::mc_id(): Returns Monte Carlo identifier for an event

The ctobssim tool now sets the Monte Carlo identifiers for every event

#4 Updated by Knödlseder Jürgen over 7 years ago

  • Status changed from In Progress to Closed
  • % Done changed from 90 to 100

Code is merged into devel

Also available in: Atom PDF