Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RuntimeError: No shared folder available #9

Closed
qumengxue opened this issue May 25, 2021 · 5 comments
Closed

RuntimeError: No shared folder available #9

qumengxue opened this issue May 25, 2021 · 5 comments

Comments

@qumengxue
Copy link

When I run python run_with_submitit.py --dataset_config configs/refcoco.json --batch_size 4 --load https://zenodo.org/record/4721981/files/pretrained_resnet101_checkpoint.pth?download=1 --ngpus 1 --nodes 2 --ema --text_encoder_lr 1e-5 --lr 5e-5, the following error occurred:
Traceback (most recent call last):
File "run_with_submitit.py", line 171, in
main()
File "run_with_submitit.py", line 130, in main
args.job_dir = get_shared_folder(args) / "%j"
File "run_with_submitit.py", line 41, in get_shared_folder
raise RuntimeError("No shared folder available")
RuntimeError: No shared folder available

How to deal with it?

@toku-n
Copy link

toku-n commented Jul 13, 2021

Hi @qumengxue,
How did you solved this problem?
It would be helpful if you share your solution.

@qumengxue
Copy link
Author

Hi @qumengxue,
How did you solved this problem?
It would be helpful if you share your solution.

The "coco_path" in the .json file in ./config folder need to be modified to the correct path. It seems to be the only change I do for solving this problem.

@alcinos
Copy link
Collaborator

alcinos commented Jul 13, 2021

@toku-n you'll likely need to also adapt the default experimental path to something that works on your cluster.
See

if Path("/checkpoint/").is_dir():
p = Path(f"/checkpoint/{user}/experiments")
p.mkdir(exist_ok=True)
return p
raise RuntimeError("No shared folder available")

This will fail if /checkpoint/{user}/experiments is not a writable path. Just change to where you want to save the experiments.

@toku-n
Copy link

toku-n commented Jul 15, 2021

Hi @qumengxue @alcinos
Thank you for your comment! The problem is solved.

@TopCoder2K
Copy link

TopCoder2K commented Sep 17, 2021

@alcinos, thank you for your answer, but when I changed it into this:

user = os.getenv("USER")

if Path("/home/my_username/MDETR/mdetr/checkpoint/").is_dir():
    p = Path(f"/home/my_username/MDETR/mdetr/checkpoint/{user}/experiments")
    p.mkdir(exist_ok=True)

I got the following error:

Traceback (most recent call last):
  File "run_with_submitit.py", line 171, in <module>
    main()
  File "run_with_submitit.py", line 130, in main
    args.job_dir = get_shared_folder(args) / "%j"
  File "run_with_submitit.py", line 39, in get_shared_folder
    p.mkdir(exist_ok=True)
  File "/home/pchelintsev/anaconda3/envs/mdetr_env/lib/python3.8/pathlib.py", line 1288, in mkdir
    self._accessor.mkdir(self, mode)
FileNotFoundError: [Errno 2] No such file or directory: '/home/my_username/MDETR/mdetr/checkpoint/my_username/experiments'

Only creating this directory solved the problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants