使用重复元素的网络(VGG) 讨论区


#21

我用的是pip,木有conda。。。所以,只要第一行git clone就够了?


#22

conda env create -f environment.yml这一行是需要的,应该是在创建环境,然后才能进行source activate gluon来激活。
所以建议先安装一个conda(或者miniconda),然后安装git,然后运行上面4行就可以了,如果不懂,建议看看教程视频里面的第一课,开始的时候李沐大神有安装的一系列过程。


#23

谢谢大佬。。。确实要mxnet的最新版。。。现在可以跑了。。。0bug 0error。。。:grin::grin::grin:
其他什么都没有动。。。没有那么复杂啦。。。


#24

因为需要新一点的mxnet才支持.add()加多个layer

:+1:, 送一个“调的一手好参”徽章


#25

把batchsize或者图像resize设置小一些


#26

请问更新的时候解压的文件夹要覆盖之前的么?


#27

恩, 我是按照git方式更新的教程


#28

特别羡慕你们这些可以跑100次的,我迭代了7轮,就用了12.5小时,测试和训练只达到了0.92+。唉,硬伤啊。


#29

我也遇到了这个问题,请问您解决了吗?


#30

win10 i3 8g内存 750ti
跑教程的demo
提示内存不足
cudaMalloc failed: out of memory
只有我一个人遇到?
Start training on gpu(0)
[11:34:50] d:\program files (x86)\jenkins\workspace\mxnet-tag\mxnet\src\operator./cudnn_algoreg-inl.h:107: Running performance tests to find the best convolution algorithm, this can take a while… (setting env variable MXNET_CUDNN_AUTOTUNE_DEFAULT to 0 to disable)
[11:34:58] D:\Program Files (x86)\Jenkins\workspace\mxnet-tag\mxnet\dmlc-core\include\dmlc/logging.h:308: [11:34:58] d:\program files (x86)\jenkins\workspace\mxnet-tag\mxnet\src\storage./pooled_storage_manager.h:107: cudaMalloc failed: out of memory
[11:34:58] D:\Program Files (x86)\Jenkins\workspace\mxnet-tag\mxnet\dmlc-core\include\dmlc/logging.h:308: [11:34:58] d:\program files (x86)\jenkins\workspace\mxnet-tag\mxnet\src\engine./threaded_engine.h:359: [11:34:58] d:\program files (x86)\jenkins\workspace\mxnet-tag\mxnet\src\storage./pooled_storage_manager.h:107: cudaMalloc failed: out of memory
A fatal error occurred in asynchronous engine operation. If you do not know what caused this error, you can try set environment variable MXNET_ENGINE_TYPE to NaiveEngine and run with debugger (i.e. gdb). This will force all operations to be synchronous and backtrace will give you the series of calls that lead to this error. Remember to set MXNET_ENGINE_TYPE back to empty after debugging.


#31

这个似乎要占用4G多的显存


#32

感觉没有用到gpu 1050;,在跑VGG的时候,截的图~是我安装方法不正确么?希望大侠指点迷津··多谢:no_mouth:


#34

我也是遇到这个问题。。。


#35

而且在跑的时候报错,提示:
Python 3.6.3 |Anaconda, Inc.| (default, Oct 15 2017, 03:27:45) [MSC v.1900 64 bit (AMD64)]
Type “copyright”, “credits” or “license” for more information.

IPython 6.1.0 – An enhanced Interactive Python.

runfile(‘E:/Anaconda_workspace/MxnetCNN/vgg_net.py’, wdir=‘E:/Anaconda_workspace/MxnetCNN’)
D:\Anaconda3\lib\site-packages\h5py_init_.py:36: FutureWarning: Conversion of the second argument of issubdtype from float to np.floating is deprecated. In future, it will be treated as np.float64 == np.dtype(float).type.
from ._conv import register_converters as _register_converters
D:\Anaconda3\lib\site-packages\mxnet\optimizer.py:136: UserWarning: WARNING: New optimizer mxnet.optimizer.NAG is overriding existing optimizer mxnet.optimizer.NAG
Optimizer.opt_registry[name].name))
D:\Anaconda3\lib\site-packages\urllib3\contrib\pyopenssl.py:46: DeprecationWarning: OpenSSL.rand is deprecated - you should use os.urandom instead
import OpenSSL.SSL
(2, 128, 8, 8)
D:\Anaconda3\lib\site-packages\mxnet\gluon\data\vision\datasets.py:82: DeprecationWarning: The binary mode of fromstring is deprecated, as it behaves surprisingly on unicode inputs. Use frombuffer instead
label = np.fromstring(fin.read(), dtype=np.uint8).astype(np.int32)
D:\Anaconda3\lib\site-packages\mxnet\gluon\data\vision\datasets.py:86: DeprecationWarning: The binary mode of fromstring is deprecated, as it behaves surprisingly on unicode inputs. Use frombuffer instead
data = np.fromstring(fin.read(), dtype=np.uint8)
Start training on gpu(0)
Epoch 0. Loss: 0.826, Train acc 0.69, Test acc 0.85, Time 207.1 sec
Traceback (most recent call last):

