Fork me on GitHub

Project Notes

#055

A demonstration of the k-nearest neighbors algorithm implemented using tensorflow-js with node.js.

Notes

Libraries

Uses the following npm modules:

Example

$ node example.js
2019-03-02 11:13:57.713521: I tensorflow/core/platform/cpu_feature_guard.cc:141] Your CPU supports instructions that this TensorFlow binary was not compiled to use: SSE4.2 AVX AVX2 FMA
Guess: 1251260 error: -15.323502304147466
Guess: 519756.5 error: -11.344580119965723
Guess: 433700 error: -2.047058823529412
Guess: 455800 error: 19.327433628318584
Guess: 699750 error: 7.806324110671936
Guess: 584260 error: -14.106372465729613
Guess: 835450 error: -8.782552083333334
Guess: 1329790 error: 13.227406199021207
Guess: 279422.5 error: -36.336911441815076
Guess: 228767.5 error: 7.381578947368421

Credits and References

About LCK#55 nodeknntensorflow
Project Source on GitHub Return to the Project Catalog

LittleCodingKata is my collection of programming exercises, research and code toys broadly spanning things that relate to programming and software development (languages, frameworks and tools).

These range from the trivial to the complex and serious. Many are inspired by existing work and I'll note credits and references where applicable. The focus is quite scattered, as I variously work on things new and important in the moment, or go back to revisit things from the past.

This is primarily a personal collection for my own edification and learning, but anyone who stumbles by is welcome to borrow, steal or reference the work here. And if you spot errors or issues I'd really appreciate some feedback - create an issue, send me an email or even send a pull-request.

LittleArduinoProjects LittleModelArt More on my blog