def caida(): # normal_sigs, normal_nodes = parseToCoo('../loc6-20070501-100.sigs', # undirected=True) # model, para, debug_ret = select_model(len(normal_nodes), normal_sigs, 50, 50, True) # import ipdb;ipdb.set_trace() # ROOT = '/home/wangjing/LocalResearch/CyberData/caida-data/passive-2013/' ROOT = '../' normal_sigs, normal_nodes = parseToCoo(ROOT + \ 'equinix-sanjose.dirA.20130117-125912.UTC.anon-10.sigs', undirected=True, first_k=None) botnet_sigs, botnet_nodes = parseToCoo( '../ddostrace.20070804_134936-10.sigs', undirected=True) model, para, debug_ret = select_model(len(normal_nodes), normal_sigs, 4, 1000, True) data_set = normal_sigs * 3 + botnet_sigs + normal_sigs * 3 divs1 = monitor_deg_dis(data_set, 'CHJ', [debug_ret['CHJ'][1], 1e-10]) divs3 = monitor_deg_dis(data_set, 'BA', [debug_ret['BA'][1], 1e-10]) divs2 = monitor_deg_dis(data_set, 'ER', [debug_ret['ER'][1], 1e-10]) dump_data = {'d1': divs1, 'd2': divs2, 'd3': divs3} dump(dump_data, './CHJ_overperform_BA.pk') P.subplot(311) P.plot(divs1) P.subplot(312) P.plot(divs2) P.subplot(313) P.plot(divs3) P.show() import ipdb ipdb.set_trace()
def caida(): # normal_sigs, normal_nodes = parseToCoo('../loc6-20070501-100.sigs', # undirected=True) # model, para, debug_ret = select_model(len(normal_nodes), normal_sigs, 50, 50, True) # import ipdb;ipdb.set_trace() # ROOT = '/home/wangjing/LocalResearch/CyberData/caida-data/passive-2013/' ROOT = '../' normal_sigs, normal_nodes = parseToCoo(ROOT + \ 'equinix-sanjose.dirA.20130117-125912.UTC.anon-10.sigs', undirected=True, first_k=None) botnet_sigs, botnet_nodes = parseToCoo('../ddostrace.20070804_134936-10.sigs', undirected=True) model, para, debug_ret = select_model(len(normal_nodes), normal_sigs, 4, 1000, True) data_set = normal_sigs * 3 + botnet_sigs + normal_sigs * 3 divs1 = monitor_deg_dis(data_set, 'CHJ', [debug_ret['CHJ'][1], 1e-10]) divs3 = monitor_deg_dis(data_set, 'BA', [debug_ret['BA'][1], 1e-10]) divs2 = monitor_deg_dis(data_set, 'ER', [debug_ret['ER'][1], 1e-10]) dump_data = {'d1': divs1, 'd2': divs2, 'd3': divs3} dump(dump_data, './CHJ_overperform_BA.pk') P.subplot(311) P.plot(divs1) P.subplot(312) P.plot(divs2) P.subplot(313) P.plot(divs3) P.show() import ipdb;ipdb.set_trace()
def loc6(): normal_sigs, normal_nodes = parseToCoo('../loc6-20070501-100.sigs', undirected=True) model, para, debug_ret = select_model(len(normal_nodes), normal_sigs, 50, 50, True) import ipdb ipdb.set_trace()
def loc6(): normal_sigs, normal_nodes = parseToCoo('../loc6-20070501-100.sigs', undirected=True) model, para, debug_ret = select_model(len(normal_nodes), normal_sigs, 50, 50, True) import ipdb;ipdb.set_trace()