Fixed some debugging messages on factors

This commit is contained in:
Jeff Moser
2010-09-27 08:00:22 -04:00
parent 5cb1919c21
commit f816a766d7
6 changed files with 10 additions and 12 deletions

View File

@ -21,11 +21,10 @@ class GaussianPriorFactor extends GaussianFactor
public function __construct($mean, $variance, Variable &$variable)
{
parent::__construct("Prior value going to {0}");
parent::__construct(sprintf("Prior value going to %s", $variable));
$this->_newMessage = new GaussianDistribution($mean, sqrt($variance));
$newMessage = new Message(GaussianDistribution::fromPrecisionMean(0, 0),
"message from {0} to {1}",
$this, $variable);
sprintf("message from %s to %s", $this, $variable));
$this->createVariableToMessageBindingWithMessage($variable, $newMessage);
}