Skip to content

_optimize_orientation_by_area_orient bug for some Polygons #32

@deppen8

Description

@deppen8

_optimize_orientation_by_area_orient fails when you pass the following

area_shape = Polygon([(-1000.0, -500.0), (1000.0, -500.0), (1000.0, 500.0), (-1000.0, 500.0)])
a_rectangular_area = prospect.Area(name="test_area", shape=area_shape)
coverage = prospect.Coverage.from_transects(
        name="test_Coverage_from_transects",
        area=a_rectangular_area,
        optimize_orient_by="area_orient",
        orient_axis="short"
    )

The code that determines the point coordinates is off. Need to redraw the geometry to clarify how to fix. May only be a problem for shapes where the min bounding rectangle is already aligned on the axis of interest.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions