// public const string databaseAccessesPath = @"C:\Users\Yuval\Desktop\Data\Traffic of Database Accesses\trimmed.csv"; private static void RunMilanoPhonesSecondMomentSketch(Random random) { //int numOfNodes = 25; // var dimensions = new[] { (9, 9)}; var window = 24; // foreach (var numOfNodes in ArrayUtils.Init(16, 36, 64, 100, 144, 13 * 13, 14 * 14)) foreach (var numOfNodes in ArrayUtils.Init(4) .Select(x => x * x)) { var distributingMethod = new GridDistributing(1, 10000, numOfNodes); //var approximation = new MultiplicativeUpperLowerApproximation(0.3, 3.0); //var approximation = new ThresholdApproximation(2700000); //var approximation = new CombinedApproximation(new MultiplicativeUpperLowerApproximation(0.5, 2.0), // new AdditiveApproximation(100000)); // foreach (var approximation in ArrayUtils.Init(100000, 200000, 300000, 400000, 500000, 700000, 900000, 1100000, 1300000, 1600000, 1900000, 2200000, 2500000).Select(x => new AdditiveApproximation(x))) { var width = 14; var height = 11; var approximation = new AdditiveApproximation(0.5E06); //foreach (var (width, height) in ArrayUtils // .Init(2, 5, 10, 14, 18, 22, 27, 31, 36, 40, 45, 50, 54, 59, 63, 68, 72, 77, 81, 86, 90) // .Select(x => (14, x))) SecondMomentRunner.RunMilanoPhoneActivity(random, numOfNodes, window, approximation, width, height, distributingMethod, phoneActivitiesBaseFolder, resultDir); } } }
private static void RunRandomAms(Random random) { int iterations = 4000; bool oneChanges = true; for (var numOfNodes = 41; numOfNodes <= 41; numOfNodes += 2) { for (var width = 21; width <= 21; width += 10) { var height = 21; //ApproximationType approximation = new CombinedApproximation(new MultiplicativeUpperLowerApproximation(0.5, 2.0)); ApproximationType approximation = new CombinedApproximation(new MultiplicativeUpperLowerApproximation(0.5, 2.0)); SecondMomentRunner.RunRandomly(random, width, height, numOfNodes, iterations, approximation, oneChanges, resultDir); } } }