CEA-LIST / N2D2

N2D2 is an open source CAD framework for Deep Neural Network simulation and full DNN-based applications building.
Other
146 stars 35 forks source link

Cannot run Spike example #30

Closed vankhoa21991 closed 5 years ago

vankhoa21991 commented 5 years ago

Hello, I tried to run the example to convert CNN to SNN (LeNet), by these two commands: ../build/bin/n2d2 "../models/LeNet.ini" -learn 6000000 -log 100000 ../build/bin/n2d2 "../models/LeNet_Spike.ini" -test

And I ran into this error: Option -test: perform testing Loading network configuration file ../models/LeNet_Spike.ini Layer: conv1 [Conv(Transcode_CUDA)] Notice: Could not open configuration file: conv1.cfg Notice: Unused section fc2.Target in INI file Notice: Unused section fc2.config in INI file Time elapsed: 0.882318 s Error: Cell_Spike::addInput(): mapping length must be equal to the number of outputs

Do you know where does it come from? Thanks

vankhoa21991 commented 5 years ago

The same happens with mnist24_16c4s2_24c5s2_150_10.ini

olivierbichler-cea commented 5 years ago

Hello, Thanks for your feedbacks, this was a bug that should be corrected in the latest commit 20be5f401c15802a4de08bcd649f4b84e10ce223 Please tell us if everything is all right now.

vankhoa21991 commented 5 years ago

Hello, Thanks for your help, it works now.

olivierbichler-cea commented 5 years ago

Closing the issue, please feel free to reopen it if necessary.

dipsankarb commented 2 years ago

./../build/bin/n2d2 "mnist24_16c4s2_24c5s2_150_10_Spike.ini" -test Option -test: perform testing Loading network configuration file mnist24_16c4s2_24c5s2_150_10_Spike.ini Layer: conv1 [Conv(Transcode)] Notice: Could not open configuration file: conv1.cfg

Shared synapses: 256

Virtual synapses: 30976

Inputs dims: 24 24 1

Outputs dims: 11 11 16

Layer: conv2 [Conv(Transcode)] Notice: Could not open configuration file: conv2.cfg

Shared synapses: 2250

Virtual synapses: 36000

Inputs dims: 11 11 16

Outputs dims: 4 4 24

Layer: fc1 [Fc(Transcode)] Notice: Could not open configuration file: fc1.cfg

Synapses: 57600

Inputs dims: 4 4 24

Outputs dims: 1 1 150

Layer: fc2 [Fc(Transcode)] Notice: Could not open configuration file: fc2.cfg

Synapses: 1500

Inputs dims: 1 1 150

Outputs dims: 1 1 10

Target: fc2 (target value: 1 / default value: 0 / top-n value: 1) Remove extra Reshape... Total number of neurons: 2480 Total number of nodes: 2480 Total number of synapses: 61606 Total number of virtual synapses: 126076 Total number of connections: 126076 Notice: Unused section fc2.Target in INI file GD Warning: PNG image support has been disabled GD Warning: PNG image support has been disabled Learning database size: 48000 images Validation database size: 12000 images Testing database size: 10000 images