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

CUDA out of memory when updating masks #23

Open
Dexter1066 opened this issue Jun 13, 2024 · 3 comments
Open

CUDA out of memory when updating masks #23

Dexter1066 opened this issue Jun 13, 2024 · 3 comments

Comments

@Dexter1066
Copy link

Hello, I get CUDA out of memory error during mask updating stages when I was training with my own dataset.

This error always occurs when first executing update_gt_mask function, in train.py, line 129, pred = net.forward(img). Before that, the training process is normal.

I am using RTX 4090 and all configurations are the same with the default ones.

Could the problem arise from my dataset and how can I avoid this problem?

Thank you!

@XinyiYing
Copy link
Owner

The error of "CUDA out of memory" exists when input images are in large size.
If the error is caused by the above reason, we suggest cutting, processing and splicing large images as a solution.

@Dexter1066
Copy link
Author

The error of "CUDA out of memory" exists when input images are in large size. If the error is caused by the above reason, we suggest cutting, processing and splicing large images as a solution.

I notice in Update_mask dataset, no crop operation is carried. Would it be helpful to crop images and masks as TrainSetLoader does?

@XinyiYing
Copy link
Owner

XinyiYing commented Jul 2, 2024

You can refer to lines 57-70 of inference.py.

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

2 participants