Spiking Neural Networks for Computer Vision

Published: 9 March 2018| Version 1 | DOI: 10.17632/84pvnm3rj3.1
Contributors:
Petruț Antoniu Bogdan,
Steve B. Furber,
Garibaldi Pineda-Garcia,
Michael Hopkins

Description

EVS ------------------------------ Root directory: EVS Description of data: 1. Multiscale representation: > INPUT FILES: The first digit of the MNIST dataset was converted using an EVS (pyDVS) emulator and stored as (neuron id, time stamps) pairs. These were stored as text and compressed using the bzip2 Python package, resulting in the file mnist_img_00000_class_5.txt.bz2 . 2. Motion sensing: > INPUT FILES: Images representing a boucing ball are stored in the bouncing_ball_sequence_w_064_h_064_bw_05.zip archive file, these were processed with an EVS emulator and results in the input file for the experiment bouncing_ball_sequence_w_064_h_064_bw_05___spikes.txt.bz2 . The files correct_0_0_3.txt and incorrect_0_0_3.txt are to be processed to generate voltage curves shown in the paper, they contain membrane voltage and slow neurotransmitter levels through the steps of a simulation. > OUTPUT FILES: Motion sensing results can be found in motion_outputs___2018-02-27-12-47.pickle.bz2 , this contains a dictionary of spike arrays for each population measured during the experiments. They were stored using the standard Python pickle format and later compressed using the bzip2 Python package. ====================== MNIST Structural plasticity ------------------------------ Root directory: MNIST Structural plasticity > INPUT FILES: the input MNIST Digits which are loaded into the mnist_topographic_map.py or mnist_topographic_map_rate_based.py scripts (as exemplified in open_rate_files.ipynb) > RESULT FILES: contains the connectivity, spiking activity and parameters used for training and for testing The results are contained within numpy .npz files and are contained within the RESULT FILES folder. If the files' names start with "testing" then the file contains results from the testing phase of the network, conversely, the ones with prefix (starting with mnist_case_*...) contain post-training network information. Case 1 refers to networks in which both synaptic plasticity and structural plasticity operate at the same time, while in case 3 synapses have static weight, but the connectivity changes in real time. Case 2 is case 3 without lateral connectivity. The structure of the .npz data files can be interrogated in python. To this end, the iPython (Jupyter) notebooks (.ipynb) show how this connectivity/activity can be extracted and analysed. The data which contains the description "rate_based" in the name is to be analysed with the notebook "Large-scale MNIST network - rate based.ipynb", while the ones with description "cs_on_off " is to be analysed with the notebook "Large-scale MNIST network 2 source inputs.ipynb". ====================== Maximum entropy sampling ------------------------------ Root directory: Maximum entropy > input: pre-processed image and label data from the MNIST training set required by the C code ======================

Files

Steps to reproduce

EVS ------------------------------ 1. Install SpiNNaker tools (python 2.7) 2. Change branch to "bimpc" 3. Install vision package (from the repository linked bellow, i.e "chanokin/vision" ) 4. Change to branch bimpc 5. Follow instructions included in README files included for each subfolder of EVS ====================== MNIST Structural plasticity ------------------------------ 1. Install SpiNNaker tools (python 2.7) 2. Change all branches to structural_plasticity (if available) -- might be deprecated (should be included in master) 3. For training run (see available parameters by typing python mnist_topographic_map.py --help) NOTE: In order to run these commands, a SpiNNaker board MUST be available, either on site or remotely. ``python mnist_topographic_map.py --case 3 --no_iteration 300000 --t_record 300000 --lat_inh 1 -o mnist_case_3_5hz_cs_on_off_smax_96_sigma_lat_2 --sigma_form_lat 2 --t_stim 200 --f_mean 5 --s_max 96`` 4. For testing run (see available parameters by typing python mnist_topographic_map.py --help) ``python mnist_topographic_map.py --case 3 --no_iteration 300000 --t_record 300000 --lat_inh 1 -o testing_mnist_case_3_5hz_cs_on_off_smax_96_sigma_lat_2 --sigma_form_lat 2 --t_stim 200 --f_mean 5 --s_max 96 --testing mnist_case_3_5hz_cs_on_off_smax_96_sigma_lat_2.npz`` 5. For analysis open either Large-scale MNIST network - rate based.ipynb or Large-scale MNIST network 2 source inputs on off.ipynb based on whether you want to analyse rate-based, non-filtered input, or filtered input respectively. ====================== Maximum entropy sampling ------------------------------ This code shows the operation of the dendritic branch sampling algorithm as described in section 5 of the paper and exemplified in figures 20-22. There are source and header files described as 'private' and 'public'. Private code is garnered from a proprietary code library owned by Michael Hopkins which was used for some of the research, algorithms and analysis described in this paper. The essential functions that are required to demonstrate operation of the dendritic branch sampling algorithm have been extracted as source to allow a fully open build and test of the algorithm. Public code has been generated during research time at the University of Manchester and contains all the essential features of the algorithm itself. The binary files 'MNIST-train-60k-images' and 'MNIST-train-60k-labels' must be available in a position defined in the macros TRAIN_IMAGES and TRAIN_LABELS at the top of db_public.h Usage instructions are described in db test code notes.txt