Skip to content

Broken extended_metrics attribute #64

@matteomrz

Description

@matteomrz

Describe the bug
When trying to access COCOEval_faster.extended_metrics I get the following Error:
TypeError: only 0-dimensional arrays can be converted to Python scalars
the error occurs in: faster_coco_eval/core/faster_eval_api.py:238

To Reproduce

  1. Create any COCOEval_faster
  2. Run evaluate(), accumulate() and summarize()
  3. Try accessing COCOEval_faster.extended_metrics

Expected behavior
The extended metrics should be displayed without any Errors

Additional context
To fix this you should consider replacing the int cast with a call to the item() function.
faster_coco_eval version: 1.7.0
numpy version: 2.4.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions