haifengl / smile

Statistical Machine Intelligence & Learning Engine

Home Page:https://haifengl.github.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add XMeans with float array type

DobryninVyacheslav opened this issue · comments

In our application, we use a model to turn text into a vector with the float type. Then we convert this vector into a double array for XMeans clustering, after which we convert it back to float to save it in a vector database. We would not like to make these extra conversions. It is also important for us to use float because of the lower memory consumption.

Could you make XMeans work with float arrays as well?

Will do

Thank you!

Can I implement XMeans with float types?
If yes, what is the best way to do it?
The easiest option is to make a copy with float types instead of double.
Would that be acceptable or do you prefer another solution?

There are many dependency class of double[]. I am research a systematic way to support different precisions, which is not easy on Java.

understood thanks