Talk:Lt-trim

From Apertium
Revision as of 08:36, 11 February 2014 by Unhammer (talk | contribs) (Created page with "==Alternate implementation methods== Trimming while reading the XML file might have lower memory usage (who knows, untested), but seems like more work, since pardefs are read ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Alternate implementation methods[edit]

Trimming while reading the XML file might have lower memory usage (who knows, untested), but seems like more work, since pardefs are read and turned into FST's before we get to an "initial" state and then attached at the end of regular entries.

product automaton for intersection

The product automaton for intersection, marks as final only state-pairs where both parts of the state-pair are final in the original automata. Minimisation removes unreachable state-pairs. However, this quickly blows up in memory usage since it creates all possible state pairs first (cartesian product), not just the useful ones.

https://github.com/unhammer/lttoolbox/branches has some experiments, see e.g. branches product-intersection and df-intersection (the latter is the currently used implementation)