This project is an implementation of a basic SNN library that supports simple image classification example.
-
Python version 3.11.3 >
https://www.python.org/
-
Virtualenv
https://pypi.org/project/virtualenv/
-
Clone the repository
git clone https://github.com/Albert-Osei/SNN-implementation.git
-
Create Virtual Environment
virtualenv .spike-venv
OR
python -m venv spike-venv
-
Activate Virtual Environment
source spike-venv\scripts\activate ~ on~windows
source spike-venv/bin/. activate ~ on~mac
-
Install Dependencies
pip install -r requirements.txt
- cd into the root where the project is cloned
- run classification/classify.py
- this command will use pregenerated weights and output the results of classifying the test images
- to reconstruct the weights, run binary_class/learning.py
- this command will generate new weights file and output
neuron[1-3].pngwhich will show the reconstructed weights. One neuron should look random, the other two will produce a pattern similar to the O, and another a pattern similar to the X.