source: fact/tools/pyscripts/sandbox/dneise/spike_studies/basic.py@ 13459

Last change on this file since 13459 was 13459, checked in by neise, 13 years ago
init
  • Property svn:executable set to *
File size: 516 bytes
Line 
1#!/usr/bin/python -tt
2#
3# Example
4# * looping over RawData class object
5#
6
7from pyfact import RawData
8from drs_spikes import DRSSpikes_2D
9import sys
10
11data_filename = 'data/20120223_210.fits.gz'
12calib_filename = 'data/20120223_206.drs.fits.gz'
13
14
15run = RawData(data_filename, calib_filename, return_dict = True, do_calibration=True)
16despike = DRSSpikes_2D()
17
18for event in run:
19 index = event['event_id'].value
20 print event['trigger_type'].value ,
21 if index == int(sys.argv[1]):
22 sys.exit(0)
23
Note: See TracBrowser for help on using the repository browser.