Skip to content

Commit

Permalink
Deal with Infinity score in test (#133)
Browse files Browse the repository at this point in the history
  • Loading branch information
ibnesayeed authored and Ch4s3 committed Jan 17, 2017
1 parent be47188 commit 795bed1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/bayes/bayesian_integration_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ def classification_scores(classifier)
@testing_set.collect do |line|
parts = line.strip.split("\t")
result, score = classifier.classify_with_score(parts.last)
"#{result}:#{score}"
score.infinite? ? "irrelevant" : "#{result}:#{score}"
end
end
end

0 comments on commit 795bed1

Please sign in to comment.