I noticed a bug in fsa-0.9.4: when an XML file is read in which an arc
has no weight specified then the weight will be uninitialized and may
be a random value.
The behavior occurred on an Intel(R) Xeon(TM) CPU 3.06GHz system,
after compiling with gcc-3.4.4. For example, the arc weight in the
src/Tools/Fsa/examples/closure-1.fsa machine is -1.792753, or
-1.829887, different on every run, instead of 0.
To fix the bug, insert the line
arc_->weight_ = fsa_->semiring()->one();
in src/Fsa/StorageXml.cc, after line 97, so that you have
arc_->output_ = Epsilon;
arc_->weight_ = fsa_->semiring()->one();
--Markus