Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
04/24/17 14:45:37 (8 years ago)
Author:
gkronber
Message:

#2699 renamed and moved files

File:
1 moved

Legend:

Unmodified
Added
Removed
  • branches/RBFRegression/HeuristicLab.Algorithms.DataAnalysis/3.4/TSNE/Distances/ManhattanDistance.cs

    r14884 r14885  
    5050    }
    5151
    52     public static double GetDistance(IEnumerable<double> a, IEnumerable<double> b, double threshold) {
    53       double sum = 0;
    54       var it1 = a.GetEnumerator();
    55       var it2 = b.GetEnumerator();
    56       while (sum > threshold && it1.MoveNext() && it2.MoveNext()) {
    57         sum += Math.Abs(it1.Current - it2.Current);
    58       }
    59       it1.Dispose();
    60       it2.Dispose();
    61       return sum;
    62     }
    63 
    6452    public override double Get(IEnumerable<double> a, IEnumerable<double> b) {
    6553      return GetDistance(a.ToArray(), b.ToArray());
    6654    }
    67 
    68     public override double Get(IEnumerable<double> a, IEnumerable<double> b, double threshold) {
    69       return GetDistance(a, b, threshold);
    70     }
    71 
    72 
    7355  }
    7456}
Note: See TracChangeset for help on using the changeset viewer.