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

Could you please give us some explanation on how to run inference with trained model? #5

Open
Ali-Tohidifar opened this issue Oct 21, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@Ali-Tohidifar
Copy link

I’ve developed a custom inference script to run predictions using BoundaryFormer. The training completed successfully, but I'm encountering errors during inference. Below is a summary of my approach and the problems I'm facing:

Inference Script Overview:

  • I am using Detectron2 v0.6 for the inference script.
  • The model and configuration are loaded using get_cfg() from Detectron2, and I run inference on custom dataset.
  • I use DefaultPredictor from Detectron2 for the inference process.

Errors Encountered:

  • Parameter Shape Mismatches:
    Multiple parameters are skipped due to shape mismatches between the model architecture and the saved checkpoint. For example:

Skip loading parameter 'proposal_generator.rpn_head.conv.weight' to the model due to incompatible shapes...
Skip loading parameter 'roi_heads.box_predictor.cls_score.weight'...

Questions:

  1. What is the recommended way to run inference using a custom-trained BoundaryFormer model with Detectron2 v0.6?
  2. Are the parameter mismatches during inference expected, or is there a way to ensure better compatibility between the model and checkpoint?

Any guidance on resolving these issues would be greatly appreciated. Thank you for your help!

@Ali-Tohidifar Ali-Tohidifar added the enhancement New feature or request label Oct 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant