print "===> Chan/corr slicing reduces this to %10d visibilities (%.3g%% of selection)" % ( nvis_A, nvis_A * percent) if not (options.flagmask is None and options.flagmask_all is None and options.flagmask_none is None): print "===> Flag selection reduces this to %10d visibilities (%.3g%% of selection)" % ( nvis_B, nvis_B * percent) if options.nan or options.above is not None or options.below is not None or \ options.fm_above is not None or options.fm_below is not None: print "===> Data selection reduces this to %10d visibilities (%.3g%% of selection)" % ( nvis_C, nvis_C * percent) if unflagstr: print "===> (which were unflagged using flagmask %s)" % unflagstr if flagstr: print "===> (which were flagged using flagmask %s)" % flagstr flagger.close() # export flags from file, if so specified if options.export: try: dump = Owlcat.Tables.TableDump(options.export, write=True, compress=True) ms = get_ms() colnames = set(ms.colnames()) print "Exporting flags to %s, %d rows:" % (options.export, ms.nrows()) for colname in FLAGCOLS: if colname in colnames: dump.dump_column(ms, colname, verbose=True) ms.close()
if options.channels or options.corrs: print("===> Chan/corr slicing reduces this to %10d visibilities (%.3g%% of selection)" % ( nvis_A, nvis_A * percent)) if not (options.flagmask is None and options.flagmask_all is None and options.flagmask_none is None): print("===> Flag selection reduces this to %10d visibilities (%.3g%% of selection)" % ( nvis_B, nvis_B * percent)) if options.nan or options.above is not None or options.below is not None or \ options.fm_above is not None or options.fm_below is not None: print("===> Data selection reduces this to %10d visibilities (%.3g%% of selection)" % ( nvis_C, nvis_C * percent)) if unflagstr: print("===> (which were unflagged using flagmask %s)" % unflagstr) if flagstr: print("===> (which were flagged using flagmask %s)" % flagstr) flagger.close() # export flags from file, if so specified if options.export: try: dump = Owlcat.Tables.TableDump(options.export, write=True, compress=True) ms = get_ms() colnames = set(ms.colnames()) print("Exporting flags to %s, %d rows:" % (options.export, ms.nrows())) for colname in FLAGCOLS: if colname in colnames: dump.dump_column(ms, colname, verbose=True) ms.close() dump.close() except: traceback.print_exc()
print "===> (over which legacy flags were filled using flagmask %s)"%legacystr; percent = 100.0/sel_nvis if sel_nvis else 0; if options.channels or options.corrs: print "===> Chan/corr slicing reduces this to %10d visibilities (%.3g%% of selection)"%(nvis_A,nvis_A*percent); if not (options.flagmask is None and options.flagmask_all is None and options.flagmask_none is None): print "===> Flag selection reduces this to %10d visibilities (%.3g%% of selection)"%(nvis_B,nvis_B*percent); if options.nan or options.above is not None or options.below is not None or \ options.fm_above is not None or options.fm_below is not None: print "===> Data selection reduces this to %10d visibilities (%.3g%% of selection)"%(nvis_C,nvis_C*percent); if unflagstr: print "===> (which were unflagged using flagmask %s)"%unflagstr; if flagstr: print "===> (which were flagged using flagmask %s)"%flagstr; flagger.close(); # export flags from file, if so specified if options.export: try: dump = Owlcat.Tables.TableDump(options.export,write=True,compress=True); ms = get_ms(); colnames = set(ms.colnames()); print "Exporting flags to %s, %d rows:"%(options.export,ms.nrows()); for colname in FLAGCOLS: if colname in colnames: dump.dump_column(ms,colname,verbose=True); ms.close(); dump.close(); except: traceback.print_exc();