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

Few Questions regarding training on custom data #40

Closed
rono221 opened this issue Mar 26, 2023 · 3 comments
Closed

Few Questions regarding training on custom data #40

rono221 opened this issue Mar 26, 2023 · 3 comments
Labels
question Further information is requested

Comments

@rono221
Copy link

rono221 commented Mar 26, 2023

Hi, I am trying to train OneFormer on the custom dataset and I was able to start the training. But, I have a few questions regarding choosing the right settings. Currently I resued ADE20k config file after editing the number of classes, iterations, and batch size.

  1. What does DETECTIONS_PER_IMAGE do and how to choose the right value?
  2. How to choose the right crop size? and will it impact the training or prediction time?
  3. I have 20k labeled images and I am training on 4 NVIDIA A100 40GB GPUs with batch size 4, what is the minimum number of iterations required to get good results?
@rono221
Copy link
Author

rono221 commented Mar 29, 2023

@praeclarumjj3 could you please help

@praeclarumjj3
Copy link
Member

Hi @rono221, thanks for your interest in our work. To answer your questions:

  1. DETECTIONS_PER_IMAGE is the top k queries considered from the total number of queries during the inference stage for the final instance segmentation predictions. Usually, it's fine to set it equal to NUM_QUERIES.

    "test_topk_per_image": cfg.TEST.DETECTIONS_PER_IMAGE,

    scores_per_image, topk_indices = scores.flatten(0, 1).topk(self.test_topk_per_image, sorted=False)

  2. The right crop size depends on your use case. If, during the inference, you want to input high-resolution or low-resolution images, it's beneficial to train with a comparable resolution. The crop size is only used during training, so training with a larger resolution will take more time.

  3. It depends on the number of classes in your dataset as well, but since the size is similar to ADE20K, I would recommend training for 160k iterations to establish a baseline.

@praeclarumjj3 praeclarumjj3 added the question Further information is requested label Mar 30, 2023
@praeclarumjj3
Copy link
Member

Closing this, feel free to re-open.

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

No branches or pull requests

2 participants