Chez Scheme implementation of Triadic Memory.
Translated from an earlier version of the C implementation.
triadicmemory.ss is a R6RS Scheme library: it should be usable with any R6RS conformant Scheme system.
triadic-test.ss is a Chez Scheme benchmark/test script which compiles and executes itself using parameters which optimize for execution speed:
ChezScheme % scheme
Chez Scheme Version 9.5.7.6
Copyright 1984-2021 Cisco Systems, Inc.
>
ChezScheme % triadic-test.ss z 1000 10
Testing TriadicMemory with 100000 SDRs of size 1000 and solidity of 10 ON bits
100000 vectors generated in 158ms
100000 triples stored in 1248ms
100000 queries in 6327ms
0 errors
ChezScheme % triadic-test.ss x
Testing TriadicMemory with 100000 SDRs of size 1000 and solidity of 10 ON bits
100000 vectors generated in 157ms
100000 triples stored in 1253ms
100000 queries in 8712ms
0 errors
ChezScheme % triadic-test.ss y
Testing TriadicMemory with 100000 SDRs of size 1000 and solidity of 10 ON bits
100000 vectors generated in 162ms
100000 triples stored in 1252ms
100000 queries in 23837ms
0 errors
A Windows .exe is available
For other platforms (including Apple Silicon) the Racket fork with these instructions is suggested.