Nightly Per-Antenna Quality Summary Notebook¶

Josh Dillon, Last Revised February 2021

This notebooks brings together as much information as possible from ant_metrics, auto_metrics and redcal to help figure out which antennas are working properly and summarizes it in a single giant table. It is meant to be lightweight and re-run as often as necessary over the night, so it can be run when any of those is done and then be updated when another one completes.

In [1]:
import numpy as np
import matplotlib.pyplot as plt
import matplotlib
import pandas as pd
pd.set_option('display.max_rows', 1000)
from hera_qm.metrics_io import load_metric_file
from hera_cal import utils, io, redcal
import glob
import os
import h5py
from copy import deepcopy
from IPython.display import display, HTML
from hera_notebook_templates.utils import status_colors

%matplotlib inline
%config InlineBackend.figure_format = 'retina'
display(HTML("<style>.container { width:100% !important; }</style>"))
In [2]:
# If you want to run this notebook locally, copy the output of the next cell into the first few lines of this cell.

# JD = "2459122"
# data_path = '/lustre/aoc/projects/hera/H4C/2459122'
# ant_metrics_ext = ".ant_metrics.hdf5"
# redcal_ext = ".maybe_good.omni.calfits"
# nb_outdir = '/lustre/aoc/projects/hera/H4C/h4c_software/H4C_Notebooks/_rtp_summary_'
# os.environ["JULIANDATE"] = JD
# os.environ["DATA_PATH"] = data_path
# os.environ["ANT_METRICS_EXT"] = ant_metrics_ext
# os.environ["REDCAL_EXT"] = redcal_ext
# os.environ["NB_OUTDIR"] = nb_outdir
In [3]:
# Use environment variables to figure out path to data
JD = os.environ['JULIANDATE']
data_path = os.environ['DATA_PATH']
ant_metrics_ext = os.environ['ANT_METRICS_EXT']
redcal_ext = os.environ['REDCAL_EXT']
nb_outdir = os.environ['NB_OUTDIR']
print(f'JD = "{JD}"')
print(f'data_path = "{data_path}"')
print(f'ant_metrics_ext = "{ant_metrics_ext}"')
print(f'redcal_ext = "{redcal_ext}"')
print(f'nb_outdir = "{nb_outdir}"')
JD = "2459755"
data_path = "/mnt/sn1/2459755"
ant_metrics_ext = ".ant_metrics.hdf5"
redcal_ext = ".known_good.omni.calfits"
nb_outdir = "/home/obs/src/H5C_Notebooks/_rtp_summary_"
In [4]:
from astropy.time import Time
utc = Time(JD, format='jd').datetime
print(f'Date: {utc.month}-{utc.day}-{utc.year}')
Date: 6-24-2022
In [5]:
# Per-season options
def ant_to_report_url(ant):
    return f'https://htmlpreview.github.io/?https://github.com/HERA-Team/H5C_Notebooks/blob/main/antenna_report/antenna_{ant}_report.html'

Load Auto Metrics¶

In [6]:
use_auto_metrics = False

# find the auto_metrics file
glob_str = os.path.join(data_path, f'zen.{JD}*.auto_metrics.h5')
auto_metrics_file = sorted(glob.glob(glob_str))

# if it exists, load and extract relevant information
if len(auto_metrics_file) > 0:
    auto_metrics_file = auto_metrics_file[0]
    print(f'Found auto_metrics results file at {auto_metrics_file}.')
    
    auto_metrics = load_metric_file(auto_metrics_file)
    mean_round_modz_cut = auto_metrics['parameters']['mean_round_modz_cut']
    auto_ex_ants = auto_metrics['ex_ants']['r2_ex_ants']
    
    use_auto_metrics = True
else:
    print(f'No files found matching glob {glob_str}. Skipping auto_metrics.')
Found auto_metrics results file at /mnt/sn1/2459755/zen.2459755.25305.sum.auto_metrics.h5.

Load Ant Metrics¶

In [7]:
use_ant_metrics = False

# get a list of all ant_metrics files
glob_str = os.path.join(data_path, f'zen.{JD}.?????.sum{ant_metrics_ext}')
ant_metrics_files = sorted(glob.glob(glob_str))

# if they exist, load as many of them as possible
if len(ant_metrics_files) > 0:
    print(f'Found {len(ant_metrics_files)} ant_metrics files matching glob {glob_str}')
    ant_metrics_apriori_exants = {}
    ant_metrics_xants_dict = {}
    ant_metrics_dead_ants_dict = {}
    ant_metrics_crossed_ants_dict = {}
    ant_metrics_dead_metrics = {}
    ant_metrics_crossed_metrics = {}
    dead_cuts = {}
    crossed_cuts = {}
    for amf in ant_metrics_files:
        with h5py.File(amf, "r") as infile: # use h5py directly since it's much faster than load_metric_file
            # get out results for this file
            dead_cuts[amf] = infile['Metrics']['dead_ant_cut'][()]
            crossed_cuts[amf] = infile['Metrics']['cross_pol_cut'][()]
            xants = infile['Metrics']['xants'][:]
            dead_ants = infile['Metrics']['dead_ants'][:]
            crossed_ants = infile['Metrics']['crossed_ants'][:]        
            try:
                # look for ex_ants in history
                ex_ants_string = infile['Header']['history'][()].decode()
                ex_ants_string = ex_ants_string.split('--apriori_xants')[1]
                ex_ants_string = ex_ants_string.split('--')[0].strip()
            except:
                ex_ants_string = ''
                    
            # This only works for the new correlation-matrix-based ant_metrics
            if 'corr' in infile['Metrics']['final_metrics'] and 'corrXPol' in infile['Metrics']['final_metrics']:
                ant_metrics_dead_metrics[amf] = {eval(ant): infile['Metrics']['final_metrics']['corr'][ant][()]
                                                 for ant in infile['Metrics']['final_metrics']['corr']}
                ant_metrics_crossed_metrics[amf] = {eval(ant): infile['Metrics']['final_metrics']['corrXPol'][ant][()]
                                                    for ant in infile['Metrics']['final_metrics']['corrXPol']}                       
            else:
                raise(KeywordError)
        
        # organize results by file
        ant_metrics_xants_dict[amf] = [(int(ant[0]), ant[1].decode()) for ant in xants]
        ant_metrics_dead_ants_dict[amf] = [(int(ant[0]), ant[1].decode()) for ant in dead_ants]
        ant_metrics_crossed_ants_dict[amf] = [(int(ant[0]), ant[1].decode()) for ant in crossed_ants]
        ant_metrics_apriori_exants[amf] = [int(ant) for ant in ex_ants_string.split()]
    
    dead_cut = np.median(list(dead_cuts.values()))
    crossed_cut = np.median(list(crossed_cuts.values()))
        
    use_ant_metrics = True
else:
    print(f'No files found matching glob {glob_str}. Skipping ant_metrics.')
Found 372 ant_metrics files matching glob /mnt/sn1/2459755/zen.2459755.?????.sum.ant_metrics.hdf5

Load chi^2 info from redcal¶

In [8]:
use_redcal = False
glob_str = os.path.join(data_path, f'zen.{JD}.?????.sum{redcal_ext}')

