((37.6401044 55.7431905, 37.6404904 55.7433074, 37.6405864 55.7432069, 37.6402004 55.74309, 37.6401044 55.7431905))), Value(SRID=4326;POLYGON ((37.6401044 55.7431905, 37.6404904 55.7433074, 37.6405864 55.7432069, 37.6402004 55.74309, 37.6401044 55.7431905))))
                  
                  
                  
                  
                  
                  GEOSGeometry() и wkt с shapely.wkt.loads не помогают
                  
                  
                  
                  
                  
                  а еще лучше, как сразу площадь получить?
                  
                  
                  
                  
                  
                  Area(Intersection(Value(SRID=4326;POLYGON ((41.3753944 52.7650383, 41.3754433 52.7650608, 41.375535 52.7649878, 41.3754861 52.7649653, 41.3753944 52.7650383))), Value(SRID=4326;POLYGON ((41.3753944 52.7650383, 41.3754433 52.7650608, 41.375535 52.7649878, 41.3754861 52.7649653, 41.3753944 52.7650383)))))
                  
                  
                  
                  
                  
                  код
                  
                  
                  from django.contrib.gis.db.models.functions import Intersection, Area
                  
                  
                  intersection = Intersection(qs.first().geom, ext_building['way'])
                  
                  
                  print(intersection)
                  
                  
                  area = Area(intersection)
                  
                  
                  print(area)
                  
                  
                
кому интересно, решил так: intersect_area = qs.first().geom & ext_building['way'] intersect_area = intersect_area.area
Обсуждают сегодня