Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design.

learn more… | top users | synonyms

0
votes
0answers
9 views

Getting “Points of LinearRing do not form a closed linestring”

I downloaded the data provided here as KML, exported to ESRI Shapefile format, checked it on QGIS and everything looked fine. Upon trying to use the layermapping utility of Geodjango I am getting ...
0
votes
1answer
34 views

Geodjango read raster files

I am developing a web app in geodjango (django) framework but I need to import raster files. Is it possible a geodjango app read raster files from a directory? Thanks
0
votes
3answers
345 views

OpenLayers + GeoJSON from a django server does not display features

I'm having trouble with the vector layer for my little project, here's the snippet of the javascript block var map; function init(){ map = new OpenLayers.Map('map', { ...
0
votes
1answer
101 views

Geodjango: Using Lat / Lon to Buffer from Point

I want to have a radius based distance search. To do this, I want to create a buffer around a point object so that I can filter objects that are inside this buffer, a method that I learned based on a ...
1
vote
2answers
264 views

Polygon intersection with bounding box with polygon's holes intact

I am trying to serve GeoJSON FeatureCollection tiles with each feature's geometries trimmed to the tile boundary. I am working on a Leaflet plugin to re-assemble the geometries. It works by building ...
3
votes
1answer
175 views

How to configure tilecache on nginx

I am running a geodjango application with mapnik and tilecache. Currently tilecache is run on another server to decrease the load on the application server. The application server has nginx as the ...
0
votes
1answer
85 views

Error on rendering linestring

I am using Mapnik 2.0.1rc0 on a Windows 7 with python 2.7 32bits inside a GeoDjango App using xml. The datasource come from spatialite 4.0. My tiling script can render polygon and point features ...
1
vote
1answer
30 views

GeoDjango Scale/Layers issue?

I've been having issues visualising data from a shapefile in GeoDjango using OpenStreetMaps. I believe it's some sort of a scale issue because of how it appears(as you can see in the screenshot of the ...
2
votes
1answer
100 views

SpatialRefSys as foreign key

Using the working stuff reported here, I've written the following django model: from django.contrib.gis.models import SpatialRefSys class LandCover(models.Model): shp_name = ...
0
votes
0answers
34 views

Adding GIS feature into an existing postgis table using django 1.6

i am using Django 1.6 on my web map. the problem i got is that i cannot import shapefile with features about 200. . the console has given me this traceback. . Saved: 162-05-0001-005-31 Saved: ...
0
votes
1answer
19 views

geodjango + OL bbox strategy

I managed to learn the fundamentals of Django, GeoDjango and know OpenLayers for a while. Now I realize a project with a lot of objects with point geometries. To make the user map fast and responsive, ...
2
votes
1answer
56 views

Cache geodjango query with bounding box filter

Im using geodjango (postgis) to retrieve points contained inside a bounding box (made by leafletjs), it works so nice, but now I want to cache this query. A tipical query is one like this: ...
1
vote
0answers
37 views

django---error in displaying data and displaying it on the map

. i am trying to display a feature queried from postgis. . i also designed a user input field to enter the id of the desired feature to be displayed. . i have already queried the attributes first ...
2
votes
1answer
95 views

Transform projection from EPSG:4326 into EPSG:900913

. i've got this problem about projection. .i just wanted to know what am i missing. . i already displayed map base layer using openlayers through base_layer = new OpenLayers.Layer.WMS( "OpenLayers ...
0
votes
1answer
59 views

overlay my shapefiles stored in database to the web/browser [duplicate]

I am very much strrugling on how to display my shapefiles stored in postgis database to the browser or to the web.. is there anyone there knows how to do it.? I am using geodjango framework in ...
2
votes
0answers
55 views

GeoDjango and Spatial Indexes

I have three questions about spatial indexes management in GeoDjango, and I cant find the answers in the doc. First, I know GeoDjango creates a spatial_index for a geometry field by default when a ...
0
votes
2answers
61 views

Geodjango render_to_kml Multipolygons - Can be fast or faster as WMS?

I am learning now geodjango. I made basic web app with postgis database. With openlayers iam displaying basic wms map and I want to add other layers from my postgis database. I use render_to_kml ...
0
votes
1answer
61 views

retrieving polygon shapes from postgis in geodjango

Can anyone explain how to extract polygon shapes that are stored in a PostGIS database and display it in the browser? I am using geodjango framework in python. I would like a step by step guide on ...
1
vote
1answer
62 views

Retrieving polygon shapes from postgis database and display it to the browser

I have a codes that will convert polygon shapes that is stored in the database into kml format and count all the rows in it and display it to the browser. models.py #my model in creating fields in my ...
3
votes
2answers
91 views

Distance between Paris and San Francisco with PostGis (out of range coordinates?)

SELECT ST_Distance(gg1, gg2) As spheroid_dist, ST_Distance(gg1, gg2, false) As sphere_dist FROM (SELECT ST_GeographyFromText('SRID=4326;POINT(37 -122)') As gg1, ...
0
votes
3answers
652 views

OpenLayers dynamic map width inside Bootstrap tabs

I have the following layout, produced with Django and Bootsrap frameworks: some tabs with inside each one of them other 3 sub-tabs. In every first sub-tab I have an OpenLayers-2.13 map. This is what ...
0
votes
0answers
93 views

Progress-bar not appearing on Leaflet-MarkerCluster

I am having problems with the progress-bar of leaflet markercluster. I am using it in a geodjango application which uses the django-leaflet app to handle the leaflet requirements. Everything works but ...
2
votes
1answer
74 views

GeoDjango: read geometry column in geography field

I have a Django application that needs to work with an existent PostGIS database, apart from its own database. I've configured multidatabase support, created a database router, created models for the ...
2
votes
1answer
102 views

GeoDjango - return SRID of geometry in GeoQuerySet

I'm wondering if there is a function in GeoDjango which would allow me to determine the SRID of a geometry column in a GeoQuerySet. I know I could do it with a raw SQL query (I'm using PostGIS) but I ...
1
vote
1answer
50 views

Hot could I generate a CRS field inside the GeoJSON object created by Leaflet layer.toGeoJSON?

I'm using Leaflet to transform some drawn polygons to GeoJSON and send them to a backend. But the GeoJSON objects generated by layer.toGeoJSON are like this: { "type":"Feature", "properties":{}, ...
0
votes
0answers
24 views

mapnik and django urlconf error

I follow this http://www.dbsgeo.com/talks/wa_urisa_springmeyer_mapnik_django.pdf tutorial and get error: The included urlconf <django_databrowse.sites.DatabrowseSite object at 0x30ccd90> ...
1
vote
0answers
27 views

Most efficient way of passing values from OGRGeometry to ModelField in geodjango

I am writing a custom parser that maps shapefile data to a geodjango model in a Django 1.6 project. To read the shapefile I use the DataSource object from django.contrib.gis.gdal, which provides ...
3
votes
2answers
116 views

Unit testing with postgis 1.5 and django

I'm trying to get some unit tests working in Django/PostGis. When the test database is formed, it doesn't have the postgis and postgis_topology extensions installed. Is there a way to issue commands ...
0
votes
0answers
25 views

Exclude any geometry contained within another in geodjango queryset

I am trying to get a set of non-intersecting model objects my a GeoDjango project. I have a model with a polygon geometry field, and it represents a collection of buffers. The model definition is as ...
3
votes
2answers
470 views

PostGIS + pgRouting: Adding dummy links to a road network and performing routing analysis

I'm a beginner when it comes to postgis and pgrouting development. For a project I'm working on and a bit of the algorithm: I have a polygon layer that represents zones I have a line layer that ...
2
votes
3answers
108 views

How should I implement a many-to-many relationship in a web mapping application?

Scenario: I am given a layer of point locations called "problems." These will be displayed on a web map. Users will then use the web map interface to create and populate field information for a point ...
4
votes
1answer
566 views

Wrap GEOS functionality into python

I've been looking on how to get GEOSExtractLine available in python. I looked into Shapely source to if it was available for it, but it's not. I'm trying to wrap this funcionality into Django, much ...
4
votes
1answer
2k views

Why is my PostGIS query not using a spatial index?

I am having an issue with a spatial query that is not making use of indexes. My schema is: CREATE TABLE geoplanet_place ( woeid integer NOT NULL, "name" character varying(300) NOT NULL, ...
1
vote
0answers
88 views

GeoDjango with MongoDB

Has anyone had experience successfully deploying GeoDjango with MongoDB? Is it possible? If so, how is it as simple as as installing the non-relational fork of Django and setting MongoDB as the ...
1
vote
1answer
87 views

Load partial shapefile into Postgis / GeoDjango project

I have a shapefile with Canadian postal codes, but am only looking to load a small subset of the data. I can load the entire data file and use SQL or Django queries to prune the data, but the load ...
7
votes
3answers
896 views

Use Esri Geoservices REST as backend for Python web framework (Django?)

I would like to know if it's feasible to use an existing Python web framework such as Django/GeoDjango as a frontend to work with Esri's Geoservices REST API? I envision developing a database engine ...
1
vote
1answer
150 views

GeoDjango / PostGIS - Cut geometry by bounding box

I am looking for a solution to retrieve the geometry(ies) from a polygon/multipolygon within a bounding box in a GeoDjango application. The application I am developing has a requirement to serve out ...
0
votes
0answers
45 views

OpenStreetMap layer in OSMGeoAdmin reverse coordinates

In my django application I have a map displayed when I'm in the admin thanks to the class OSMGeoAdmin (from django.contrib.gis.admin) the only problem is that this map kind of reverse the GPS ...
1
vote
1answer
99 views

How do I use polygon centroids within a GeoQuerySet?

I have two models: neighbourhoods and boroughs, each containing a polygon field. I am trying to construct a QuerySet that will give me the neighbourhoods within a given borough. I expected to use ...
1
vote
0answers
23 views

Mapserver mapscript map inset

What is the recommended way to produce a map similar to the one in http://www.nexusenergy.com.au/6468050/nexus-energy-oil-gas-exploration-and-productio.htm I would like to dynamically create the ...
9
votes
4answers
400 views

How to use PostGIS to handle complex geoprocessing workflows?

Our organization is considering moving our geoprocessing workflow to PostGIS. We are currently using ArcGIS, with a plethora of custom Python tools used in ModelBuilder. We're moving most of our data ...
4
votes
2answers
223 views

Shapefile postgis database to be queried by GeoDjango

I would like to create a Postgres database (postgreslq-9.1 and postgis-2.0.2) storing several shapefiles but I am uncertain on how to implement it so I'm searching for some advices. I have already ...
0
votes
1answer
141 views

Geodjango InspectDB Fails on Postgis Raster_Columns View

I am trying to generate models for an existing Postgresql database using the Django InspectDB command. Models are produced but a failure occurs on the raster_columns view. The error is: Exception: ...
3
votes
0answers
149 views

Is there a Python WMS client (thin client analogue of OpenLayers)?

I'm making a geoportal based on (Geo)Django 1.5, PostgreSQL 9.1 + PostGIS 2.0, QGIS MapServer and OpenStreet Map or Google Maps WMS services for the base layer. It seems like there is no problem, but ...
0
votes
0answers
40 views

Grouping records by location

I want to group points together on the basis of their proximity to one another, within a certain range of proximity. I think that a good way to do this would be to parse the geometry to a new field ...
1
vote
2answers
826 views

DatabaseError: Coordinate values are out of range [-180 -90, 180 90] for GEOGRAHY type

I am using Django 1.3, PostGIS 2.0 , Postgresql 9.0 and GeoDjango. I had a database with a table for places. This table had latitude and longitude for places in the US. I enabled this database with ...
3
votes
1answer
78 views

Should states/provinces be stored as geographic or geometric data types?

While reading the GeoDjango documentation, they advise using geometric rather than the geographic data type when storing values that are on a continental scale. The Canadian province of Ontario, for ...
5
votes
1answer
72 views

What are lazy geometries

What are "Lazy Geometries"? How are they different from other types of geometries? I'm an experienced Python/Django developer but am very new to the world of GIS, and understand that this is a ...
0
votes
1answer
80 views

Anyone recognize this (reference-system related?) pattern of distortion?

I'm new to GIS and was making some progress until getting rather stumped on this one. I've imported what I believe to be lat/lon data based on US FIPS county codes in weather alerts (NOAA SPC). When ...
1
vote
1answer
138 views

GeoDjango - How to secure tile map services?

I use geodjango to create and serve tiles that I usually display into OpenLayers as openLayers.Layer.TMS I am worried that anybody could grab the tms URL and plug it into their own map without asking ...