redcal_files = sorted(glob.glob(glob_str))
if len(redcal_files) > 0:
    print(f'Found {len(redcal_files)} ant_metrics files matching glob {glob_str}')
    post_redcal_ant_flags_dict = {}
    flagged_by_redcal_dict = {}
    cspa_med_dict = {}
    for cal in redcal_files:
        hc = io.HERACal(cal)
        _, flags, cspa, chisq = hc.read()
        cspa_med_dict[cal] = {ant: np.nanmedian(cspa[ant], axis=1) for ant in cspa}

        post_redcal_ant_flags_dict[cal] = {ant: np.all(flags[ant]) for ant in flags}
        # check history to distinguish antennas flagged going into redcal from ones flagged during redcal
        tossed_antenna_lines =  hc.history.replace('\n','').split('Throwing out antenna ')[1:]
        flagged_by_redcal_dict[cal] = sorted([int(line.split(' ')[0]) for line in tossed_antenna_lines])
        
    use_redcal = True
else:
    print(f'No files found matching glob {glob_str}. Skipping redcal chisq.')
Found 38 ant_metrics files matching glob /mnt/sn1/2459755/zen.2459755.?????.sum.known_good.omni.calfits

Figure out some general properties¶

In [9]:
# Parse some general array properties, taking into account the fact that we might be missing some of the metrics
ants = []
pols = []
antpol_pairs = []

if use_auto_metrics:
    ants = sorted(set(bl[0] for bl in auto_metrics['modzs']['r2_shape_modzs']))
    pols = sorted(set(bl[2] for bl in auto_metrics['modzs']['r2_shape_modzs']))
if use_ant_metrics:
    antpol_pairs = sorted(set([antpol for dms in ant_metrics_dead_metrics.values() for antpol in dms.keys()]))
    antpols = sorted(set(antpol[1] for antpol in antpol_pairs))
    ants = sorted(set(antpol[0] for antpol in antpol_pairs) | set(ants))
    pols = sorted(set(utils.join_pol(ap, ap) for ap in antpols) | set(pols))
if use_redcal:
    antpol_pairs = sorted(set([ant for cspa in cspa_med_dict.values() for ant in cspa.keys()]) | set(antpol_pairs))
    antpols = sorted(set(antpol[1] for antpol in antpol_pairs))
    ants = sorted(set(antpol[0] for antpol in antpol_pairs) | set(ants))
    pols = sorted(set(utils.join_pol(ap, ap) for ap in antpols) | set(pols))

# Figure out remaining antennas not in data
hd = io.HERAData(sorted(glob.glob(os.path.join(data_path, 'zen.*.sum.uvh5')))[0])
unused_ants = [ant for ant in hd.antpos if ant not in ants]    

Load a priori antenna statuses and node numbers¶

In [10]:
# try to load a priori antenna statusesm but fail gracefully if this doesn't work.
a_priori_statuses = {ant: 'Not Found' for ant in ants}
nodes = {ant: np.nan for ant in ants + unused_ants}
try:
    from hera_mc import cm_hookup

    # get node numbers
    hookup = cm_hookup.get_hookup('default')
    for ant_name in hookup:
        ant = int("".join(filter(str.isdigit, ant_name)))
        if ant in nodes:
            if hookup[ant_name].get_part_from_type('node')['E<ground'] is not None:
                nodes[ant] = int(hookup[ant_name].get_part_from_type('node')['E<ground'][1:])
    
    # get apriori antenna status
    for ant_name, data in hookup.items():
        ant = int("".join(filter(str.isdigit, ant_name)))
        if ant in a_priori_statuses:
            a_priori_statuses[ant] = data.apriori

except Exception as err:
    print(f'Could not load node numbers and a priori antenna statuses.\nEncountered {type(err)} with message: {err}')

Summarize auto metrics¶

In [11]:
if use_auto_metrics:
    # Parse modzs
    modzs_to_check = {'Shape': 'r2_shape_modzs', 'Power': 'r2_power_modzs', 
                      'Temporal Variability': 'r2_temp_var_modzs', 'Temporal Discontinuties': 'r2_temp_diff_modzs'}
    worst_metrics = []
    worst_zs = []
    all_modzs = {}
    binary_flags = {rationale: [] for rationale in modzs_to_check}

    for ant in ants:
        # parse modzs and figure out flag counts
        modzs = {f'{pol} {rationale}': auto_metrics['modzs'][dict_name][(ant, ant, pol)] 
                 for rationale, dict_name in modzs_to_check.items() for pol in pols}
        for pol in pols:
            for rationale, dict_name in modzs_to_check.items():
                binary_flags[rationale].append(auto_metrics['modzs'][dict_name][(ant, ant, pol)] > mean_round_modz_cut)

        # parse out all metrics for dataframe
        for k in modzs:
            col_label = k + ' Modified Z-Score'
            if col_label in all_modzs:
                all_modzs[col_label].append(modzs[k])
            else:
                all_modzs[col_label] = [modzs[k]]
                
    mean_round_modz_cut = auto_metrics['parameters']['mean_round_modz_cut']
else:
    mean_round_modz_cut = 0

Summarize ant metrics¶

In [12]:
if use_ant_metrics:
    a_priori_flag_frac = {ant: np.mean([ant in apxa for apxa in ant_metrics_apriori_exants.values()]) for ant in ants}
    dead_ant_frac = {ap: {ant: np.mean([(ant, ap) in das for das in ant_metrics_dead_ants_dict.values()])
                                 for ant in ants} for ap in antpols}
    crossed_ant_frac = {ant: np.mean([np.any([(ant, ap) in cas for ap in antpols])
                                      for cas in ant_metrics_crossed_ants_dict.values()]) for ant in ants}
    ant_metrics_xants_frac_by_antpol = {antpol: np.mean([antpol in amx for amx in ant_metrics_xants_dict.values()]) for antpol in antpol_pairs}
    ant_metrics_xants_frac_by_ant = {ant: np.mean([np.any([(ant, ap) in amx for ap in antpols])
                                     for amx in ant_metrics_xants_dict.values()]) for ant in ants}
    average_dead_metrics = {ap: {ant: np.nanmean([dm.get((ant, ap), np.nan) for dm in ant_metrics_dead_metrics.values()]) 
                                 for ant in ants} for ap in antpols}
    average_crossed_metrics = {ant: np.nanmean([cm.get((ant, ap), np.nan) for ap in antpols 
                                                for cm in ant_metrics_crossed_metrics.values()]) for ant in ants}
else:
    dead_cut = 0.4
    crossed_cut = 0.0

Summarize redcal chi^2 metrics¶

In [13]:
if use_redcal:
    cspa = {ant: np.nanmedian(np.hstack([cspa_med_dict[cal][ant] for cal in redcal_files])) for ant in antpol_pairs}
    redcal_prior_flag_frac = {ant: np.mean([np.any([afd[ant, ap] and not ant in flagged_by_redcal_dict[cal] for ap in antpols])
                                            for cal, afd in post_redcal_ant_flags_dict.items()]) for ant in ants}
    redcal_flagged_frac = {ant: np.mean([ant in fbr for fbr in flagged_by_redcal_dict.values()]) for ant in ants}

Build DataFrame¶

In [14]:
# build dataframe
to_show = {'Ant': [f'<a href="{ant_to_report_url(ant)}" target="_blank">{ant}</a>' for ant in ants],
           'Node': [nodes[ant] for ant in ants], 
           'A Priori Status': [a_priori_statuses[ant] for ant in ants]}
           #'Worst Metric': worst_metrics, 'Worst Modified Z-Score': worst_zs}
df = pd.DataFrame(to_show)

