Megvii-BaseDetection / Megvii-BaseDetection/OTA

How to solve the problem:PermissionError: [Errno 13] Permission denied: '/data'

Open
#13 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
246
Forks
24
PR merge metrics
No merged PRs in 30d

Description

2022-03-15 15:37:57.573 | INFO | main::157 - Create soft link to /data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x
2022-03-15 15:37:57.607 | ERROR | cvpods.engine.launch:launch:64 - An error has been caught in function 'launch', process 'MainProcess' (15181), thread 'MainThread' (140337650262208):
Traceback (most recent call last):

File "/icislab/volume1/wjm/cvpods/tools/train_net.py", line 165, in
args=(args, config, build_model),
│ │ └ <function build_model at 0x7fa13a3dd290>
│ └ ╒═════════════════╤═════════════════════════════════════════════════════════════════════════════════════════════════╕
│ │ confi...
└ Namespace(clearml=False, dir=None, dist_url='tcp://127.0.0.1:50206', eval_only=False, machine_rank=0, num_gpus=1, num_machine...

File "/icislab/volume1/wjm/cvpods/cvpods/engine/launch.py", line 64, in launch
main_func(*args)
│ └ (Namespace(clearml=False, dir=None, dist_url='tcp://127.0.0.1:50206', eval_only=False, machine_rank=0, num_gpus=1, num_machin...
└ <function main at 0x7fa2e67a73b0>

File "/icislab/volume1/wjm/cvpods/tools/train_net.py", line 82, in main
cfg = default_setup(config, args)
│ │ └ Namespace(clearml=False, dir=None, dist_url='tcp://127.0.0.1:50206', eval_only=False, machine_rank=0, num_gpus=1, num_machine...
│ └ ╒═════════════════╤═════════════════════════════════════════════════════════════════════════════════════════════════╕
│ │ confi...
└ <function default_setup at 0x7fa13a3d05f0>

File "/icislab/volume1/wjm/cvpods/cvpods/engine/setup.py", line 131, in default_setup
ensure_dir(output_dir)
│ └ '/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x'
└ <function ensure_dir at 0x7fa1577545f0>

File "/icislab/volume1/wjm/cvpods/cvpods/utils/file/file_io.py", line 22, in ensure_dir
megfile.smart_makedirs(path, exist_ok=True)
│ │ └ '/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x'
│ └ <function smart_makedirs at 0x7fa157752c20>
└ <module 'megfile' from '/home/weijinmeng/.local/lib/python3.7/site-packages/megfile/init.py'>

File "/home/weijinmeng/.local/lib/python3.7/site-packages/megfile/smart.py", line 443, in smart_makedirs
SmartPath(path).makedirs(exist_ok)
│ │ └ True
│ └ '/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x'
└ <class 'megfile.smart_path.SmartPath'>
File "/home/weijinmeng/.local/lib/python3.7/site-packages/megfile/pathlike.py", line 245, in makedirs
self.mkdir(exist_ok=exist_ok)
│ │ └ True
│ └ <function _bind_function..smart_method at 0x7fa157cd3320>
└ SmartPath('/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x')
File "/home/weijinmeng/.local/lib/python3.7/site-packages/megfile/smart_path.py", line 14, in smart_method
return getattr(self.pathlike, name)(*args, **kwargs)
│ │ │ │ └ {'exist_ok': True}
│ │ │ └ ()
│ │ └ 'makedirs'
│ └ FSPath('/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x')
└ SmartPath('/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x')
File "/home/weijinmeng/.local/lib/python3.7/site-packages/megfile/pathlike.py", line 245, in makedirs
self.mkdir(exist_ok=exist_ok)
│ │ └ True
│ └ <function fs_makedirs at 0x7fa157c58710>
└ FSPath('/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x')
File "/home/weijinmeng/.local/lib/python3.7/site-packages/megfile/fs_path.py", line 18, in fs_method
return getattr(fs, name)(self.path_without_protocol, *args, **kwargs)
│ │ │ │ │ └ {'exist_ok': True}
│ │ │ │ └ ()
│ │ │ └ '/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x'
│ │ └ FSPath('/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x')
│ └ 'fs_makedirs'
└ <module 'megfile.fs' from '/home/weijinmeng/.local/lib/python3.7/site-packages/megfile/fs.py'>
File "/home/weijinmeng/.local/lib/python3.7/site-packages/megfile/fs.py", line 228, in fs_makedirs
return os.makedirs(path, exist_ok=exist_ok)
│ │ │ └ True
│ │ └ '/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos/fcos.res50.fpn.coco.800size.1x'
│ └ <function makedirs at 0x7fa2e7b76ef0>
└ <module 'os' from '/icislab/volume1/wjm/Anaconda/envs/open-mmlab/lib/python3.7/os.py'>
File "/icislab/volume1/wjm/Anaconda/envs/open-mmlab/lib/python3.7/os.py", line 213, in makedirs
makedirs(head, exist_ok=exist_ok)
│ │ └ True
│ └ '/data/Outputs/model_logs/cvpods_playground/detection/coco/fcos'
└ <function makedirs at 0x7fa2e7b76ef0>
File "/icislab/volume1/wjm/Anaconda/envs/open-mmlab/lib/python3.7/os.py", line 213, in makedirs
makedirs(head, exist_ok=exist_ok)
│ │ └ True
│ └ '/data/Outputs/model_logs/cvpods_playground/detection/coco'
└ <function makedirs at 0x7fa2e7b76ef0>
File "/icislab/volume1/wjm/Anaconda/envs/open-mmlab/lib/python3.7/os.py", line 213, in makedirs
makedirs(head, exist_ok=exist_ok)
│ │ └ True
│ └ '/data/Outputs/model_logs/cvpods_playground/detection'
└ <function makedirs at 0x7fa2e7b76ef0>
[Previous line repeated 4 more times]
File "/icislab/volume1/wjm/Anaconda/envs/open-mmlab/lib/python3.7/os.py", line 223, in makedirs
mkdir(name, mode)
│ │ └ 511
│ └ '/data'

PermissionError: [Errno 13] Permission denied: '/data'

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at tools/train_net.py:82 and cvpods/engine/setup.py:131, where default_setup calls ensure_dir for the /data output path; inspect how that output path is selected. Reproduce the training command and verify that a writable output directory can be created without PermissionError.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
machine-learning
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.