ghc ( if you want to build the API yourself )
raku
zef
git clone [this repo]
setup.bat
zef install JSON::Tiny
zef install Terminal::ANSIColor
ghc main.hs
- Implementation of native Haskell API to process the binary vectors and transformations
- if you do not want to compile the API download the exe here : My drive!
EDX free course about computational neuroscience !
The goal of Hopfield models is to a mathematical model to associative memory especially for images
Here I could implement a first of this model, but there's still a long path towards a totally useful model
(Illustrative example)
my $trainingset = ImageSet.new(
myimages=>{
"image0"=>"image0.json",
"image1"=>"image1.json"
}
);
my $testingset = ImageSet.new(
myimages=>{
"image2"=>"image2.json"
}
);
# this is the info that will populate our training information
my $mytrainingsetfinal = $trainingset.genSet(8);
# this will be the ones used to test the net
my $mytestingsetfinal = $testingset.genSet(8);
my $model = HopfieldNetwork.new(
dataset=>$mytrainingsetfinal,
testset=>$mytestingsetfinal,
title=>"mynet"
); # here we use our generated formatted data to feed the net
$model.predict # store the result
$model.showResult # show the similarities
$model.export # this goes as mymodel.json
$mode.loadModel("mynet") # here goes the name of the json exported from model
- Implementation of zef or panda module
- Implementation of higher features from Hopfield Models and variations