我正在研究尖峰神经网络,并从https://github.com/peter-u-diehl/stdp-mnist下载了一个基准测试
我有严重的问题运行这个代码,我已经安装了必要的东西。你知道吗
查看代码运行时生成的错误
100%完成,已过0秒,剩余约0秒。你知道吗
100%完成,已过0秒,剩余约0秒。你知道吗
100%完成,已过0秒,剩余约0秒。你知道吗
保存结果
Traceback (most recent call last):
File "peterb1.py", line 516, in <module>
np.save(data_path + 'activity/resultPopVecs' + str(num_examples), result_monitor)
File "/srv/home/compsci/anaconda2/envs/py2b1/lib/python2.7/site-packages
/numpy/lib/npyio.py", line 490, in save
fid = open(file, "wb")
IOError: [Errno 2] No such file or directory: './activity/resultPopVecs100.npy'
compsci@cclab1-5:~/Desktop/pt1$
代码
print ('save results')
if not test_mode:
save_theta()
if not test_mode:
save_connections()
else:
np.save(data_path + 'activity/resultPopVecs' + str(num_examples), result_monitor)
np.save(data_path + 'activity/inputNumbers' + str(num_examples), input_numbers)
基于您的错误
No such file or director: './activity/resultPopVecs100.npy
,您可能以错误的方式生成文件路径。你知道吗/activity
文件夹中有一个名为resultPopVecs100.npy
的文件。你知道吗os
python库生成文件路径。你知道吗要获得运行脚本的实际系统文件路径,请使用以下代码段,然后使用该
BASE_DIR
构造文件路径的其余部分。你知道吗相关问题 更多 >
编程相关推荐