Comment by bigdict

3 years ago

No way. Does it use Scheme?

EDIT: Half Life 3 confirmed: "Presents key ideas of machine learning using a small, manageable subset of the Scheme language"

Some time ago I wrote this: https://notabug.org/ZelphirKaltstahl/guile-ml -- It contains a parallelized decision tree implementation in GNU Guile, a Scheme dialect. There is also https://github.com/lloda/guile-ffi-cblas which at least gives fast matrix multiplication. Example usage I have here: https://notabug.org/ZelphirKaltstahl/guile-math-examples/src...

I don't know what is in the book, but things are possible.

I am looking at the GitHub repo for the Malt library developed in the book https://github.com/themetaschemer/malt. It looks like they use Racket (Scheme) vectors to implement tensors. I experimented with loading Keras simple models into Racket several years ago: the built in math library matrix support was fast enough for my needs so the book software may be both pedagogical and useful for smaller problems.

EDIT: I have not tried the OpenBLAS Racket bindings here (https://github.com/soegaard/sci) but perhaps the low level tensor and tensor ops book code could be optimized,

Have not tries this one (yet) but Racket/base is fine for the previous books.

  • IIRC you can use Racket base so long as you define the “atom” function per the book authors