NeuromorphicProcessorProject / snn_toolbox

Toolbox for converting analog to spiking neural networks (ANN to SNN), and running them in a spiking neuron simulator.
MIT License
360 stars 104 forks source link

Normalize weights not needed for Loihi #110

Closed jimzhou112 closed 3 years ago

jimzhou112 commented 3 years ago

Hello,

I noticed that for your INIsimulator example, the config file contains normalize = True. Setting it to be false would cause accuracy degradation. However, this normalization is not necessary for deployment on Loihi to achieve good accuracy. I noticed that there is a comment that states normalization is not needed for Loihi backend, as seen below.

config['tools'] = { 'evaluate_ann': True, # Test ANN on dataset before conversion. 'normalize': False # Not needed for Loihi backend. }

Could you explore a little more in-depth why normalization is not necessary for the Loihi backend only? It seems Loihi performs very well without it.

rbodo commented 3 years ago

The reason is simply that NxTF (the compiler that the toolbox uses to map a network to Loihi) already applies some form of parameter normalization (see Sec. 2.3.7 in this paper). It doesn't hurt to do it in the toolbox as well, but there is no benefit to be expected.