Skip to content

Commit

Permalink
Clearing a few comments of old code.
Browse files Browse the repository at this point in the history
  • Loading branch information
smbadiwe committed Nov 7, 2017
1 parent 97bfef3 commit 4f2db5c
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 61 deletions.
5 changes: 0 additions & 5 deletions MODA.Impl/ModaAlgorithms.1.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using QuickGraph;
using System;
using System.Collections.Generic;

namespace MODA.Impl
Expand Down Expand Up @@ -40,7 +39,6 @@ public static Dictionary<QueryGraph, string> Algorithm1_C(UndirectedGraph<int> i
{
// Modified Mapping module - MODA and Grockow & Kellis
mappings = Algorithm2_Modified(qGraph, inputGraphClone, numIterations, false);
//mappings = ModaAlgorithm2Parallelized.Algorithm2_Modified(qGraph, inputGraph);
}
else
{
Expand Down Expand Up @@ -163,9 +161,6 @@ public static Dictionary<QueryGraph, IList<Mapping>> Algorithm1(UndirectedGraph<
else
{
// Enumeration moodule - MODA

//var timer = System.Diagnostics.Stopwatch.StartNew();

// This is part of Algo 3; but performance tweaks makes it more useful to get it here
var parentQueryGraph = GetParent(qGraph, _builder.ExpansionTree);
if (parentQueryGraph.IsTree(subgraphSize))
Expand Down
57 changes: 1 addition & 56 deletions MODA.Impl/ModaAlgorithms.3.cs
Original file line number Diff line number Diff line change
Expand Up @@ -53,62 +53,7 @@ private static IList<Mapping> Algorithm3(Dictionary<QueryGraph, IList<Mapping>>

var list = new List<Mapping>();
int oldCount = parentGraphMappings.Count, queryGraphEdgeCount = queryGraph.EdgeCount;
#region MyRegion
//int addId = 0, removeId = -10;
//var mapGroups = parentGraphMappings.GroupBy(x => x.Function.Values, MappingNodesComparer); //.ToDictionary(x => x.Key, x => x.ToArray());

//var toRemove = new HashSet<Mapping>();

//foreach (var group in mapGroups)
//{
// if (group.Count() > 2)
// {

// }
// foreach (var item in group)
// {
// item.Id = addId++;
// // Remember, f(h) = g
// bool added = false;
// // if (f(u), f(v)) ϵ G and meets the conditions, add to list
// if (item.SubGraphEdgeCount == queryGraphEdgeCount)
// {
// var isMapping = item.IsCorrectlyMapped(queryGraph, inputGraph);
// if (isMapping)
// {
// list.Add(item);
// added = true;
// }
// }
// else if (item.SubGraphEdgeCount > queryGraphEdgeCount)
// {
// var newEdgeImage = item.GetImage(inputGraph, newEdge);

// // if it's a valid edge...
// if (newEdgeImage.Source != Utils.DefaultEdgeNodeVal
// && inputGraph.ContainsEdge(newEdgeImage.Source, newEdgeImage.Target))
// {
// list.Add(item);
// added = true;
// }
// }
// if (added)
// {
// foreach (var rem in group)
// {
// for (int i = 0; i < queryGraphEdgeCount; i++)
// {
// if (item.Function.Values[i] == rem.Function.Values[queryGraphEdgeCount - i - 1])
// continue;

// toRemove.Add(rem);
// break;
// }
// }
// }
// }
//}
#endregion

for (int i = 0; i < oldCount; i++)
{
var item = parentGraphMappings[i];
Expand Down

0 comments on commit 4f2db5c

Please sign in to comment.