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 |
|
---|
7 | from pyfact import RawData
|
---|
8 | from drs_spikes import DRSSpikes_2D
|
---|
9 | import sys
|
---|
10 |
|
---|
11 | data_filename = 'data/20120223_210.fits.gz'
|
---|
12 | calib_filename = 'data/20120223_206.drs.fits.gz'
|
---|
13 |
|
---|
14 |
|
---|
15 | run = RawData(data_filename, calib_filename, return_dict = True, do_calibration=True)
|
---|
16 | despike = DRSSpikes_2D()
|
---|
17 |
|
---|
18 | for 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.