-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Add transform method to Detections class and documentation for the transform method #1779
base: develop
Are you sure you want to change the base?
Conversation
|
Hi @nahcol10 👋🏻 Thank you very much for your interest in supervision. Could you please clarify when the user would like to use the |
Hi @SkalskiP 👋🏻, thanks for your question! The transform method is particularly useful when you need to remap detection class names and update class IDs to align with a specific dataset. This can be helpful in scenarios such as: Standardizing class names: When integrating detections from multiple sources, you can ensure consistency by mapping different class names to a unified set. Renaming classes: For example, mapping "dog" → "animal" or "eagle" → "bird" based on a predefined mapping. Filtering detections: Ensuring only valid detections (those with class names present in the dataset) are retained, improving consistency and reducing noise. |
@nahcol10, are you trying to address #1778? @SkalskiP Such a method may ease the process of benchmarking VLMs on Roboflow datasets because:
|
Yes, this method is intended to address #1778 by ensuring VLM predictions have appropriate class_id assignments, filtering out irrelevant predictions, and allowing for class modifications using class_mapping |
Add transform method to Detections class and documentation for the transform method
transform
method to theDetections
class to support remapping class names, filtering predictions, and remapping class IDs to match a dataset's classes.transform
method indocs/detections.md
, including a description, parameters, returns, raises, and an example usage.