question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ValueError: y_max is less than or equal to y_min

See original GitHub issue

During training in MMDetection using this PR I got following error:

augmentations/bbox_utils.py", line 247, in check_bbox
    bbox=bbox,
ValueError: y_max is less than or equal to y_min for bbox [0.5390625, 0.6067708333333334, 0.541015625, 0.6067708333333334, 17].

I use only ShiftScaleRotate augmentation for bboxes:

type='ShiftScaleRotate',
        shift_limit=0.15,
        scale_limit=(0.0, 0.45),
        rotate_limit=10,
        interpolation=1,
        border_mode=0,
        p=0.5
bbox_params=dict(
            type='BboxParams',
            format='pascal_voc',
            label_fields=['gt_labels'],
            min_visibility=0.6,
            filter_lost_elements=True),

Version: 0.3.3

My original annotation of bboxes is correct. I think such ValueError can occur after ShiftScaleRotate when it modifies some of bboxes too much.

Can you please give some advice how to avoid such error?

Issue Analytics

  • State:open
  • Created 4 years ago
  • Reactions:2
  • Comments:8

github_iconTop GitHub Comments

1reaction
albucommented, Sep 17, 2019

seems like a problem is in your data format. please send us few data points (boxes for one failing image should be enough). Everything is not valid without preprocessing.

0reactions
yzbxcommented, Apr 7, 2022

try to remove bbox with width/height=0, just set min_area=1 in BboxParams view https://albumentations.ai/docs/api_reference/core/composition/#albumentations.core.composition.BboxParams for detail

Read more comments on GitHub >

github_iconTop Results From Across the Web

ValueError: x_max is less than or equal to x_min for bbox
While running albumentations for a set of bounding errors, above error comes (ValueError: x_max is less than or equal to x_min for bbox)...
Read more >
Source code for neutcurve.hillcurve
You may want to fit the fraction neutralized rather than the fraction ... that `f\left(c\right)` gets larger rather than smaller as :math:`c` increases....
Read more >
https://hyperbrowser.uio.no/eggs_repo/matplotlib/m...
lineMarkers: if marker is not None: raise ValueError( 'Illegal format string ... 2: raise ValueError("x and y can be no greater than 2-D")...
Read more >
axes.py - The yt Project
lineStyles: if linestyle is not None: raise ValueError( 'Illegal format ... 2: raise ValueError("x and y can be no greater than 2-D") if...
Read more >
https://www.psych.mcgill.ca/labs/mogillab/anaconda...
lineStyles: if linestyle is not None: raise ValueError( 'Illegal format string ... 2 or y.ndim > 2: raise ValueError("x and y can be...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found