rattle / hoatzin Goto Github PK
View Code? Open in Web Editor NEWSVM Classifier in Ruby
License: Other
SVM Classifier in Ruby
License: Other
Hello, perhaps I've just missed something, but I see some strange behaviour when calling classify method for several times. The first call goes with no error, but any subsequent results the error below:
NoMethodError: You have a nil object when you didn't expect it!
You might have expected an instance of Array.
The error occurred while evaluating nil.length
from /home/moe/.rvm/gems/ruby-1.9.2-p0/gems/hoatzin-0.2.1/lib/feature_vector/builder.rb:74:in build_vector' from /home/moe/.rvm/gems/ruby-1.9.2-p0/gems/hoatzin-0.2.1/lib/feature_vector/builder.rb:28:in
build_query_vector'
from /home/moe/.rvm/gems/ruby-1.9.2-p0/gems/hoatzin-0.2.1/lib/classifier.rb:59:in `classify'
I've created a very simple class (https://gist.github.com/869573) to test hoatzin and it seems I am doing something wrong... I am calling train method on my class first, then classify, first call is ok, subsequent - fails.
c.classify('Testig Document')
NoMethodError: You have a nil object when you didn't expect it!
You might have expected an instance of Array.
The error occurred while evaluating nil.length
from /home/karthikselva/.rvm/gems/ruby-1.8.7-p358/gems/hoatzin-0.2.1/lib/feature_vector/builder.rb:74:in build_vector' from /home/karthikselva/.rvm/gems/ruby-1.8.7-p358/gems/hoatzin-0.2.1/lib/feature_vector/builder.rb:28:in
build_query_vector'
from /home/karthikselva/.rvm/gems/ruby-1.8.7-p358/gems/hoatzin-0.2.1/lib/classifier.rb:59:in `classify'
from (irb):6
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.