Ejemplo n.º 1
0
#
# Make new time slides.
#

if options.verbose:
    print("Computing new time slides ...", file=sys.stderr)

# dictionary mapping time_slide_id --> (dictionary mapping insrument --> offset)

for offsetvect in timeslides.SlidesIter(
        timeslides.parse_slides(options.instrument)):
    time_slides[lsctables.TimeSlideTable.get_next_id()] = offsetvect
for inspiral_slidespec in options.inspiral_num_slides:
    for offsetvect in timeslides.Inspiral_Num_Slides_Iter(
            *timeslides.parse_inspiral_num_slides_slidespec(
                inspiral_slidespec)):
        time_slides[lsctables.TimeSlideTable.get_next_id()] = offsetvect

if options.verbose:
    print("Total of %d time slides." % len(time_slides), file=sys.stderr)

#
# Remove duplicates.
#

if options.verbose:
    print("Identifying and removing duplicates ...", file=sys.stderr)

map(
    time_slides.pop,
Ejemplo n.º 2
0
#
# Make new time slides.
#

if options.verbose:
    print >> sys.stderr, "Computing new time slides ..."

# dictionary mapping time_slide_id --> (dictionary mapping insrument --> offset)

for offsetvect in ligolw_tisi.SlidesIter(
        ligolw_tisi.parse_slides(options.instrument)):
    time_slides[lsctables.TimeSlideTable.get_next_id()] = offsetvect
for inspiral_slidespec in options.inspiral_num_slides:
    for offsetvect in ligolw_tisi.Inspiral_Num_Slides_Iter(
            *ligolw_tisi.parse_inspiral_num_slides_slidespec(
                inspiral_slidespec)):
        time_slides[lsctables.TimeSlideTable.get_next_id()] = offsetvect

if options.verbose:
    print >> sys.stderr, "Total of %d time slides." % len(time_slides)

#
# Remove duplicates.
#

if options.verbose:
    print >> sys.stderr, "Identifying and removing duplicates ..."

map(
    time_slides.pop,