Upload README.md with huggingface_hub
Browse files
README.md
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
license: mit
|
| 3 |
+
tags:
|
| 4 |
+
- neurocuda
|
| 5 |
+
- spiking-neural-network
|
| 6 |
+
- snn
|
| 7 |
+
- neuromorphic
|
| 8 |
+
- vision
|
| 9 |
+
- vision
|
| 10 |
+
- cifar-10
|
| 11 |
+
- strongcnn
|
| 12 |
+
- classification
|
| 13 |
+
- medium
|
| 14 |
+
pipeline_tag: image-classification
|
| 15 |
+
---
|
| 16 |
+
|
| 17 |
+
# neurocuda/strongcnn-cifar10-snn ⚠️
|
| 18 |
+
|
| 19 |
+
7-layer CNN SNN for CIFAR-10. Gap of 6% with conversion + fine-tuning. Larger gap than ResNet-18 due to higher non-linearity. Good for studying conversion challenges in medium-depth networks.
|
| 20 |
+
|
| 21 |
+
## Model Details
|
| 22 |
+
|
| 23 |
+
- **Task:** image-classification
|
| 24 |
+
- **Dataset:** CIFAR-10
|
| 25 |
+
- **Architecture:** StrongCNN (7-layer, BatchNorm, wider channels)
|
| 26 |
+
- **Training:** ANN → QCFS → IF + BPTT FT (conversion + fine-tune)
|
| 27 |
+
- **Status:** beta
|
| 28 |
+
|
| 29 |
+
## Performance
|
| 30 |
+
|
| 31 |
+
- **SNN Accuracy:** 74.3% | **Gap:** +6.00% (within ANN)
|
| 32 |
+
- **Parameters:** 4,800,000 (18.3 MB)
|
| 33 |
+
- **Timesteps:** T=16
|
| 34 |
+
|
| 35 |
+
## Usage
|
| 36 |
+
|
| 37 |
+
```python
|
| 38 |
+
import neurocuda as nc
|
| 39 |
+
|
| 40 |
+
# Load the pre-converted spiking model
|
| 41 |
+
snn, info = nc.hub.load("neurocuda/strongcnn-cifar10-snn")
|
| 42 |
+
|
| 43 |
+
# The model is already spiking — binary IF/LIF spikes, stateful membrane
|
| 44 |
+
snn.eval()
|
| 45 |
+
|
| 46 |
+
# 4D input (single frame)
|
| 47 |
+
import torch
|
| 48 |
+
x = torch.randn(1, 2, 34, 34) # Adjust channels/size for your model
|
| 49 |
+
output = snn(x)
|
| 50 |
+
|
| 51 |
+
# 5D input (temporal — event cameras, video)
|
| 52 |
+
x5 = torch.randn(2, 16, 2, 34, 34) # (Batch, Timesteps, Channels, H, W)
|
| 53 |
+
output5 = snn(x5)
|
| 54 |
+
```
|
| 55 |
+
|
| 56 |
+
## Hardware Compatibility
|
| 57 |
+
|
| 58 |
+
- **Validated on:** GPU, CPU
|
| 59 |
+
- **NIR Export:** Yes — deployable to Loihi 2, SpiNNaker, FPGA
|
| 60 |
+
|
| 61 |
+
## Conversion Method
|
| 62 |
+
|
| 63 |
+
ANN → QCFS → IF + BPTT FT (conversion + fine-tune)
|
| 64 |
+
|
| 65 |
+
## Citation
|
| 66 |
+
|
| 67 |
+
```bibtex
|
| 68 |
+
@software{neurocuda2026,
|
| 69 |
+
title = {NeuroCUDA: A PyTorch-to-Neuromorphic Compiler},
|
| 70 |
+
author = {Krishna Varma},
|
| 71 |
+
year = {2026},
|
| 72 |
+
url = {https://github.com/neurocuda/neurocuda}
|
| 73 |
+
}
|
| 74 |
+
```
|
| 75 |
+
|
| 76 |
+
## Limitations
|
| 77 |
+
|
| 78 |
+
⚠️ Single seed result. Multi-seed verification pending.
|