nok / sklearn-porter

Transpile trained scikit-learn estimators to C, Java, JavaScript and others.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Port CountVectorizer

nicolalandro opened this issue · comments

For text mining it's important to fit also a CountVectorizer (or a TFIDFTransformer), so should be possible to export it in the targhet lenguage

Currently, is there any alternative way?

@Opdoop the way is to extract the dictionary from CountVectorizer (get_feature_names()) and reimplement the logic manually.
You can do the same thing on TFIDF.

Hello @nicolalandro ,

can you provide some snippets? Withit I will have a better start.

Kind regards,
Darius