HamNN
This repo, as well as the associated cli app VHamNN, have been superseded by the repo
VHamML
.
A machine learning (ML) library for classification using a nearest neighbor algorithm based on Hamming distances. hamnn documentation
There is an associated Command Line Interface app,
VHamNN
You can use the library with your own datasets, or with a selection of publicly available datasets that are widely used for demonstrating and testing ML classifiers, in the
datasets
Classification accuracy with datasets in the
datasets
Do we really need another ML library? Read this!
And have a look here for a more complete
description and potential use cases
To use the HamNN library
This assumes you already have V installed on your system. If not, please refer to the
VHamNN readme
v install holder66.hamnn
And (optionally) libraries used by HamNN for generating plots and for colored output on the console:
v install vsl
v install Mewzax.chalk
In your V code:
import holder66.hamnn
Example source code:
module main
import hamnn
import os
fn main() {
opts := hamnn.Options{
show_flag: true
}
datafile_path := os.home_dir() + '/.vmodules/holder66/hamnn/datasets/iris.tab'
println(datafile_path)
ds := hamnn.load_file(datafile_path)
result := hamnn.analyze_dataset(ds, opts)
println(result)
}
Getting help:
The V lang community meets on Discord
For bug reports, feature requests, etc., please raise an issue on github:
MNIST dataset
The mnist_train.tab file is too large to keep in the repository. If you wish to experiment with it, it can be downloaded by right-clicking on
this link
wget http://henry.olders.ca/datasets/mnist_train.tab
Previous versions
The most recent version of the HamNN algorithm (2012) was written in python; one can experiment with it via a
web-based interface
The process of development in its early stages is described in
this essay
Copyright (c) 2017, 2022: Henry Olders.