# create bar chart columns for flagging percentages:
bar_cols = {}
if use_auto_metrics:
    bar_cols['Auto Metrics Flags'] = [float(ant in auto_ex_ants) for ant in ants]
if use_ant_metrics:
    if np.sum(list(a_priori_flag_frac.values())) > 0:  # only include this col if there are any a priori flags
        bar_cols['A Priori Flag Fraction in Ant Metrics'] = [a_priori_flag_frac[ant] for ant in ants]
    for ap in antpols:
        bar_cols[f'Dead Fraction in Ant Metrics ({ap})'] = [dead_ant_frac[ap][ant] for ant in ants]
    bar_cols['Crossed Fraction in Ant Metrics'] = [crossed_ant_frac[ant] for ant in ants]
if use_redcal:
    bar_cols['Flag Fraction Before Redcal'] = [redcal_prior_flag_frac[ant] for ant in ants]
    bar_cols['Flagged By Redcal chi^2 Fraction'] = [redcal_flagged_frac[ant] for ant in ants]  
for col in bar_cols:
    df[col] = bar_cols[col]

# add auto_metrics
if use_auto_metrics:
    for label, modz in all_modzs.items():
        df[label] = modz
z_score_cols = [col for col in df.columns if 'Modified Z-Score' in col]        
        
# add ant_metrics
ant_metrics_cols = {}
if use_ant_metrics:
    for ap in antpols:
        ant_metrics_cols[f'Average Dead Ant Metric ({ap})'] = [average_dead_metrics[ap][ant] for ant in ants]
    ant_metrics_cols['Average Crossed Ant Metric'] = [average_crossed_metrics[ant] for ant in ants]
    for col in ant_metrics_cols:
        df[col] = ant_metrics_cols[col]   

# add redcal chisq
redcal_cols = []
if use_redcal:
    for ap in antpols:
        col_title = f'Median chi^2 Per Antenna ({ap})'
        df[col_title] = [cspa[ant, ap] for ant in ants]
        redcal_cols.append(col_title)

# sort by node number and then by antenna number within nodes
df.sort_values(['Node', 'Ant'], ascending=True)

# style dataframe
table = df.style.hide_index()\
          .applymap(lambda val: f'background-color: {status_colors[val]}' if val in status_colors else '', subset=['A Priori Status']) \
          .background_gradient(cmap='viridis', vmax=mean_round_modz_cut * 3, vmin=0, axis=None, subset=z_score_cols) \
          .background_gradient(cmap='bwr_r', vmin=dead_cut-.25, vmax=dead_cut+.25, axis=0, subset=list([col for col in ant_metrics_cols if 'dead' in col.lower()])) \
          .background_gradient(cmap='bwr_r', vmin=crossed_cut-.25, vmax=crossed_cut+.25, axis=0, subset=list([col for col in ant_metrics_cols if 'crossed' in col.lower()])) \
          .background_gradient(cmap='plasma', vmax=4, vmin=1, axis=None, subset=redcal_cols) \
          .applymap(lambda val: 'font-weight: bold' if val < dead_cut else '', subset=list([col for col in ant_metrics_cols if 'dead' in col.lower()])) \
          .applymap(lambda val: 'font-weight: bold' if val < crossed_cut else '', subset=list([col for col in ant_metrics_cols if 'crossed' in col.lower()])) \
          .applymap(lambda val: 'font-weight: bold' if val > mean_round_modz_cut else '', subset=z_score_cols) \
          .applymap(lambda val: 'color: red' if val > mean_round_modz_cut else '', subset=z_score_cols) \
          .bar(subset=list(bar_cols.keys()), vmin=0, vmax=1) \
          .format({col: '{:,.4f}'.format for col in z_score_cols}) \
          .format({col: '{:,.4f}'.format for col in ant_metrics_cols}) \
          .format({col: '{:,.2%}'.format for col in bar_cols}) \
          .applymap(lambda val: 'font-weight: bold', subset=['Ant']) \
          .set_table_styles([dict(selector="th",props=[('max-width', f'70pt')])]) \

Table 1: RTP Per-Antenna Metrics Summary Table¶

This admittedly very busy table incorporates summary information about all antennas in the array. Its columns depend on what information is available when the notebook is run (i.e. whether auto_metrics, ant_metrics, and/or redcal is done). These can be divided into 5 sections:

Basic Antenna Info: antenna number, node, and its a priori status.

Flag Fractions: Fraction of the night that an antenna was flagged for various reasons. Note that auto_metrics flags antennas for the whole night, so it'll be 0% or 100%.

auto_metrics Details: If auto_metrics is included, this section shows the modified Z-score signifying how much of an outlier each antenna and polarization is in each of four categories: bandpass shape, overall power, temporal variability, and temporal discontinuities. Bold red text indicates that this is a reason for flagging the antenna. It is reproduced from the auto_metrics_inspect.ipynb nightly notebook, so check that out for more details on the precise metrics.

ant_metrics Details: If ant_metrics is included, this section shows the average correlation-based metrics for antennas over the whole night. Low "dead ant" metrics (nominally below 0.4) indicate antennas not correlating with the rest of the array. Negative "crossed ant" metrics indicate antennas that show stronger correlations in their cross-pols than their same-pols, indicating that the two polarizations are probably swapped. Bold text indicates that the average is below the threshold for flagging.

redcal chi^2 Details: If redcal is included, this shows the median chi^2 per antenna. This would be 1 in an ideal array. Antennas are thrown out when they they are outliers in their median chi^2, usually greater than 4-sigma outliers in modified Z-score.

In [15]:
HTML(table.render())
Out[15]:
Ant Node A Priori Status Auto Metrics Flags Dead Fraction in Ant Metrics (Jee) Dead Fraction in Ant Metrics (Jnn) Crossed Fraction in Ant Metrics Flag Fraction Before Redcal Flagged By Redcal chi^2 Fraction ee Shape Modified Z-Score nn Shape Modified Z-Score ee Power Modified Z-Score nn Power Modified Z-Score ee Temporal Variability Modified Z-Score nn Temporal Variability Modified Z-Score ee Temporal Discontinuties Modified Z-Score nn Temporal Discontinuties Modified Z-Score Average Dead Ant Metric (Jee) Average Dead Ant Metric (Jnn) Average Crossed Ant Metric Median chi^2 Per Antenna (Jee) Median chi^2 Per Antenna (Jnn)
0 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 15.293529 4.049352 55.415914 56.357928 5262.671431 8089.761198 6195.573062 7957.085083 0.018138 0.016384 0.002110 0.984266 0.967618
1 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 84.677729 72.797873 85.037889 74.246884 96.274345 94.638212 960.638399 910.575806 0.016154 0.016395 0.000247 1.036096 1.041080
2 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 60.115429 59.437064 77.744902 66.961965 78.291309 41.964020 799.821418 410.343854 0.016535 0.016682 0.000430 1.064571 1.065828
3 1 RF_maintenance 0.00% 0.00% 0.00% 0.00% 100.00% 0.00% 3.783247 -0.345843 -0.419788 -0.761806 -0.769863 -0.419028 -0.255321 -0.340967 0.583527 0.582536 0.361845 3.856080 4.013863
4 1 RF_maintenance 0.00% 0.00% 0.00% 0.00% 100.00% 0.00% 0.317275 2.035753 0.242918 0.378678 -0.663687 -0.221188 1.044882 0.691320 0.597190 0.579983 0.366056 6.740858 7.418110
5 1 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% 0.002617 -0.639549 0.155159 -0.519625 -0.129498 -0.511495 0.594953 -1.141676 0.597802 0.573847 0.366645 1.690081 1.811281
7 2 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.580076 -0.886255 -0.113823 -0.035343 -1.059749 0.376549 0.430912 7.558079 0.095232 0.088173 0.019040 1.144231 1.142795
8 2 RF_maintenance 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% 1.955426 1.737862 2.395850 2.672018 2.508734 2.696866 0.311809 -1.797214 0.090498 0.077963 0.013720 1.170857 1.170802
9 2 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.617408 -0.791676 0.005115 0.105357 0.159297 0.490807 -0.496763 -0.262561 0.066021 0.058182 0.007239 1.158219 1.155039
10 2 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -1.225259 -0.907290 -0.251616 -0.216258 0.410371 1.158089 -0.986351 -0.282450 0.100899 0.076788 0.016458 1.159314 1.161581
11 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 96.539975 99.285908 76.765994 80.721173 77.457699 81.292823 660.560530 771.426714 0.018189 0.017268 0.000850 1.027309 1.028723
12 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 103.628987 67.168968 83.171683 74.153018 109.950924 68.464920 1049.266307 640.814575 0.018219 0.017422 0.000320 1.037548 1.039403
13 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 77.351589 59.279878 76.656834 78.726527 86.767872 82.976723 680.898229 802.202140 0.018170 0.017211 0.000769 1.064965 1.058408
14 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 66.367048 77.293199 69.028780 71.001201 82.993082 74.687042 601.750749 576.507405 0.018062 0.017340 0.000711 1.058285 1.058014
15 1 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% -0.179045 -0.092902 0.570957 0.072866 1.484281 1.336141 0.844018 7.725857 0.617421 0.606312 0.356113 5.072803 5.070457
16 1 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -0.568916 -1.534453 -0.258012 -1.122685 0.077740 -0.567219 2.412731 0.420736 0.620163 0.610224 0.356634 1.650873 1.610041
17 1 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 1.114874 8.457139 0.237851 1.040324 2.689046 2.064381 11.112499 3.475365 0.603719 0.583150 0.349887 9.482701 11.609920
18 1 RF_maintenance 100.00% 0.00% 56.99% 0.00% 100.00% 0.00% 1.628276 7.181653 -0.035761 0.036808 20.148707 16.617199 71.666518 59.512480 0.572832 0.371604 0.394455 3.382611 2.146159
19 2 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.584287 1.611322 0.279591 2.204185 -0.363484 -0.135457 -1.409943 -2.201425 0.077192 0.079151 0.011495 1.193729 1.185333
20 2 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% 0.345748 0.171395 0.943784 -0.943613 2.151026 -0.714582 -0.003232 -0.742558 0.054456 0.059742 0.005118 1.147700 1.146227
21 2 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 0.774609 1.758542 0.439067 4.144409 15.912991 18.432122 20.835229 34.853959 0.065930 0.058239 0.005897 1.188700 1.191297
23 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 57.534209 62.763813 79.455701 69.996152 97.583826 54.891151 839.847454 579.829773 0.017099 0.016775 0.000425 1.088548 1.091326
24 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 71.549288 85.730639 89.117206 68.889631 137.299499 41.472431 1212.663065 405.801584 0.016323 0.016671 0.000470 1.074425 1.078253
25 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 295.659616 296.599277 inf inf 80.638821 159.533618 644.529965 1288.548908 nan nan nan 0.000000 0.000000
26 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 293.677344 299.787836 147.940552 inf 166.809150 48.002844 1150.686163 414.844208 0.020434 nan nan 0.987439 0.000000
27 1 RF_maintenance 100.00% 100.00% 56.99% 0.00% 100.00% 0.00% 35.822418 17.597327 32.080678 6.959221 17.600161 36.376492 40.134665 143.041755 0.079476 0.398738 0.189174 1.274693 2.672322
28 1 RF_maintenance 100.00% 94.62% 94.62% 5.38% 100.00% 0.00% 21.433737 2.720942 8.399888 1.773399 9.858729 6.317494 52.588778 0.798044 0.167896 0.295932 -0.122705 3.013614 8.321260
29 1 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -1.293502 -0.922816 -0.892499 -1.039324 -0.316203 -0.908475 -0.752234 -0.511404 0.618863 0.608218 0.342722 1.691827 1.861767
30 1 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -0.730813 -0.213804 -1.137742 -0.281691 -1.279105 -0.561199 3.550414 0.433375 0.612718 0.605144 0.350867 1.536683 1.774490
31 2 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% 0.242403 0.022580 0.305177 0.684277 0.685295 -0.401055 2.249268 1.166503 0.092557 0.089830 0.021264 1.185423 1.183475
32 2 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 23.356471 26.446469 0.967914 1.619460 4.824640 9.975363 19.915774 26.598247 0.078355 0.093700 0.008923 1.211631 1.212908
33 2 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.467093 4.606254 -0.227142 -0.424952 15.642603 17.156526 21.559422 38.530312 0.061080 0.107490 0.032064 1.278079 1.271370
36 3 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 6.403238 7.097983 0.620409 3.279625 0.800961 3.171318 0.115085 1.308130 0.611097 0.605451 0.349379 5.630573 5.356660
37 3 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% 1.904072 0.922622 2.258131 1.580843 3.690012 1.236569 1.246631 3.568399 0.619350 0.612843 0.344473 1.417436 1.719406
38 3 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 1.800825 1.983117 2.483476 2.194587 4.399511 2.755527 5.568143 -1.030423 0.621952 0.619987 0.347472 3.497578 4.336492
39 0 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 302.458641 304.724683 inf inf 622.240810 3466.351834 4091.967218 10779.377478 nan nan nan 0.000000 0.000000
40 4 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% 0.842681 0.952641 1.027701 0.971496 1.062443 0.980139 0.056722 -0.152007 0.627331 0.641685 0.348487 1.728636 2.049324
41 4 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -0.496968 -0.869292 -1.081185 -0.262163 -1.595186 -0.550411 -0.334068 1.985354 0.633391 0.643297 0.349936 1.789884 2.011596
42 4 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -0.833954 0.670648 -0.958966 -0.005115 -1.224422 1.462246 0.131317 -0.196547 0.640495 0.638614 0.349683 1.720261 1.881742
45 5 RF_maintenance 100.00% 0.00% 100.00% 0.00% 100.00% 0.00% 0.487766 21.180386 0.232595 36.920243 -0.115265 7.972506 -0.166796 4.117310 0.587881 0.065888 0.284126 3.492664 2.257122
46 5 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -1.006006 -0.761010 -1.001955 -0.403684 -0.222794 0.626297 2.064809 -0.154092 0.567083 0.555110 0.363988 1.142899 1.212587
50 3 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 0.601682 5.011795 1.761688 0.669192 3.140666 10.164344 15.495641 97.166536 0.598349 0.586571 0.319881 6.058918 7.039935
51 3 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -0.002617 1.424609 -0.279258 1.208561 -1.112746 0.641467 2.123487 -1.006829 0.622344 0.620226 0.337141 1.444467 1.724782
52 3 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 5.929972 4.931710 0.775694 0.797142 5.302959 5.601964 82.121005 82.300758 0.615852 0.618444 0.299856 8.668808 11.282372
53 3 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 0.029884 0.373718 -0.380930 -1.002664 -0.895058 -0.516538 2.847178 7.038377 0.627942 0.642894 0.338425 3.918980 4.874837
54 4 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -0.254361 -0.601129 -1.040500 0.348288 -1.089153 0.236475 0.497707 0.769433 0.626651 0.647136 0.334557 1.575850 1.928675
55 4 digital_ok 100.00% 0.00% 0.00% 100.00% 100.00% 0.00% 0.305749 2.648538 0.701305 0.793441 2.815868 3.450072 7.111327 10.235181 0.288824 0.293521 -0.277211 4.842412 4.575559
56 4 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% -1.149410 -0.120417 -0.600323 0.651824 -0.062734 1.137381 2.695062 20.452558 0.636306 0.644521 0.347230 5.467367 5.641786
57 4 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 3.673932 0.322252 5.242354 1.455265 9.040756 2.075769 2.907150 -0.869409 0.629381 0.615687 0.354091 4.991890 4.735890
65 3 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% 0.581200 0.798273 0.698839 0.609428 0.399994 1.261492 -1.358218 -0.316913 0.586580 0.588997 0.335029 1.693136 1.894472
66 3 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% 1.278460 0.239556 2.113471 -0.579643 2.233569 -0.830935 -2.052952 0.003232 0.604595 0.615400 0.329933 1.485972 1.660346
67 3 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 0.956913 3.271770 2.763105 7.943796 2.988221 6.358930 1.197892 4.792813 0.627490 0.641755 0.333243 5.551264 7.393948
68 3 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% 0.446271 0.219507 -0.044236 1.221876 0.200837 0.557750 -1.302810 2.690621 0.628112 0.651939 0.338891 1.646192 1.854097
69 4 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% -1.027455 -0.782011 -0.930362 0.010095 -1.213936 5.860784 -0.137875 -0.285433 0.640704 0.651752 0.351024 4.472184 5.107427
70 4 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 9.403517 5.722698 8.151088 9.497214 6.136729 6.725906 6.331343 16.501298 0.641585 0.623287 0.362715 15.757160 12.949043
71 4 digital_ok 0.00% 0.00% 0.00% 100.00% 100.00% 0.00% 1.061039 0.362154 0.374728 0.255227 2.592254 1.170343 1.688219 2.685275 0.292174 0.286221 -0.280626 3.078583 3.214931
72 4 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 3.433350 -0.134449 0.500582 -0.757312 4.134027 0.527348 23.029632 11.401178 0.622213 0.622889 0.341690 4.339839 4.065964
73 5 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 0.312932 3.116505 0.639072 7.343273 0.307696 5.051377 1.460049 9.678952 0.617174 0.599023 0.357369 3.990983 4.059881
81 7 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 0.194025 0.837110 0.625412 -0.366374 1.244642 0.315368 13.438299 9.944870 0.579213 0.586196 0.337774 3.030966 3.494764
82 7 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 5.277954 2.276237 1.322492 1.243526 2.966705 1.595306 35.656602 4.477700 0.599369 0.610590 0.340013 6.116432 5.201961
83 7 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 18.923532 20.949855 32.848020 33.972728 11.006867 8.157070 4.808507 4.125090 0.043622 0.047840 0.001391 1.177579 1.186788
84 8 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 6.566439 7.340401 0.042602 0.789428 -0.201622 0.302790 -0.106091 -0.253744 0.631593 0.636383 0.339687 4.313808 4.529013
85 8 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
86 8 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
87 8 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
88 9 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
89 9 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
90 9 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
91 9 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
92 10 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 16.139200 20.010353 35.912933 37.338245 11.196100 8.322294 3.482351 4.346234 0.034529 0.046864 0.005413 1.426370 1.458928
93 10 RF_maintenance 100.00% 43.55% 100.00% 0.00% 100.00% 0.00% 7.470837 22.754197 -0.631468 37.972255 6.040635 8.348648 1.438100 7.130436 0.423559 0.046125 0.174995 4.721807 1.421871
94 10 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 0.187293 1.745362 0.587285 3.929822 0.710871 0.985371 5.326295 1.340502 0.577783 0.559812 0.363770 3.498625 4.189804
98 7 digital_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 18.054049 20.170185 31.879259 32.921112 11.168963 8.163263 4.344504 4.022510 0.041892 0.044924 0.005557 1.133034 1.129352
99 7 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 1.598915 1.966477 2.418581 2.565723 2.688243 2.421976 4.833477 21.094831 0.589174 0.593770 0.358480 3.339621 3.155467
100 7 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 19.682606 21.931616 32.385164 34.608305 11.024878 8.197085 6.165301 5.468881 0.043920 0.048116 0.005890 1.159906 1.159619
101 8 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
102 8 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
103 8 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 2.371377 6.916437 0.898350 1.726538 0.802360 1.217225 1.060027 1.378971 0.630032 0.622099 0.358571 3.409138 3.057271
104 8 RF_maintenance 100.00% 0.00% 0.00% 100.00% 100.00% 0.00% 7.181465 66.416025 2.392249 34.225561 1.502901 8.509759 1.138950 2.690459 0.268647 0.210956 -0.263830 1.612191 1.389636
105 9 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
106 9 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
107 9 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
108 9 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
109 10 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -0.520741 -0.752237 0.130070 -0.686946 -0.387416 -0.622138 2.905600 -0.318071 0.602308 0.587481 0.359988 0.413911 0.340359
110 10 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 36.540270 1.167304 4.658105 -0.301028 2.929626 14.081334 28.201913 151.898552 0.519038 0.575047 0.313518 6.603743 8.829337
111 10 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% -0.032082 -0.174397 -0.275277 -0.515148 0.819002 4.340155 4.377397 6.039284 0.592722 0.570937 0.358281 3.908075 4.657223
112 10 RF_maintenance 100.00% 0.00% 100.00% 0.00% 100.00% 0.00% -0.792945 22.594276 0.615078 37.720264 0.501644 8.181825 0.801963 3.966577 0.565624 0.056930 0.280007 3.388427 1.877097
116 7 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 20.068017 22.419339 32.863993 34.085205 11.020380 8.223128 3.894079 5.205995 0.043711 0.044197 0.000195 1.150764 1.148995
119 7 RF_maintenance 100.00% 100.00% 0.00% 0.00% 100.00% 0.00% 19.308012 -0.204502 30.893015 -1.007843 10.957341 -0.865447 4.022414 0.491158 0.044511 0.593448 0.294534 1.017843 2.606088
120 8 RF_maintenance 100.00% 43.55% 100.00% 0.00% 100.00% 0.00% 11.202321 32.588527 3.887217 40.588489 6.372803 7.971917 1.978044 7.274697 0.420593 0.038614 0.232022 2.227755 0.828345
121 8 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 1.382656 6.828491 0.714459 6.927143 2.018161 3.095678 30.149714 29.194772 0.628783 0.621123 0.364192 2.081919 2.026244
122 8 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
123 8 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 4.663472 3.965100 -0.501622 0.181548 -1.361834 -0.083319 -0.240069 -0.688393 0.623878 0.611980 0.370949 0.000000 0.000000
124 9 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
125 9 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
126 9 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
127 10 RF_maintenance 0.00% 0.00% 0.00% 0.00% 100.00% 0.00% 1.113706 0.557456 1.376331 1.218375 1.746683 0.873878 0.544147 2.622551 0.593689 0.586795 0.358234 8.326821 10.768741
128 10 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 0.00% -0.607783 1.457123 -0.251208 -0.840581 0.031552 -0.646153 -0.144348 -0.335867 0.597020 0.574741 0.352503 0.415173 0.362577
129 10 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 2.747803 -0.238341 5.009256 0.949071 4.938203 0.347612 0.977347 0.250621 0.595090 0.581228 0.352083 4.841252 6.558709
130 10 digital_maintenance 100.00% 100.00% 78.49% 0.00% 100.00% 0.00% 17.167031 5.818075 36.224884 3.824636 10.944225 2.840396 3.062765 -1.650224 0.049217 0.366484 0.155568 1.359068 3.718066
135 12 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
136 12 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
138 7 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 0.413663 1.454074 -0.912632 -0.887061 -1.425715 -0.110787 0.446831 7.264793 0.574353 0.571747 0.361426 0.000000 0.000000
140 13 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 0.748362 1.389501 0.165829 0.466371 1.109615 0.621718 1.593774 4.712050 0.606882 0.593161 0.354460 0.000000 0.000000
141 13 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% -0.125708 3.092133 -1.046234 11.229817 -0.691050 6.923940 1.519618 56.220380 0.615756 0.585659 0.361469 0.000000 0.000000
142 13 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 1.035886 22.855835 3.103201 37.502896 2.067719 8.139437 3.079717 3.665866 0.249761 0.049927 -0.006375 0.000000 0.000000
143 14 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.129230 -0.249595 -0.720238 -0.259509 -1.272584 -0.318313 -0.622872 -0.268358 0.108403 0.122954 0.026347 0.000000 0.000000
144 14 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 2.154430 4.364580 3.940411 8.780103 4.186501 9.801101 6.927086 3.443928 0.075927 0.088998 0.016310 0.000000 0.000000
145 14 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 1.076054 -0.595951 2.012922 -0.121537 2.751820 0.129410 4.893374 10.588362 0.090754 0.102167 0.020711 0.000000 0.000000
150 15 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 19.144336 23.277460 36.448276 38.384092 11.153360 8.263250 5.433851 6.097414 0.047548 0.050189 0.001453 1.159785 1.172887
155 12 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
156 12 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 0.445805 0.698665 -0.598557 1.966452 1.057238 17.995744 19.465604 28.944059 0.065073 0.056177 0.007761 0.000000 0.000000
157 12 RF_maintenance 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.056402 -0.678333 0.891335 0.014427 0.604143 1.395356 -0.275588 0.311870 0.062835 0.053462 0.006652 0.000000 0.000000
158 12 RF_maintenance 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.316354 -1.143936 -0.911160 -1.057917 -0.628832 -0.594447 3.031720 0.615531 0.066721 0.063581 0.006835 0.000000 0.000000
160 13 digital_ok 100.00% 43.55% 78.49% 0.00% 100.00% 0.00% 12.022376 18.732511 -0.326858 1.283044 4.640367 13.008670 3.017699 55.748784 0.420396 0.376972 0.166927 0.000000 0.000000
161 13 digital_ok 100.00% 0.00% 13.98% 0.00% 100.00% 0.00% 0.821230 37.075555 1.058073 4.948281 2.446831 1.558971 1.036342 11.622481 0.594916 0.484734 0.338732 0.000000 0.000000
162 13 digital_ok 0.00% 0.00% 0.00% 0.00% 0.00% 63.16% 0.487977 -0.102203 0.491416 0.486259 2.034411 1.420424 2.914137 1.403037 0.594454 0.583561 0.357203 0.000000 0.000000
163 14 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% 0.127166 -0.341880 0.092022 -0.509628 -0.184555 -0.000595 -0.304014 2.224606 0.090196 0.087942 0.017660 0.000000 0.000000
164 14 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.774943 -0.708074 -0.664705 -0.149062 -1.480028 3.489098 -0.063663 3.501370 0.059553 0.057976 0.007396 0.000000 0.000000
165 14 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.346905 -0.213382 -0.446930 -0.526081 -0.706304 0.230492 6.109756 1.222948 0.069475 0.070579 0.010644 0.000000 0.000000
166 14 RF_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 21.814971 24.111671 3.129514 3.545099 11.299010 6.671323 122.910816 55.089561 0.123209 0.129252 0.017106 1.254248 1.254921
167 15 digital_ok 100.00% 51.61% 0.00% 0.00% 100.00% 0.00% 43.969477 5.196181 2.262132 3.521376 15.344025 6.135519 171.380209 31.269547 0.421375 0.521123 0.305412 3.288794 3.440831
168 15 RF_maintenance 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 3.032959 4.224359 2.670058 4.303581 3.056289 4.583805 -1.324299 -1.696608 0.581326 0.553071 0.345007 4.378462 4.525900
169 15 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 4.715348 3.457537 4.342084 3.340672 6.019132 3.822470 -2.170741 -0.118958 0.559339 0.537016 0.344402 3.762789 3.505570
170 15 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 4.988124 2.323404 4.462250 2.615300 6.265145 3.143900 -0.311851 -0.877321 0.542144 0.535777 0.337194 0.000000 0.000000
176 12 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.693269 -0.765474 -0.420945 -0.085515 -0.821830 0.000595 -1.085114 1.367084 0.081378 0.069122 0.016334 0.000000 0.000000
177 12 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 0.810741 3.366977 -0.304140 3.435560 -0.357809 4.214398 3.997862 -0.823423 0.049693 0.085673 0.005386 0.000000 0.000000
178 12 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.265904 -1.038663 1.799910 -0.285316 1.288460 -0.184876 3.255349 3.900099 0.050039 0.059152 0.003316 0.000000 0.000000
179 12 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.893331 0.138549 -0.929897 0.041912 2.793088 -0.532417 -0.328586 -0.359324 0.078217 0.080324 0.012830 0.000000 0.000000
180 13 RF_maintenance 100.00% 62.37% 100.00% 0.00% 100.00% 0.00% 15.405447 21.650535 0.662399 37.750271 3.924831 8.134617 11.969163 3.824834 0.373054 0.052743 0.150237 0.000000 0.000000
181 13 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% 4.738616 0.755557 6.274175 1.813426 5.462898 2.511974 2.544035 2.045933 0.589119 0.567084 0.376345 0.000000 0.000000
182 13 RF_maintenance 0.00% 0.00% 0.00% 0.00% 100.00% 0.00% 1.927810 2.438199 2.646594 2.971028 3.447675 3.198636 -2.258837 -2.523176 0.573454 0.551499 0.365686 0.000000 0.000000
183 13 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% -0.122011 0.402767 1.216492 2.611442 1.183123 2.028066 4.501633 9.574677 0.576089 0.557970 0.369685 0.000000 0.000000
184 14 digital_ok 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% 0.645905 0.027815 -0.142214 0.302760 -0.491179 -0.624134 0.038312 0.270321 0.066502 0.066361 0.009600 0.000000 0.000000
185 14 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 7.652923 14.752914 -0.537909 0.813136 0.303573 0.674405 2.820124 8.923371 0.064877 0.066441 0.008755 0.000000 0.000000
186 14 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 0.434394 -0.214196 -0.991222 -0.450923 0.704198 0.026897 5.196773 5.506869 0.099781 0.104243 0.023550 0.000000 0.000000
187 14 digital_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% -0.192049 2.217726 -0.210210 3.079532 0.614417 6.009344 16.607760 76.116375 0.106501 0.110196 0.025936 0.952617 0.951397
189 15 digital_ok 0.00% 0.00% 0.00% 0.00% 36.84% 60.53% 0.226358 0.652041 -1.018253 -0.876573 -0.890676 -0.603760 -0.619867 -0.435950 0.566322 0.543823 0.362714 0.000000 0.000000
190 15 digital_ok 100.00% 43.55% 54.30% 0.00% 100.00% 0.00% 32.814531 58.062160 4.245388 8.890039 8.356438 36.567597 69.978299 242.822079 0.438171 0.407113 0.198080 0.000000 0.000000
191 15 digital_ok 100.00% 0.00% 0.00% 0.00% 100.00% 0.00% -0.307150 -0.718435 0.211774 -0.643606 -0.671908 -0.187226 6.892834 6.540415 0.541003 0.529004 0.354844 0.000000 0.000000
220 18 RF_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
221 18 RF_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
222 18 RF_ok 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% nan nan inf inf nan nan nan nan nan nan nan 0.000000 0.000000
320 3 dish_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 23.082033 22.646872 28.366826 29.035251 11.137060 8.196829 5.585149 4.139555 0.062456 0.071947 0.009078 0.000000 0.000000
321 2 not_connected 0.00% 100.00% 100.00% 0.00% 100.00% 0.00% 1.683157 0.799202 1.592293 1.480274 2.273696 2.519391 0.657661 -0.618236 0.080019 0.079563 0.032938 0.000000 0.000000
323 2 not_connected 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 20.998614 2.510172 2.850252 3.066503 3.315788 5.165769 13.530692 -0.115206 0.074686 0.080073 0.029291 0.000000 0.000000
324 4 not_connected 100.00% 48.92% 51.61% 0.00% 100.00% 0.00% 5.474278 4.663946 5.101252 4.534791 7.225075 5.679804 -0.671147 -0.827557 0.398596 0.382089 0.300992 0.000000 0.000000
329 12 dish_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 3.079350 8.366662 0.662089 2.280636 1.724992 2.893735 5.724674 -1.493980 0.069123 0.071201 0.023966 0.000000 0.000000
333 12 dish_maintenance 100.00% 100.00% 100.00% 0.00% 100.00% 0.00% 10.728456 2.174400 16.120351 2.335240 52.804440 3.087092 74.116016 -0.090552 0.068955 0.070244 0.023150 0.000000 0.000000
In [16]:
# print ex_ants for easy copy-pasting to YAML file
proposed_ex_ants = [ant for i, ant in enumerate(ants) if np.any([col[i] > .1 for col in bar_cols.values()])]
print('ex_ants: [' + ", ".join(str(ant) for ant in proposed_ex_ants) + ']')
ex_ants: [0, 1, 2, 3, 4, 7, 8, 9, 10, 11, 12, 13, 14, 15, 17, 18, 19, 20, 21, 23, 24, 25, 26, 27, 28, 31, 32, 33, 36, 38, 39, 45, 50, 52, 53, 55, 56, 57, 67, 69, 70, 71, 72, 73, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 110, 111, 112, 116, 119, 120, 121, 122, 123, 124, 125, 126, 127, 129, 130, 135, 136, 138, 140, 141, 142, 143, 144, 145, 150, 155, 156, 157, 158, 160, 161, 162, 163, 164, 165, 166, 167, 168, 169, 170, 176, 177, 178, 179, 180, 181, 182, 183, 184, 185, 186, 187, 189, 190, 191, 220, 221, 222, 320, 321, 323, 324, 329, 333]
In [17]:
# write to csv
outpath = os.path.join(nb_outdir, f'rtp_summary_table_{JD}.csv')
print(f'Now saving Table 1 to a csv at {outpath}')
df.to_csv(outpath)
Now saving Table 1 to a csv at /home/obs/src/H5C_Notebooks/_rtp_summary_/rtp_summary_table_2459755.csv
In [18]:
# Load antenna positions
data_list = sorted(glob.glob(os.path.join(data_path, f'zen.{JD}.?????.sum.uvh5')))
hd = io.HERAData(data_list[len(data_list) // 2])

# Figure out where to draw the nodes
node_centers = {}
for node in sorted(set(list(nodes.values()))):
    if np.isfinite(node):
        this_node_ants = [ant for ant in ants + unused_ants if nodes[ant] == node]
        if len(this_node_ants) == 1:
            # put the node label just to the west of the lone antenna 
            node_centers[node] = hd.antpos[ant][node] + np.array([-14.6 / 2, 0, 0])
        else:
            # put the node label between the two antennas closest to the node center
            node_centers[node] = np.mean([hd.antpos[ant] for ant in this_node_ants], axis=0)
            closest_two_pos = sorted([hd.antpos[ant] for ant in this_node_ants], 
                                     key=lambda pos: np.linalg.norm(pos - node_centers[node]))[0:2]
            node_centers[node] = np.mean(closest_two_pos, axis=0)
In [19]:
def Plot_Array(ants, unused_ants, outriggers):
    plt.figure(figsize=(16,16))
    
    plt.scatter(np.array([hd.antpos[ant][0] for ant in hd.data_ants if ant in ants]), 
                np.array([hd.antpos[ant][1] for ant in hd.data_ants if ant in ants]), c='w', s=0)

    # connect every antenna to their node
    for ant in ants:
        if nodes[ant] in node_centers:
            plt.plot([hd.antpos[ant][0], node_centers[nodes[ant]][0]], 
                     [hd.antpos[ant][1], node_centers[nodes[ant]][1]], 'k', zorder=0)

    rc_color = '#0000ff'
    antm_color = '#ffa500'
    autom_color = '#ff1493'

    # Plot 
    unflagged_ants = []
    for i, ant in enumerate(ants):
        ant_has_flag = False
        # plot large blue annuli for redcal flags
        if use_redcal:
            if redcal_flagged_frac[ant] > 0:
                ant_has_flag = True
                plt.gca().add_artist(plt.Circle(tuple(hd.antpos[ant][0:2]), radius=7 * (2 - 1 * float(not outriggers)), fill=True, lw=0,
                                                color=rc_color, alpha=redcal_flagged_frac[ant]))
                plt.gca().add_artist(plt.Circle(tuple(hd.antpos[ant][0:2]), radius=6 * (2 - 1 * float(not outriggers)), fill=True, color='w'))
        
        # plot medium green annuli for ant_metrics flags
        if use_ant_metrics: 
            if ant_metrics_xants_frac_by_ant[ant] > 0:
                ant_has_flag = True
                plt.gca().add_artist(plt.Circle(tuple(hd.antpos[ant][0:2]), radius=6 * (2 - 1 * float(not outriggers)), fill=True, lw=0,
                                                color=antm_color, alpha=ant_metrics_xants_frac_by_ant[ant]))
                plt.gca().add_artist(plt.Circle(tuple(hd.antpos[ant][0:2]), radius=5 * (2 - 1 * float(not outriggers)), fill=True, color='w'))
        
        # plot small red annuli for auto_metrics
        if use_auto_metrics:
            if ant in auto_ex_ants:
                ant_has_flag = True                
                plt.gca().add_artist(plt.Circle(tuple(hd.antpos[ant][0:2]), radius=5 * (2 - 1 * float(not outriggers)), fill=True, lw=0, color=autom_color)) 
        
        # plot black/white circles with black outlines for antennas
        plt.gca().add_artist(plt.Circle(tuple(hd.antpos[ant][0:2]), radius=4 * (2 - 1 * float(not outriggers)), fill=True, color=['w', 'k'][ant_has_flag], ec='k'))
        if not ant_has_flag:
            unflagged_ants.append(ant)

        # label antennas, using apriori statuses if available
        try:
            bgc = matplotlib.colors.to_rgb(status_colors[a_priori_statuses[ant]])
            c = 'black' if (bgc[0]*0.299 + bgc[1]*0.587 + bgc[2]*0.114) > 186 / 256 else 'white'
        except:
            c = 'k'
            bgc='white'
        plt.text(hd.antpos[ant][0], hd.antpos[ant][1], str(ant), va='center', ha='center', color=c, backgroundcolor=bgc)

    # label nodes
    for node in sorted(set(list(nodes.values()))):
        if not np.isnan(node) and not np.all(np.isnan(node_centers[node])):
            plt.text(node_centers[node][0], node_centers[node][1], str(node), va='center', ha='center', bbox={'color': 'w', 'ec': 'k'})
    
    # build legend 
    legend_objs = []
    legend_labels = []
    
    # use circles for annuli 
    legend_objs.append(matplotlib.lines.Line2D([0], [0], marker='o', color='w', markeredgecolor='k', markerfacecolor='w', markersize=13))
    legend_labels.append(f'{len(unflagged_ants)} / {len(ants)} Total {["Core", "Outrigger"][outriggers]} Antennas Never Flagged')
    legend_objs.append(matplotlib.lines.Line2D([0], [0], marker='o', color='w', markerfacecolor='k', markersize=15))
    legend_labels.append(f'{len(ants) - len(unflagged_ants)} Antennas {["Core", "Outrigger"][outriggers]} Flagged for Any Reason')

    if use_auto_metrics:
        legend_objs.append(matplotlib.lines.Line2D([0], [0], marker='o', color='w', markeredgewidth=2, markeredgecolor=autom_color, markersize=15))
        legend_labels.append(f'{len([ant for ant in auto_ex_ants if ant in ants])} {["Core", "Outrigger"][outriggers]} Antennas Flagged by Auto Metrics')
    if use_ant_metrics: 
        legend_objs.append(matplotlib.lines.Line2D([0], [0], marker='o', color='w', markeredgewidth=2, markeredgecolor=antm_color, markersize=15))
        legend_labels.append(f'{np.round(np.sum([frac for ant, frac in ant_metrics_xants_frac_by_ant.items() if ant in ants]), 2)} Antenna-Nights on' 
                             f'\n{np.sum([frac > 0 for ant, frac in ant_metrics_xants_frac_by_ant.items() if ant in ants])} {["Core", "Outrigger"][outriggers]} Antennas '
                             'Flagged by Ant Metrics\n(alpha indicates fraction of time)')        
    if use_redcal:
        legend_objs.append(matplotlib.lines.Line2D([0], [0], marker='o', color='w', markeredgewidth=2, markeredgecolor=rc_color, markersize=15))
        legend_labels.append(f'{np.round(np.sum(list(redcal_flagged_frac.values())), 2)} Antenna-Nights on' 
                             f'\n{np.sum([frac > 0 for ant, frac in redcal_flagged_frac.items() if ant in ants])} {["Core", "Outrigger"][outriggers]} Antennas '
                             'Flagged by Redcal\n(alpha indicates fraction of time)')

    # use rectangular patches for a priori statuses that appear in the array
    for aps in sorted(list(set(list(a_priori_statuses.values())))):
        if aps != 'Not Found':
            legend_objs.append(plt.Circle((0, 0), radius=7, fill=True, color=status_colors[aps]))
            legend_labels.append(f'A Priori Status:\n{aps} ({[status for ant, status in a_priori_statuses.items() if ant in ants].count(aps)} {["Core", "Outrigger"][outriggers]} Antennas)')

    # label nodes as a white box with black outline
    if len(node_centers) > 0:
        legend_objs.append(matplotlib.patches.Patch(facecolor='w', edgecolor='k'))
        legend_labels.append('Node Number')

    if len(unused_ants) > 0:
        legend_objs.append(matplotlib.lines.Line2D([0], [0], marker='o', color='w', markerfacecolor='grey', markersize=15, alpha=.2))
        legend_labels.append(f'Anntenna Not In Data')
        
    
    plt.legend(legend_objs, legend_labels, ncol=2, fontsize='large', framealpha=1)
    
    if outriggers:
        pass
    else:
        plt.xlim([-200, 150])
        plt.ylim([-150, 150])        
       
    # set axis equal and label everything
    plt.axis('equal')
    plt.tight_layout()
    plt.title(f'Summary of {["Core", "Outrigger"][outriggers]} Antenna Statuses and Metrics on {JD}', size=20)    
    plt.xlabel("Antenna East-West Position (meters)", size=12)
    plt.ylabel("Antenna North-South Position (meters)", size=12)
    plt.xticks(fontsize=12)
    plt.yticks(fontsize=12)
    xlim = plt.gca().get_xlim()
    ylim = plt.gca().get_ylim()    
        
    # plot unused antennas
    plt.autoscale(False)    
    for ant in unused_ants:
        if nodes[ant] in node_centers:
            plt.plot([hd.antpos[ant][0], node_centers[nodes[ant]][0]], 
                     [hd.antpos[ant][1], node_centers[nodes[ant]][1]], 'k', alpha=.2, zorder=0)
        
        plt.gca().add_artist(plt.Circle(tuple(hd.antpos[ant][0:2]), radius=4, fill=True, color='w', ec=None, alpha=1, zorder=0))
        plt.gca().add_artist(plt.Circle(tuple(hd.antpos[ant][0:2]), radius=4, fill=True, color='grey', ec=None, alpha=.2, zorder=0))
        if hd.antpos[ant][0] < xlim[1] and hd.antpos[ant][0] > xlim[0]:
            if hd.antpos[ant][1] < ylim[1] and hd.antpos[ant][1] > ylim[0]:
                plt.text(hd.antpos[ant][0], hd.antpos[ant][1], str(ant), va='center', ha='center', color='k', alpha=.2) 

Figure 1: Array Plot of Flags and A Priori Statuses¶

This plot shows all antennas, which nodes they are connected to, and their a priori statuses (as the highlight text of their antenna numbers). It may also show (depending on what is finished running):

  • Whether they were flagged by auto_metrics (red circle) for bandpass shape, overall power, temporal variability, or temporal discontinuities. This is done in a binary fashion for the whole night.
  • Whether they were flagged by ant_metrics (green circle) as either dead (on either polarization) or crossed, with the transparency indicating the fraction of the night (i.e. number of files) that were flagged.
  • Whether they were flagged by redcal (blue circle) for high chi^2, with the transparency indicating the fraction of the night (i.e. number of files) that were flagged.

Note that the last fraction does not include antennas that were flagged before going into redcal due to their a priori status, for example.

In [20]:
core_ants = [ant for ant in ants if ant < 320]
outrigger_ants = [ant for ant in ants if ant >= 320]
Plot_Array(ants=core_ants, unused_ants=unused_ants, outriggers=False)
if len(outrigger_ants) > 0:
    Plot_Array(ants=outrigger_ants, unused_ants=sorted(set(unused_ants + core_ants)), outriggers=True)

Metadata¶

In [21]:
from hera_qm import __version__
print(__version__)
from hera_cal import __version__
print(__version__)
2.0.2
3.1.1.dev2+g1b5039f
In [ ]: