Exemple #1
0
        public void ComposeEpsilon_Test()
        {
            URL url = new URL(Helper.FilesDirectory + "/fst/algorithms/composeeps/A.fst.txt");

            String path = url.File.DirectoryName + "/A";
            Fst    fstA = Convert.ImportFst(path, new TropicalSemiring());

            path = url.File.DirectoryName + "/B";
            Fst fstB = Convert.ImportFst(path, new TropicalSemiring());

            path = Path.Combine(url.File.DirectoryName, "fstcomposeeps");
            Fst fstC = Convert.ImportFst(path, new TropicalSemiring());

            Fst fstComposed = Compose.Get(fstA, fstB, new TropicalSemiring());

            Assert.AreEqual(fstC, fstComposed);
        }