Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/mosesdecoder.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'moses/src/FloydWarshall.h')
-rw-r--r--moses/src/FloydWarshall.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/moses/src/FloydWarshall.h b/moses/src/FloydWarshall.h
new file mode 100644
index 000000000..0a28a9bce
--- /dev/null
+++ b/moses/src/FloydWarshall.h
@@ -0,0 +1,10 @@
+#pragma once
+
+#include <vector>
+
+/**
+ * Floyd-Warshall all-pairs shortest path algorithm
+ * See CLR (1990). Introduction to Algorithms, p. 558-565
+ */
+void floyd_warshall(const std::vector<std::vector<bool> >& edges, std::vector<std::vector<int> >& distances);
+