I've tried this without success in Indigo. It runs on my local machine and runs on PyCharm on the server
- Code: Select all
#!/usr/bin/env python3.8
from shapely.geometry import Point, Polygon
coords = [
(39.008234937234256, -77.37684452531161),
(39.00809324520176, -77.37627518191934),
(39.00733602026089, -77.37671994280922),
(39.0076547326009, -77.37724949835487)
]
homeFence = Polygon(coords)
lat = 39.00777
long = -77.37668600000001
bmw = Point(lat, long)
if bmw.within(homeFence):
#update indigo variable with True
print(True)
else:
print(False)