Editing
Neuromorphic
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== <span style="color: #FFFFFF;">Applying</span> == '''Spiking Neural Network with SpikingJelly:''' <syntaxhighlight lang="python"> import torch import torch.nn as nn from spikingjelly.activation_based import neuron, functional, layer class SpikingCNN(nn.Module): """Simple SNN for image classification.""" def __init__(self, T=8, num_classes=10): super().__init__() self.T = T # Number of time steps self.encoder = nn.Sequential( layer.Conv2d(1, 32, 3, padding=1), nn.BatchNorm2d(32), neuron.LIFNode(tau=2.0), # Leaky Integrate-and-Fire neuron layer.MaxPool2d(2), layer.Conv2d(32, 64, 3, padding=1), nn.BatchNorm2d(64), neuron.LIFNode(tau=2.0), layer.MaxPool2d(2), ) self.classifier = nn.Sequential( layer.Flatten(), layer.Linear(64*7*7, 256), neuron.LIFNode(tau=2.0), layer.Linear(256, num_classes) ) functional.set_step_mode(self, step_mode='m') # Multi-step mode def forward(self, x): # x: (B, C, H, W) β repeat over T time steps x_seq = x.unsqueeze(0).repeat(self.T, 1, 1, 1, 1) # (T, B, C, H, W) out = self.encoder(x_seq) out = self.classifier(out) return out.mean(0) # Average over time steps </syntaxhighlight> ; Neuromorphic hardware comparison : '''Intel Loihi 2''' β 1M neurons, on-chip learning, research-focused : '''IBM TrueNorth''' β 4096 cores, 256M synapses, 70mW at full operation : '''BrainScaleS''' β Analog neuromorphic, 1000Γ faster than biological real-time : '''SpiNNaker 2''' β Manchester, ARM-based, flexible SNN simulation : '''Akida (BrainChip)''' β Commercial edge neuromorphic chip for inference </div> <div style="background-color: #8B4500; color: #FFFFFF; padding: 20px; border-radius: 8px; margin-bottom: 15px;">
Summary:
Please note that all contributions to BloomWiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
BloomWiki:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Namespaces
Page
Discussion
English
Views
Read
Edit
View history
More
Search
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Tools
What links here
Related changes
Special pages
Page information