mrkn / pycall.rb

Calling Python functions from the Ruby language
MIT License
1.05k stars 72 forks source link

Can't import CountVectorizer from 'sklearn.feature_extraction.text #73

Closed rahmatullah5 closed 4 years ago

rahmatullah5 commented 6 years ago

I am having an issue (undefined method module_eval when trying to import CountVectorizer from sklearn.feature_extraction.text. My Code: pyfrom :'sklearn.feature_extraction.text', import: :CountVectorizer

image

Am I missing something, or is this library not supported yet on pycall?

mrkn commented 5 years ago

@rahmatullah5 pyimport and pyfrom are module function, so they cannot be used in the instance context.

shamscorner commented 4 years ago

Then how can I import this? pyfrom :'sklearn.preprocessing', import: :PolynomialFeatures