老的链接好像失效了
INFO io.py: 67: Downloading remote file https://s3-us-west-2.amazonaws.com/detectron/ImageNetPretrained/25093814/X-152-32x8d-IN5k.pkl to /tmp/detectron-download-cache/ImageNetPretrained/25093814/X-152-32x8d-IN5k.pkl
Traceback (most recent call last):
File "/home/wrc/CBNet/tools/train_net.py", line 132, in
main()
File "/home/wrc/CBNet/tools/train_net.py", line 101, in main
assert_and_infer_cfg()
File "/home/wrc/CBNet/detectron/core/config.py", line 1127, in assert_and_infer_cfg
cache_cfg_urls()
File "/home/wrc/CBNet/detectron/core/config.py", line 1136, in cache_cfg_urls
__C.TRAIN.WEIGHTS = cache_url(C.TRAIN.WEIGHTS, C.DOWNLOAD_CACHE)
File "/home/wrc/CBNet/detectron/utils/io.py", line 68, in cache_url
download_url(url, cache_file_path)
File "/home/wrc/CBNet/detectron/utils/io.py", line 114, in download_url
response = urllib2.urlopen(url)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 154, in urlopen
return opener.open(url, data, timeout)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 435, in open
response = meth(req, response)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 548, in http_response
'http', request, response, code, msg, hdrs)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 473, in error
return self._call_chain(args)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 407, in _call_chain
result = func(args)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 556, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
urllib2.HTTPError: HTTP Error 301: Moved Permanently
然后我直接下载了detectron2的pkl权重 放到指定文件夹,又修改了config文件中的WEIGHTS: /home/wrc/CBNet/pretrained/X-152-32x8d-IN5k.pkl
同时def assert_and_infer_cfg(cache_urls=True, make_immutable=True):这里设置为False
但是新下载的权重和网络好像对不上
运行的时候报错
首先是很多参数找不到
INFO net.py: 173: 3_b not found
src_name is score_3_w
INFO net.py: 173: score_3_w not found
src_name is score_3_b
INFO net.py: 173: score_3_b not found
src_name is _pred_3_w
INFO net.py: 173: _pred_3_w not found
src_name is _pred_3_b
INFO net.py: 173: _pred_3_b not found
src_name is _w
然后报gpu的错误
[E net_async_base.cc:377] [enforce fail at context_gpu.cu:495] error == cudaSuccess. 2 vs 0. Error at: /opt/conda/conda-bld/pytorch_1556653000816/work/caffe2/core/context_gpu.cu:495: out of memory
Error from operator:
input: "gpu_0/res4_17_branch2c_bn" input: "gpu_0/res4_18_branch2a_w" input: "gpu_0/__m9_shared" output: "gpu_0/res4_18_branch2a_w_grad" output: "gpu_0/__m16_shared" name: "" type: "ConvGradient" arg { name: "no_bias" i: 1 } arg { name: "kernel" i: 1 } arg { name: "exhaustive_search" i: 0 } arg { name: "stride" i: 1 } arg { name: "pad" i: 0 } arg { name: "order" s: "NCHW" } arg { name: "dilation" i: 1 } device_option { device_type: 1 device_id: 0 } engine: "CUDNN" is_gradient_op: trueframe #0: c10::ThrowEnforceNotMet(char const, int, char const, std::string const&, void const*) + 0x59 (0x7fb0ab76c409 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libc10.so)
frame #1: + 0x281f180 (0x7fb06b638180 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #2: + 0x14db285 (0x7fb08cb45285 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2.so)
frame #3: caffe2::empty(c10::ArrayRef, c10::TensorOptions) + 0x72 (0x7fb08cd38ae2 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2.so)
frame #4: + 0x1465745 (0x7fb06a27e745 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #5: + 0x1468b75 (0x7fb06a281b75 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #6: + 0x1468e8a (0x7fb06a281e8a in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #7: bool caffe2::CudnnConvGradientOp::DoRunWithType<float, float, float, float, float, float, float>() + 0x2c5 (0x7fb06a295315 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #8: caffe2::CudnnConvGradientOp::RunOnDevice() + 0xb0 (0x7fb06a27c8c0 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #9: + 0x13cb0b5 (0x7fb06a1e40b5 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #10: caffe2::AsyncNetBase::run(int, int) + 0x144 (0x7fb08ccf2b94 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2.so)
frame #11: + 0x168f009 (0x7fb08ccf9009 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2.so)
frame #12: c10::ThreadPool::main_loop(unsigned long) + 0x2a3 (0x7fb0ab7662f3 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libc10.so)
frame #13: + 0xc8421 (0x7fb0bff01421 in /home/wrc/anaconda3/envs/py27/bin/../lib/libstdc++.so.6)
frame #14: + 0x76ba (0x7fb0cc5636ba in /lib/x86_64-linux-gnu/libpthread.so.0)
frame #15: clone + 0x6d (0x7fb0cbb8941d in /lib/x86_64-linux-gnu/libc.so.6)
, op ConvGradient
想问下有没有新的可以用的权重链接,或者说可以直接使用的与训练权重可以分享下
老的链接好像失效了 INFO io.py: 67: Downloading remote file https://s3-us-west-2.amazonaws.com/detectron/ImageNetPretrained/25093814/X-152-32x8d-IN5k.pkl to /tmp/detectron-download-cache/ImageNetPretrained/25093814/X-152-32x8d-IN5k.pkl Traceback (most recent call last): File "/home/wrc/CBNet/tools/train_net.py", line 132, in
main()
File "/home/wrc/CBNet/tools/train_net.py", line 101, in main
assert_and_infer_cfg()
File "/home/wrc/CBNet/detectron/core/config.py", line 1127, in assert_and_infer_cfg
cache_cfg_urls()
File "/home/wrc/CBNet/detectron/core/config.py", line 1136, in cache_cfg_urls
__C.TRAIN.WEIGHTS = cache_url(C.TRAIN.WEIGHTS, C.DOWNLOAD_CACHE)
File "/home/wrc/CBNet/detectron/utils/io.py", line 68, in cache_url
download_url(url, cache_file_path)
File "/home/wrc/CBNet/detectron/utils/io.py", line 114, in download_url
response = urllib2.urlopen(url)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 154, in urlopen
return opener.open(url, data, timeout)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 435, in open
response = meth(req, response)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 548, in http_response
'http', request, response, code, msg, hdrs)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 473, in error
return self._call_chain(args)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 407, in _call_chain
result = func(args)
File "/home/wrc/anaconda3/envs/py27/lib/python2.7/urllib2.py", line 556, in http_error_default
raise HTTPError(req.get_full_url(), code, msg, hdrs, fp)
urllib2.HTTPError: HTTP Error 301: Moved Permanently
然后我直接下载了detectron2的pkl权重 放到指定文件夹,又修改了config文件中的WEIGHTS: /home/wrc/CBNet/pretrained/X-152-32x8d-IN5k.pkl 同时def assert_and_infer_cfg(cache_urls=True, make_immutable=True):这里设置为False 但是新下载的权重和网络好像对不上 运行的时候报错 首先是很多参数找不到 INFO net.py: 173: 3_b not found src_name is score_3_w INFO net.py: 173: score_3_w not found src_name is score_3_b INFO net.py: 173: score_3_b not found src_name is _pred_3_w INFO net.py: 173: _pred_3_w not found src_name is _pred_3_b INFO net.py: 173: _pred_3_b not found src_name is _w 然后报gpu的错误 [E net_async_base.cc:377] [enforce fail at context_gpu.cu:495] error == cudaSuccess. 2 vs 0. Error at: /opt/conda/conda-bld/pytorch_1556653000816/work/caffe2/core/context_gpu.cu:495: out of memory Error from operator: input: "gpu_0/res4_17_branch2c_bn" input: "gpu_0/res4_18_branch2a_w" input: "gpu_0/__m9_shared" output: "gpu_0/res4_18_branch2a_w_grad" output: "gpu_0/__m16_shared" name: "" type: "ConvGradient" arg { name: "no_bias" i: 1 } arg { name: "kernel" i: 1 } arg { name: "exhaustive_search" i: 0 } arg { name: "stride" i: 1 } arg { name: "pad" i: 0 } arg { name: "order" s: "NCHW" } arg { name: "dilation" i: 1 } device_option { device_type: 1 device_id: 0 } engine: "CUDNN" is_gradient_op: trueframe #0: c10::ThrowEnforceNotMet(char const, int, char const, std::string const&, void const*) + 0x59 (0x7fb0ab76c409 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libc10.so) frame #1: + 0x281f180 (0x7fb06b638180 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #2: + 0x14db285 (0x7fb08cb45285 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2.so)
frame #3: caffe2::empty(c10::ArrayRef, c10::TensorOptions) + 0x72 (0x7fb08cd38ae2 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2.so)
frame #4: + 0x1465745 (0x7fb06a27e745 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #5: + 0x1468b75 (0x7fb06a281b75 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #6: + 0x1468e8a (0x7fb06a281e8a in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #7: bool caffe2::CudnnConvGradientOp::DoRunWithType<float, float, float, float, float, float, float>() + 0x2c5 (0x7fb06a295315 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #8: caffe2::CudnnConvGradientOp::RunOnDevice() + 0xb0 (0x7fb06a27c8c0 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #9: + 0x13cb0b5 (0x7fb06a1e40b5 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2_gpu.so)
frame #10: caffe2::AsyncNetBase::run(int, int) + 0x144 (0x7fb08ccf2b94 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2.so)
frame #11: + 0x168f009 (0x7fb08ccf9009 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libcaffe2.so)
frame #12: c10::ThreadPool::main_loop(unsigned long) + 0x2a3 (0x7fb0ab7662f3 in /home/wrc/anaconda3/envs/py27/lib/python2.7/site-packages/caffe2/python/../../torch/lib/libc10.so)
frame #13: + 0xc8421 (0x7fb0bff01421 in /home/wrc/anaconda3/envs/py27/bin/../lib/libstdc++.so.6)
frame #14: + 0x76ba (0x7fb0cc5636ba in /lib/x86_64-linux-gnu/libpthread.so.0)
frame #15: clone + 0x6d (0x7fb0cbb8941d in /lib/x86_64-linux-gnu/libc.so.6)
, op ConvGradient
想问下有没有新的可以用的权重链接,或者说可以直接使用的与训练权重可以分享下