[Dachs-support] Spherepoly line segment overlap
Sebastian Walter
sebastian.walter at fu-berlin.de
Thu Jan 4 15:59:06 CET 2018
Hi Markus,
On 01/04/2018 10:35 AM, Markus Demleitner wrote:
[...]
> <code>
> # assuming data comes in as [(long, lat), ...] in degrees in "poly"
> # change as necessary.
> points = @poly
> dali_poly = [points[0][0], points[1][1]]
> for p in points[1:]:
> if getGCDist((dali_poly[-1][0], dali_poly[-1][1]), p)>min_dist:
> dali_poly.extend(p)
> @s_region = pgsphere.SPoly.fromDALI(newpoints)
> </code>
> </apply>
Thanks for the thorough explanation and the python example, which I'm
able to adapt. How do I get the footprints from the CSV (as a python
list) into the @poly variable? Do I have to create a rowmaker variable?
The message of gavo imp is always:
simplify_polygon: While executing simplify_polygon in None: string
index out of range
The other option for me would be to include your python code in my
export script from the PostGIS database, but I would rather complete
this thread and keep it in q.rd.
Thanks for any help!
Sebastian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5427 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.g-vo.org/pipermail/dachs-support/attachments/20180104/16fb7bcc/attachment-0002.bin>
More information about the Dachs-support
mailing list