RuntimeError: DataLoader worker (pid 27) is killed by signal: Bus error.

docker中错误

ERROR: Unexpected bus error encountered in worker. This might be caused by insufficient shared memory (shm).
Traceback (most recent call last):
File "run_on_thn_seq.py", line 44, in <module>
for step, (imgs, img_ids) in enumerate(val_loader):
File "/opt/conda/lib/python3.6/site-packages/torch/utils/data/dataloader.py", line 280, in __next__
idx, batch = self._get_batch()
 File "/opt/conda/lib/python3.6/site-packages/torch/utils/data/dataloader.py", line 259, in _get_batch
return self.data_queue.get()
  File "/opt/conda/lib/python3.6/queue.py", line 164, in get
self.not_empty.wait()  File "/opt/conda/lib/python3.6/threading.py", line 295, in wait
waiter.acquire()  File "/opt/conda/lib/python3.6/site-packages/torch/utils/data/dataloader.py", line 178, in handler
_error_if_any_worker_fails()
RuntimeError: DataLoader worker (pid 69) is killed by signal: Bus error.root@8719bf31dda6:~/deeplabv3/visualization# exit

解决办法

挂载之后设定 shm大小
sudo nvidia-docker run --rm -it -v /home/lab316/Documents/Code/DepthSeg/deeplabv3-torch:/root/deeplabv3 --runtime=nvidia --shm-size 8g -m 32G --memory-swap -1 --name lab316 0.4_cuda9_cudnn7:latest /bin/bash

发布了127 篇原创文章 · 获赞 10 · 访问量 7076
展开阅读全文

没有更多推荐了,返回首页

©️2019 CSDN 皮肤主题: 大白 设计师: CSDN官方博客

分享到微信朋友圈

×

扫一扫,手机浏览