Beispiel #1
0
def levdiag_test5():
    s1 = s2 = read_file(data_dir + "/73632.agg.txt")  # 14kb file
    # s1 = read_file(data_dir +  "/73621.agg.txt")  # 900 bytes file
    # s2 = read_file(data_dir +  "/73691.agg.txt")  # 900 bytes file
    m = HybridSubsetDistanceMatrix(fDiagDistance(100), s1, s2, 100000000)
Beispiel #2
0
def levdiag_test3():
    s = read_file(data_dir + "/73632.agg.txt")  # 14kb file
    # s = read_file(data_dir +  "/73621.agg.txt")  # 900 bytes file
    print len(s)
    ArrayDistanceMatrix(fDiagDistance(100), s, s, 1000)
Beispiel #3
0
def test_DLVD(s):
    print fDiagDistance(100)(s, s)
Beispiel #4
0
def levdiag_test0():
    # s = read_file(data_dir +  "/73632.agg.txt")  # 14kb file
    s = read_file(data_dir + "/73621.agg.txt")  # 900 bytes file
    for i in fDiagDistance(100).__generator__(s, s):
        pass
Beispiel #5
0
t1, t2 = "asdsdsa", "ssasasas"
m = DistanceMatrix(fLevenshteinDistance2, t1, t2)
print m.toString(t1, t2)


t1, t2 = "asdsdsa", "ssasasas"
m = DistanceMatrix(fLevenshteinDistance, t1, t2)
print m.toString(t1, t2)

t1, t2 = "asdsdsa", "ssasasas"
m = DistanceMatrix(fClassicalLevenshteinDistance, t1, t2)
print m.toString(t1, t2)

t1, t2 = "asdsdsa", "ssasasas"
m = DistanceMatrix(fDiagDistance(6), t1, t2, 111)
print m.toString(t1, t2)

s = s1 = s2 = read_file(data_dir + "/73632.agg.txt")
test_LVD2(s)
test_LVD(s)

# test_FLVD(s)

# levdiag_test1()
# levdiag_test4()
# levdiag_test5()

# s1 = s2 = read_file(data_dir +  "/73632.agg.txt")
# test_DLVD(s1)