File “”, line 1, in
runfile(‘E:/Anaconda_workspace/MxnetCNN/vgg_net.py’, wdir=‘E:/Anaconda_workspace/MxnetCNN’)

File “D:\Anaconda3\lib\site-packages\spyder\utils\site\sitecustomize.py”, line 710, in runfile
execfile(filename, namespace)

File “D:\Anaconda3\lib\site-packages\spyder\utils\site\sitecustomize.py”, line 101, in execfile
exec(compile(f.read(), filename, ‘exec’), namespace)

File “E:/Anaconda_workspace/MxnetCNN/vgg_net.py”, line 73, in
utils.train(train_data,test_data,net,loss,trainer,ctx,num_epochs=10)

File “E:\Anaconda_workspace\MxnetCNN\utils.py”, line 132, in train
for i, batch in enumerate(train_data):

File “E:\Anaconda_workspace\MxnetCNN\utils.py”, line 31, in iter
data = self.dataset[:]

File “D:\Anaconda3\lib\site-packages\mxnet\gluon\data\dataset.py”, line 207, in getitem
return self._transform(self._data[idx], self._label[idx])

File “E:\Anaconda_workspace\MxnetCNN\utils.py”, line 59, in transform_mnist
return nd.transpose(data.astype(‘float32’), (0,3,1,2))/255, label.astype(‘float32’)

File “D:\Anaconda3\lib\site-packages\mxnet\ndarray\ndarray.py”, line 1841, in astype
res = empty(self.shape, ctx=self.context, dtype=dtype)

File “D:\Anaconda3\lib\site-packages\mxnet\ndarray\ndarray.py”, line 3423, in empty
return NDArray(handle=_new_alloc_handle(shape, ctx, False, dtype))

File “D:\Anaconda3\lib\site-packages\mxnet\ndarray\ndarray.py”, line 139, in _new_alloc_handle
ctypes.byref(hdl)))

OSError: [WinError -529697949] Windows Error 0xe06d7363


#36

试试cnn-scratch那个notebook,看看能不能把训练样本载入显存。。。


#37

谢谢你,马上百度下用法:joy:


#38

cnn-scratch那个notebook也是报错吗?是怎样的?


#39

Epoch 0. Loss: 0.865, Train acc 0.68, Test acc 0.83, Time 92.9 sec
Traceback (most recent call last):
File “G:/python_work/xujin_data/vgg.py”, line 58, in
trainer, ctx, num_epochs=10)
File “G:\python_work\xujin_data\utils.py”, line 126, in train
for i, batch in enumerate(train_data):
File “G:\python_work\xujin_data\utils.py”, line 25, in iter
data = self.dataset[:]
File “G:\Anaconda3-5.0.1\lib\site-packages\mxnet\gluon\data\dataset.py”, line 207, in getitem
return self._transform(self._data[idx], self._label[idx])
File “G:\python_work\xujin_data\utils.py”, line 53, in transform_mnist
return nd.transpose(data.astype(‘float32’), (0,3,1,2))/255, label.astype(‘float32’)
File “G:\Anaconda3-5.0.1\lib\site-packages\mxnet\ndarray\ndarray.py”, line 1841, in astype
res = empty(self.shape, ctx=self.context, dtype=dtype)
File “G:\Anaconda3-5.0.1\lib\site-packages\mxnet\ndarray\ndarray.py”, line 3423, in empty
return NDArray(handle=_new_alloc_handle(shape, ctx, False, dtype))
File “G:\Anaconda3-5.0.1\lib\site-packages\mxnet\ndarray\ndarray.py”, line 139, in _new_alloc_handle
ctypes.byref(hdl)))
OSError: [WinError -529697949] Windows Error 0xe06d7363

Process finished with exit code 1


#40

那啥cnn-scratch不知道怎么使用,网站也打不开


#41

卧槽。。。教程都不会玩?
好好去看看吧。。。
zh.gluon.ai