fix problem in SVM with path on windows

This commit is contained in:
Arkadiusz Kondas 2016-07-04 22:22:22 +02:00
parent 4c82676910
commit a2aa27adba

View File

@ -211,7 +211,7 @@ class SupportVectorMachine
*/ */
private function buildTrainCommand(string $trainingSetFileName, string $modelFileName): string private function buildTrainCommand(string $trainingSetFileName, string $modelFileName): string
{ {
return sprintf('%ssvm-train%s -s %s -t %s -c %s -n %s -d %s%s -r %s -p %s -m %s -e %s -h %d -b %d \'%s\' \'%s\'', return sprintf('%ssvm-train%s -s %s -t %s -c %s -n %s -d %s%s -r %s -p %s -m %s -e %s -h %d -b %d %s %s',
$this->binPath, $this->binPath,
$this->getOSExtension(), $this->getOSExtension(),
$this->type, $this->type,
@ -226,8 +226,8 @@ class SupportVectorMachine
$this->tolerance, $this->tolerance,
$this->shrinking, $this->shrinking,
$this->probabilityEstimates, $this->probabilityEstimates,
$trainingSetFileName, escapeshellarg($trainingSetFileName),
$modelFileName escapeshellarg($modelFileName)
); );
} }
} }