Commit 17dfa01c306f139b999ebc70d438763f0c855888

Authored by Jürgen Knödlseder
1 parent 966c0985

Add usepnt parameter

Showing 1 changed file with 4 additions and 3 deletions
scripts/obsutils.py
... ... @@ -2,7 +2,7 @@
2 2 # This script provides a number of functions that are useful for handling
3 3 # CTA observations.
4 4 #
5   -# Copyright (C) 2011-2012 Juergen Knoedlseder
  5 +# Copyright (C) 2011-2013 Juergen Knoedlseder
6 6 #
7 7 # This program is free software: you can redistribute it and/or modify
8 8 # it under the terms of the GNU General Public License as published by
... ... @@ -80,6 +80,7 @@ def sim(obs, log=False, debug=False, seed=0, nbins=0, binsz=0.05, npix=200):
80 80 bin["emin"].real(emin)
81 81 bin["emax"].real(emax)
82 82 bin["enumbins"].integer(nbins)
  83 + bin["usepnt"].boolean(True) # Use pointing for map centre
83 84 bin["nxpix"].integer(npix)
84 85 bin["nypix"].integer(npix)
85 86 bin["binsz"].real(binsz)
... ... @@ -104,12 +105,12 @@ def sim(obs, log=False, debug=False, seed=0, nbins=0, binsz=0.05, npix=200):
104 105 obs = bin.obs().copy()
105 106  
106 107 else:
107   -
  108 +
108 109 # Make a deep copy of the observation that will be returned
109 110 # (the ctobssim object will go out of scope one the function is
110 111 # left)
111 112 obs = sim.obs().copy()
112   -
  113 +
113 114 # Delete the simulation
114 115 del sim
115 116  
... ...