Git Product home page Git Product logo

Comments (5)

lvhan028 avatar lvhan028 commented on September 7, 2024

Hi, @RunningLeon Could you please handle this issue?

from mmdeploy.

RunningLeon avatar RunningLeon commented on September 7, 2024

@tehkillerbee Hi, you could create your custom deploy_cfg file by changing keep_top_k=1000. And max_output_boxes_per_class is controlling max number of detection results for each class.
A simple way is to inherit and overwrite by creating a new deploy config file:

# in mmdeploy/configs/mmdet/detection/new_config.py 
_base_ = ['../_base_/base_tensorrt_dynamic-320x320-1344x1344.py']
# got everything from base config

# overwriting parameters you want to change
codebase_config = dict(
    post_processing=dict(
        max_output_boxes_per_class=200,
        keep_top_k=1000 # update to 1000
    ))

from mmdeploy.

tehkillerbee avatar tehkillerbee commented on September 7, 2024

@RunningLeon Ok, that is a good solution then - similar to how the mmdet configs can inherit from eachother and how values can be overwritten.

FYI, I am working on a model, where only a single class is detected, but with a high number of detections per image (eg. 1000) so this was why I set the max_output_boxes_per_class higher. Previously, I did not change keep_top_k, but I still got more than 100 results.

from mmdeploy.

RunningLeon avatar RunningLeon commented on September 7, 2024

@RunningLeon Ok, that is a good solution then - similar to how the mmdet configs can inherit from eachother and how values can be overwritten.

FYI, I am working on a model, where only a single class is detected, but with a high number of detections per image (eg. 1000) so this was why I set the max_output_boxes_per_class higher. Previously, I did not change keep_top_k, but I still got more than 100 results.
@tehkillerbee Yes, you're right.
That's because parameters are set based on original model config at first. If nothing found in original model config, then it would be set based on deploy config.
You could take a look at here

keep_top_k = cfg.get('max_per_img', post_params.keep_top_k)

from mmdeploy.

tehkillerbee avatar tehkillerbee commented on September 7, 2024

@RunningLeon Thanks for the help, that makes sense.

Closing this issue, as it is not a MMdeploy bug

from mmdeploy.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.