utils/pcap_parser.py
def write_results(outDir, data_list, pcap_list):
    """
    Save the numpy design matrices and time vectors
    """
    for (pkts, time), pcap_file in zip(data_list, pcap_list):
        prefix = pcap_file.split('.')[0]
        pkts_file = os.path.join(outDir, '{}_all_pkts'.format(prefix))
        time_file = os.path.join(outDir, '{}_all_times'.format(prefix))
        np.save(pkts_file, pkts)
        np.save(time_file, time)

    Save the numpy design matrices and time vectors
    
Save the numpy design matrices and time vectors
Save the numpy design matrices and time vectors
def write_results(outDir, data_list, pcap_list):
    for (pkts, time), pcap_file in zip(data_list, pcap_list):
        prefix = pcap_file.split('.')[0]
        pkts_file = os.path.join(outDir, '{}_all_pkts'.format(prefix))
        time_file = os.path.join(outDir, '{}_all_times'.format(prefix))
        np.save(pkts_file, pkts)
        np.save(time_file, time)
def write_results ( outDir , data_list , pcap_list ) : for ( pkts , time ) , pcap_file in zip ( data_list , pcap_list ) : prefix = pcap_file . split ( '.' ) [ 0 ] pkts_file = os . path . join ( outDir , '{}_all_pkts' . format ( prefix ) ) time_file = os . path . join ( outDir , '{}_all_times' . format ( prefix ) ) np . save ( pkts_file , pkts ) np . save ( time_file , time )
Save the numpy design matrices and time vectors
Save the numpy design matrices and time vectors
"""
    Save the numpy design matrices and time vectors
    """
outDir
data_list
pcap_list