Пример #1
0
    pm = pathMonitor.pathMonitor(hegemonyQueuePM,
                                 announceQueue,
                                 saverQueue=saverQueue)

outlierDetection = False
if outlierDetection:
    pipeOD = mpPipe(False)
    od = Process(target=outlierDetection.outlierDetection,
                 args=(pipeOD[0], 3.0, 5),
                 name="OD")

pc = pathCounter.pathCounter(args.starttime,
                             args.endtime,
                             announceQueue,
                             countQueue,
                             ribQueue,
                             spatialResolution=args.spatial,
                             af=args.af,
                             asnFilter=args.filter,
                             timeWindow=args.window,
                             collectors=args.collector)
ash = asHegemony.asHegemony(countQueue,
                            hegemonyQueue,
                            alpha=args.alpha,
                            saverQueue=saverQueue)

saverQueuePostgre = None
if args.postgre:
    logging.info("Will push results to Postgresql")
    import saverPostgresql
    saverQueuePostgre = mpQueue(10000)
    sp = Process(target=saverPostgresql.saverPostgresql,
Пример #2
0
outlierDetection = False
if outlierDetection:
    pipeOD = mpPipe(False)
    od = Process(target=outlierDetection.outlierDetection,
                 args=(pipeOD[0], 3.0, 5),
                 name="OD")

pc = pathCounter.pathCounter(starttime,
                             endtime,
                             announceQueue,
                             countQueue,
                             ribQueue,
                             spatialResolution=spatial,
                             af=af,
                             timeWindow=window,
                             collectors=collector,
                             excludedPeers=excludedPeers,
                             includedPeers=includedPeers,
                             includedOrigins=includedOrigins,
                             excludedOrigins=excludedOrigins,
                             onlyFullFeed=onlyFullFeed,
                             txtFile=inputFile)
ash = asHegemony.asHegemony(countQueue,
                            hegemonyQueue,
                            alpha=alpha,
                            saverQueue=saverQueue)

saverQueuePostgre = None
if postgre:
    logging.info("Will push results to Postgresql")