[GEOS] #985: Replace sort to min_element in SubgraphDepthLocater::getDepth

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

[GEOS] #985: Replace sort to min_element in SubgraphDepthLocater::getDepth

geos-2
#985: Replace sort to min_element in SubgraphDepthLocater::getDepth
------------------------+----------------------------------
 Reporter:  dkvash      |      Owner:  geos-devel@…
     Type:  patch       |     Status:  new
 Priority:  major       |  Milestone:
Component:  Default     |    Version:  master
 Severity:  Unassigned  |   Keywords:  SubgraphDepthLocater
------------------------+----------------------------------
 SubgraphDepthLocater::getDepth uses heavy std::sort to find minimum
 DepthSegment, this patch replaces sort to a more appropriate
 std::min_element.

 Origin implementation also relies on a Collections.min instead of heavy
 sort.
 https://github.com/locationtech/jts/blob/jts-1.16.1/modules/core/src/main/java/org/locationtech/jts/operation/buffer/SubgraphDepthLocater.java#L53

--
Ticket URL: <https://trac.osgeo.org/geos/ticket/985>
GEOS <http://trac.osgeo.org/geos>
GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS).

_______________________________________________
geos-devel mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/geos-devel
Reply | Threaded
Open this post in threaded view
|

Re: [GEOS] #985: Replace sort to min_element in SubgraphDepthLocater::getDepth

geos-2
#985: Replace sort to min_element in SubgraphDepthLocater::getDepth
----------------------------------+---------------------------
 Reporter:  dkvash                |       Owner:  geos-devel@…
     Type:  patch                 |      Status:  new
 Priority:  major                 |   Milestone:
Component:  Default               |     Version:  master
 Severity:  Unassigned            |  Resolution:
 Keywords:  SubgraphDepthLocater  |
----------------------------------+---------------------------
Changes (by dkvash):

 * Attachment "Substitute_std__sort_to_std__min_element.patch" added.


--
Ticket URL: <https://trac.osgeo.org/geos/ticket/985>
GEOS <http://trac.osgeo.org/geos>
GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS).

_______________________________________________
geos-devel mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/geos-devel
Reply | Threaded
Open this post in threaded view
|

Re: [GEOS] #985: Replace sort to min_element in SubgraphDepthLocater::getDepth

geos-2
In reply to this post by geos-2
#985: Replace sort to min_element in SubgraphDepthLocater::getDepth
----------------------------------+---------------------------
 Reporter:  dkvash                |       Owner:  geos-devel@…
     Type:  patch                 |      Status:  new
 Priority:  trivial               |   Milestone:
Component:  Default               |     Version:  master
 Severity:  Idea                  |  Resolution:
 Keywords:  SubgraphDepthLocater  |
----------------------------------+---------------------------
Changes (by dkvash):

 * priority:  major => trivial
 * severity:  Unassigned => Idea


--
Ticket URL: <https://trac.osgeo.org/geos/ticket/985#comment:1>
GEOS <http://trac.osgeo.org/geos>
GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS).

_______________________________________________
geos-devel mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/geos-devel
Reply | Threaded
Open this post in threaded view
|

Re: [GEOS] #985: Replace sort to min_element in SubgraphDepthLocater::getDepth

geos-2
In reply to this post by geos-2
#985: Replace sort to min_element in SubgraphDepthLocater::getDepth
----------------------------------+----------------------
 Reporter:  dkvash                |       Owner:  dbaston
     Type:  patch                 |      Status:  new
 Priority:  trivial               |   Milestone:
Component:  Default               |     Version:  master
 Severity:  Idea                  |  Resolution:
 Keywords:  SubgraphDepthLocater  |
----------------------------------+----------------------
Changes (by dbaston):

 * owner:  geos-devel@… => dbaston


--
Ticket URL: <https://trac.osgeo.org/geos/ticket/985#comment:2>
GEOS <http://trac.osgeo.org/geos>
GEOS (Geometry Engine - Open Source) is a C++ port of the Java Topology Suite (JTS).

_______________________________________________
geos-devel mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/geos-devel