fangwei123456 / spikingjelly

SpikingJelly is an open-source deep learning framework for Spiking Neural Network (SNN) based on PyTorch.
https://spikingjelly.readthedocs.io
Other
1.22k stars 233 forks source link

请问如果本身使用时序数据,假设数据维度为(B,C,T),还需要额外模拟一个时间T吗,然后在T循环吗?可否出一个时序数据的教程?非常感谢您的回复 #525

Closed thebug-dev closed 2 months ago

thebug-dev commented 2 months ago

Read before creating a new issue

For faster response

You can @ the corresponding developers for your issue. Here is the division:

Features Developers
Neurons and Surrogate Functions fangwei123456
Yanqi-Chen
CUDA Acceleration fangwei123456
Yanqi-Chen
Reinforcement Learning lucifer2859
ANN to SNN Conversion DingJianhao
Lyu6PosHao
Biological Learning (e.g., STDP) AllenYolk
Others Grasshlw
lucifer2859
AllenYolk
Lyu6PosHao
DingJianhao
Yanqi-Chen
fangwei123456

We are glad to add new developers who are volunteering to help solve issues to the above table.

Issue type

SpikingJelly version

0.0.0.0.2

Description

...

Minimal code to reproduce the error/bug

import spikingjelly
# ...
thebug-dev commented 2 months ago

按照您mnist的教程: for t in range(args.T): encoded_img = encoder(img) # 对输入图片进行编码 out_fr += net(encoded_img) # 计算网络输出的累加值 out_fr = out_fr / args.T # 计算平均输出 如果数据集为(B,C,T)是否应该先更换维度为(T,B,C),再循环T,最后对T维度做平均?

thebug-dev commented 2 months ago

您好,经过仔细阅读您sj论文,问题已解决,感谢!

fangwei123456 commented 2 months ago

这个里面应该有一些相关的内容

https://spikingjelly.readthedocs.io/zh-cn/latest/activation_based/basic_concept.html

T放在最后一维会导致计算效率大幅度下降,在SJ框架里面是放到第0维的

fangwei123456 commented 2 months ago

https://github.com/fangwei123456/spikingjelly/issues/528#issuecomment-2081435585