Skip to content

Augmentor error on rotate #21

@smdabdoub

Description

@smdabdoub

The rotate step of the pipeline throws an error on the image "Ring_Billed_Gull_0100_52779.jpg"

  File "lib/python3.9/site-packages/Augmentor/Operations.py", line 843, in do
     image = image.crop((int(round(E)), int(round(A)), int(round(X - E)), int(round(Y - A))))
  File "lib/python3.9/site-packages/PIL/Image.py", line 1206, in crop
     raise ValueError("Coordinate 'lower' is less than 'upper'")
ValueError: Coordinate 'lower' is less than 'upper'

Replacing the call to rotate on line 23 with rotate_without_crop fixes the problem:

p.rotate_without_crop(probability=1, max_left_rotation=15, max_right_rotation=15)

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