To get FeatureInfo in OpenLayers

I am new to OpenLayers and I want to add OpenLayers.Control.WMSGetFeatureInfo to get feature   info to website.But i can't figure out right method. I also see the source code of GeoServer OpenLayers page and still I can't find the syntax of OpenLayers.Control.WMSGetFeatureInfo code? I use geoserver,apache-tomcat-6.0.35 and open layer 2.10.Should i use proxy to call OpenLayers.Control.WMSGetFeatureInfo? This is my GeoServer WMS URL:               http://localhost:8080/geoserver/sac/wms?     service=WMS&     version=1.1.0&     request=GetMap&     layers=sac:contour&     styles=&     bbox=187754.5,204980.703125,192031.40625,210022.890625&     width=434&height=512&s     rs=EPSG:5235&     format=application/openlayers      Pls give me sample code which calling OpenLayers.Control.WMSGetFeatureInfo? Thank you.


add cookies in WMS request

I need to add a cookie in each WMS request. i tried to do something like this but i don't think this is the right way.               getURL : function(bounds) {     var requestString = OpenLayers.Layer.WMS.prototype.getURL.apply(this, arguments);     window.document.cookie="referrer="+window.location.origin;     return this._encode(requestString) + "&KEY=" + this.navkey;      is it possible to do this? thanks you


Flow mapper plugin failed

I want to create a desire line with the Flow Mapper pluginwith qgis ver.2.1 . After I did it has failed. The data that I use as an attachment below. There may be error procedure I have done?. Expected clue how to do it right. Thank you for the response. ![Data](http://i.stack.imgur.com/W47rM.png)


GeoExt: Layer leaf nodes replicated across all tree nodes

This is going on with GeoExt 1.1 and OpenLayers 2.12. I need to build a layer tree dynamically, with layers and nodes that are only known at run time. The snippets I show below correctly create a layer tree with several nodes and adds the layers node leafs. The problem is that though each layer is assigned to a single tree node, it is then shown under each and every tree node created. During init the tree and its root are set up:                 treeRoot = new Ext.tree.TreeNode       ({           text        : 'Project',           id          : '0',           leaf        :false,           expandable  : true,           expanded    : true       });            layerTree = new Ext.tree.TreePanel       ({         title: 'Map Layers',         region: "west",         width: 200,         collapsible: true,         autoScroll: true,         enableDD: true,         plugins:         [{           ptype: "gx_treenodecomponent"         }],         loader:         {           applyLoader: false,           uiProviders:           {             "custom_ui": LayerNodeUI           }         },         root: treeRoot,         rootVisible: false,         lines: false       });      Later on new tree nodes can be added according to a tag, and kept in an array:               if(treeNodes[tag] == null)     {         treeNodes[tag] = new GeoExt.tree.OverlayLayerContainer         ({                 text: tag,                 leaf: false,                 expanded: true         });         treeRoot.appendChild(treeNodes[tag]);     }      Layers are added to the map and to a specific tree node:               var layer = new OpenLayers.Layer.WMS(title, serviceURL, params, options);     leftMap.addLayer(layer);     layer.events.register("visibilitychanged", this, toggleLayer);          var newNode = new GeoExt.tree.LayerNode(     {         text: title,         layer: layerName,         leaf: true,         checked: false,         children: [],         nodeType: "gx_layer"     });     treeNodes[tag].appendChild(newNode);      But then each layer appears several times, once under each tree node. Any hints on why it is happening this way are welcome. Thank you.


How to project a geoJSON file in OpenLayers?

I have a json file well formed. I want to read a json file as a base layer from OpenLayers.                   <script type="text/javascript">             var styles = new OpenLayers.StyleMap({                     "default": {                         strokeWidth: 2                     },                     "select": {                         strokeColor: "blue",                         strokeWidth: 4                     }                 });                      // add rules from the above lookup table                 styles.addUniqueValueRules("default", "RP_TYPE", {                     10: {strokeColor: "#000000", strokeWidth: 2},                     12: {strokeColor: "#222222", strokeWidth: 2},                     14: {strokeColor: "#444444", strokeWidth: 2},                     16: {strokeColor: "#666666", strokeWidth: 2},                     18: {strokeColor: "#888888", strokeWidth: 2},                     19: {strokeColor: "#666666", strokeWidth: 1}                 });                           // add rules from the above lookup table                 styles.addUniqueValueRules("default", "RP_TYPE", {                     10: {strokeColor: "#000000", strokeWidth: 2},                     12: {strokeColor: "#222222", strokeWidth: 2},                     14: {strokeColor: "#444444", strokeWidth: 2},                     16: {strokeColor: "#666666", strokeWidth: 2},                     18: {strokeColor: "#888888", strokeWidth: 2},                     19: {strokeColor: "#666666", strokeWidth: 1}                 });                      var vectors = new OpenLayers.Layer.Vector("Lines", {                     strategies: [new OpenLayers.Strategy.Fixed()],                                     protocol: new OpenLayers.Protocol.HTTP({                         url: "data/locality_region.json",                         format: new OpenLayers.Format.GeoJSON()                     }),                     styleMap: styles                 });                      map.addLayer(vectors);                 map.addControl(new OpenLayers.Control.LayerSwitcher());                 map.zoomToMaxExtent();                  }        I have another json files which are downloaded from api and those files works fine. How about my own json file that got converted from db. Do I need to work more on it. If so please guide me how to project a json on OpenLayers that created from a PostgreSQL db. How can I fix the bounds for my own map or layer; Thank you


Error on Geoserver Web Admin Page

When i click on Geoserver Web Admin Page gives Message as 'Bad Request (Invalid Hostname)' in web page. I have already data of on going project in geoserver. I have started Geoserver. My geoserver version 2.1.3. in window Xp operating System. Can any one please guide me to get out of the error and get back Geoserver web Admin Page. Please see the Page result in images below.![enter image description here](http://i.stack.imgur.com/6t8hw.png)


Get the vertices on a LineString either side of a Point

I have a shapely LineString and defined a shapely Point which lies along the LineString. How can I find the vertices of the LineString which lie either side of the point? (split the line in two). This is very similar to this blog post by the author: http://sgillies.net/blog/1040/shapely-recipes/ Except, instead of cutting by distance along the line, I want to cut given a point that lies along the line.


how display graduated symbol in the legend in print composer?

this is the problem: why the graduated symbol is not reported at all in the legend of the print composer? it is a bug or i am doing something wrong? here below the image that shows the problem ![enter image description here](http://i.stack.imgur.com/QIIGR.jpg)


Mapinfo and qgis file's datum problem

please refer to following link for the explanation of the problem I had. do you have any idea on this? http://osgeo-org.1560.x6.nabble.com/Mapinfo-and-qgis-file-s-datum-problem- td5091891.html#a5100434


QGIS 2.0 Plugin: Select and Identify a Single Feature

given is a layer with some nodes on it and every node has some attributes(name, id, etc...). For showing up the informations of a single node I can use the "Identify Feature Tool". Choose the tool, click the node and see the informations. I am trying to develop a Plugin with Python, which is doing almost the same: Start the Plugin, click on a node and get the informations about this node(output in the python console is enough for the first steps). Okay, so this is the status: I was following this tutorial: http://www.qgisworkshop.org/html/workshop/plugins_tutorial.html which works not for QGIS 2.0. The 'MouseClickEvent' is working, I get the X,Y-coordinates. But I am not able to select and to get the informations of a node. That is my selectFeature function, which is called by `result = QObject.connect(self.clickTool, SIGNAL("canvasClicked(const QgsPoint &, Qt::MouseButton)"), self.selectFeature)`:               def selectFeature(self, point, button):         #pntGeom = QgsGeometry.fromPoint(point)         #pntBuff = pntGeom.buffer( (self.canvas.mapUnitsPerPixel() * 2),0)          #rect = pntBuff.boundingBox()              layer = self.canvas.currentLayer()         selected_features = layer.selectedFeatures()         for i in selected_features:             attrs = i.attributeMap()             for (k,attr) in attrs.iteritems():                 print "%d: %s" % (k, attr.toString())      This let me see nothing. I was reading and trying out a lot of things and at the moment in feel a bit lost. I lost the overview. Do I need these geometry functions to capture the node by clicking the mouse button? What functions do I need to get the attributes of a single selected feature? Thank you :)


Cleaning up Line Features

I'm in the process of creating some routes for which I need left and right sections. I have an original streets feature class, which I used "copy parallels" on, and came up with something like the picture below. I'm wondering if there is any tool that would clean up these roads, erase some dangles and intersecting lines. I've tried using the "trim" tool, but cannot come up with a standard length to trim. Any ideas? ![Routes](http://i.stack.imgur.com/7a05c.png) Using ArcGIS 10.2.1 Advanced


Setting ArcGIS Server 10.2 Data Store Folder as Local vs. Network (UNC) path

Is there any difference? How setting ArcGIS Server Data Store Folder as local vs. network path will affect the publishing process? I saw warnings in ArcMap 10.1 when I Analyze the MXD before I publish, complaining that network path is used. (Assuming this might slow down the REST service if network access to MXD data is slow) Example: My file server has designated shared folder for ArcGIS data called "GisDataStore". It is mapped as local drive on my ArcGIS server, so I can access it both ways: \MyFileServer\GisDataStore and Z:\GisDataStore I wonder which I should use to Register the "GisDataStore" folder as ArcGIS 10.2 Server datastore. ![Local Path](http://i.stack.imgur.com/yWrCy.png) ![Network Path](http://i.stack.imgur.com/XWG8F.png) Here's the warning I am getting: SEVERITY STATUS CODE DESCRIPTION Medium Unresolved 10027 Layer's data source is referenced via a UNC path ![UNC Path Warning](http://i.stack.imgur.com/D8HaB.png)


How to generate JPEG tiles using gdal2tiles.py

I am using gdal2tiles.py to generate tiles and packing it into MBTiles using mb-util. gdal2tiles by default generates PNG tiles. When I convert PNG tiles to JPEG large black area around tiles are left (due to lack of transparency in JPEG): http://www.imagemagick.org/discourse-server/viewtopic.php?f=1&t=24048 Is there a way to directly generate JPEG tiles in gdal2tiles.py ? I am using GDAL 1.9.2 on Ubuntu 12.04.


Using the python shape library: pyshp - how to convert polygons in .csv file to .shp

I'm converting csv data to shapefiles using the pyshp python library. What I want to do is very similar to Using the python shape library: pyshp - how to convert .csv file to .shp, except that I don't know how to handle polygons. My data is in a csv file. Each row corresponds to a named rectangle, i.e. a string and the latitude or longitude coordinates of each side of the rectangle: left side (xl), right side (xr), top (yt) and bottom (yb). So my data looks like this:               name,xl,xr,yt,yb     some Name,-25.3125,22.5,47.517193,31.353634     another Name,-103.359375,-0.703125,80.87282,74.40216     ...      And my python code is pretty simple. It is only slightly modified from the points example. But when I try to import this data into google maps, it has some errors parsing it. So I think I'm doing something wrong, but I'm not sure what?               #Set up blank lists for data     name, polyPart = [],[]          #read data from csv file and store in lists     with open(in_file, 'rb') as csvfile:       r = csv.reader(csvfile, delimiter=',')       for i,row in enumerate(r):         if i > 0: #skip header                # parse data into a point array representing the bounding box           xl = float(row[1])           xr = float(row[2])           yt = float(row[3])           yb = float(row[4])           tl = [xl, yt]           tr = [xr, yt]           br = [xr, yb]             bl = [xl, yb]           parr = [tl, tr, br, bl, tl]                # array of one "part", the part is an array of points           polyPart.append([parr])           name.append(row[0])          #Set up shapefile writer and create empty fields     maxStringLength = 50     w = shp.Writer(shp.POLYGON)     w.field('name','C',maxStringLength)          #loop through the data and write the shapefile     for j, name in enumerate(name):       w.poly(parts=polyPart[j])       w.record(name)          #Save shapefile     w.save(out_file)


Attempting to use ST_DWithin to locate objects within a given distance of meters using SRID 4326

I'm a Rails developer with minimal GIS experience, working with PostGIS and the RGeo gem. I'd like to find all of the cows within 500 meters of my current location. So, I'll create a model for my cows:               class Cow < ActiveRecord::Base     set_rgeo_factory_for_column(:latlon, RGeo::Geographic.spherical_factory(:srid => 4326))        I'll then seed my database with enough cows to keep me busy:               5000.times{ Cow.new(latlon:"POINT(#{40.735767 + rand() * 0.1  } #{-77.919674 + rand() * 0.1  })" ).save }      To find the cows within 500 meters of my location, I'll use the ST_DWithin PostGIS function that all the tutorials suggest:               cows_found = Cow.find_by_sql("SELECT * FROM cows WHERE ST_DWithin(latlon, '#{search_latlon}', 500)")      The unhappy result is the following: ![enter image description here](http://i.stack.imgur.com/c3J7O.png) Moving to the East or the West, the 500 meter radius threshold appears to be observed correctly, but moving to the North or the South, I am finding cows as far as two kilometers away. Now, obviously I'm extremely naive in my approach, but I'm not completely clueless; I understand I'm populating my cows in a spheroidal projection and handing the coordinates returned from ST_DWithin to Google's Mercator. I expect distortion. However, this is larger than I anticipated and suggests to me that I've fundamentally misunderstood something. I had thought that in my use of ST_DWithin I was passing as arguments two geographies, and that distance would therefore be specified in meters. I was able to set the use_spheroid boolean argument to false without PostGIS complaining, which I do not think I should be able to do if I were in fact comparing geometries. In fact, if I use psql to look at the latlon column, it is of type geography:                latlon     | geography(Point,4326)       |      However, perusing related questions, I see several answers that state that using ST_DWithin with SRID 4326 results in the distance threshold being specified in radians. (Edit: I now understand this would only be the case if one was using 4326 geometries, not 4326 geographies.) So, given the goal of locating cows within a given number of meters, and tolerating an error of tens of meters (nobody will die if we find a few extra cows) what would be the best way to proceed? Throw out the 4326 spatial reference system, and use a different SRID? Use 4326, but calculate a conversion from meters to radians, for use with ST_DWithin? (This conversion would obviously be subject to the specific latitude and longitude from which I am searching.) Any suggestions would be appreciated. Edit: Both arguments to the ST_DWithin call are 4326 geographies. The first argument, latlon, is a 4326 geography column, and the second argument is drawn from another column of the same type. A commenter's (very perceptive) suggestion that I ensure the second argument was in fact a geography by using ST_GeogFromText led to precisely the same end result. So, I have high degree of confidence that I am using the correct version of ST_DWithin with the correct parameters. As a sanity test, I repeated exactly the same procedure (generating a dense set of latlons and performing ST_DWithin upon it) very near the equator. This is the result: ![enter image description here](http://i.stack.imgur.com/HutR0.png) As you can see, the points returned by ST_DWithin are much less distorted. More importantly, they are all within 500 meters of the central point. The results that I am able to obtain at the equator are precisely in line with my expectations. However, at roughly the 41st parallel North, I am getting the distortion observed in the first example. Now, I expect distortion from handing my 4326 coords to Google Maps (who internally transform them to their own web Mercator) and I expect some distortion from using 4326 (PostGIS In Action warns that local distance measurements will be 'bad'). I expect these distortions to become more severe as I move away from the equator. The first map example in this question is obviously subject to both of those distortions. So my question is: Is the level of distortion I am seeing in the first map example actually a correct result? (Meaning, the result one would expect given the limitations of the 4326 spheroid model and distortion from the projection to web Mercator?) If this is a correct result, I would be eager to hear suggestions regarding a PostGIS strategy to retrieve points within a given radius that was less subject to these distortions, or a strategy to ameliorate this distortion.


Function to determine font color of data driven page attribute in ArcMap 10.2

ArcGIS 10.2 I am looking for an IF/ELSE statement that I can place in the text properties of my Data Driven Page Attribute item to change the font color based on the value in that field. Here is the function I have been trying. Its a variation on a function for basic map label. I can't get this function to work w/ dynamic text. `Function FindLabel<dyn type="page" property="attribute" field="RP_Slope" domainlookup="true"/> > 2 then FindLabel = <CLR red='255'><dyn type="page" property="attribute" field="RP_Slope" domainlookup="true"/></CLR> else FindLabel = <dyn type="page" property="attribute" field="RP_Slope" domainlookup="true"/> end if End Function`


osm2po: import multiple .osm files for disparate regions?

Does osm2po support importing **multiple** OpenStreetMap files into the same Postgres/PostGIS database (i.e., to be used for routing)? If yes, can the OSM files be for geographic regions that are **not** next to each other? For example, could I import something like NewYork.osm and SanFrancisco.osm into the same routing database? Thanks!


Bing map v7 adding infobox to georss parser module

Using this plugin (source) to load pins from an xml file, pins get added correctly, but now trying to add infoboxes to each respective pin. In the function that receives the array of pins I'm trying to loop through each item and add infoboxes accordingly. Any ideas as to what I'm missing here?                     function GeoRSSImportedCallback(items, bounds) {               map.entities.push(items);                    for (var i = 0; i<items.length; i++) {                 items[i].Title = items[i].title;                 items[i].Description = items[i].description;                 Microsoft.Maps.Events.addHandler(itmes[i], 'click', displayInfoBox);               }                    map.entities.push(infoboxLayer);               map.setView({ bounds: bounds });           }              function displayInfoBox(e) {             pinInfoBox.setOptions({title: e.target.Title, description: e.target.Description, visible:true, offset: new Microsoft.Maps.Point(0,25)});             pinInfoBox.setLocation(e.target.getLocation());     }      I do initialize the following in the `GetMap()` function                       pinInfoBox = new Microsoft.Maps.Infobox(new Microsoft.Maps.Location(0, 0), { visible: false });             infoboxLayer.push(pinInfoBox);


scalebar doesn't print properly in IE or FF

I have a ruler-style scalebar in my webapp, which uses the ArcGIS JS API version 3.1. When I send the map to print using window.print(), the scalebar renders as expected in Chrome, but in both IE and Firefox, the scalebar renders as a hollow bar with no markings. From what I can tell, the scalebar=line option is not available for version 3.1 of the API, and there are other dependencies in the code that prevent me from changing the API.


Find index location of a lat/lon point on a raster grid in ArcPy

This question has been confusing me for a while, and I'd love y'all's help. I'm trying to find the index location on a raster (in terms of column and row#) of a specified lat/lon point. My first thought was to find the cell value at the lat/lon point, convert the raster to a numpy array, and find the index of the point (but that's clunky, and requires each cell value to be unique...which isn't true in the raster)               #get values, assuming the extent object is already saved     raster = "raster.shp"     x_coord = extent.XMin     y_coord = extent.YMin     point = arcpy.Point(x_coord, y_coord)     cell_val = arcpy.GetCellValue_management(raster,point,"")     raster_array = numpy.array(raster)     final_index = raster_array.index(cell_val)     print final_index      But that's ungainly, and also requires the cell values to be unique in the raster (which again isn't the case) Is there any other way to find the cell index of a pixel within a raster that corresponds to a point object? Thanks!


layer.visible command not working in arcpy.mapping module

I am using the arcpy.mapping module for the first time, and the lyr.visible command is not working as it should (or I am not using it as I should). I have a list that contains the the layer names of .img files that are loaded into a single data frame - the list is called "layernames". I am using a while loop to go though the layernames list, turn on one of the layers at a time, export a .png file with that layer visible, then turn that layer off and move on to the next layer in the list. At the beginning of each pass through the loop I specify which raster layer should be turned on by setting layernames.visible = True, and at the end of the pass through the loop I turn off that layer by setting layernames.visible = false. The first time through the loop the script works and does turn on the correct layer in the list "layernames". But for all subsequent passes through the loop, only the first layer remains visible, and none of the others are turned on or off. In other words, every .png image shows the same raster (the first one that is turned on), instead of a different raster in each .png image. I have pasted my script below. Any help would be greatly appreciated!               mxd = arcpy.mapping.MapDocument("Z:\\sharks\\Models\\Summer2013\\daily figures.mxd")     layernames = arcpy.mapping.ListLayers(mxd)     counter = 0     yr = 2005     while counter < 365:         layernames[counter].visible = True         x = str(layernames[counter])         y = x[9:12]         j = int(y)         date = datetime.datetime(yr,1, 1)+ timedelta(days=(j-1))         strDate = str(date)         if (j + 1)<= 31:             mxd.title = "January (" + strDate[0:10] + ")"         elif (j + 1) >= 32 and (j+1) <= 59:             mxd.title = "February (" + strDate[0:10] + ")"         elif (j + 1) >= 60 and (j+1) <= 90:             mxd.title = "March (" + strDate[0:10] + ")"         elif (j + 1) >= 91 and (j+1) <= 120:             mxd.title = "April (" + strDate[0:10] + ")"         elif (j + 1) >= 121 and (j+1) <= 151:             mxd.title = "May (" + strDate[0:10] + ")"         elif (j + 1) >= 152 and (j+1) <= 181:             mxd.title = "June (" + strDate[0:10] + ")"         elif (j + 1) >= 182 and (j+1) <= 212:             mxd.title = "July (" + strDate[0:10] + ")"         elif (j + 1) >= 213 and (j+1) <= 243:             mxd.title = "August (" + strDate[0:10] + ")"         elif (j + 1) >= 244 and (j+1) <= 273:             mxd.title = "September (" + strDate[0:10] + ")"         elif (j + 1) >= 274 and (j+1) <= 304:             mxd.title = "October (" + strDate[0:10] + ")"           elif (j + 1) >= 305 and (j+1) <= 334:             mxd.title = "November (" + strDate[0:10] + ")"         elif (j + 1) >= 335 and (j+1) <= 365:             mxd.title = "December (" + strDate[0:10] + ")"           mxd.save()         out_png = "Z:/sharks/Models/Summer2013/RF/ALL/SB_RF/AVpresRFP/figures/" + strDate[0:10] + ".png"         arcpy.mapping.ExportToPNG(mxd, out_png)         layernames[counter].visible = False         mxd.save()         counter +=1


Geoserver WMS v Geowebcache offset?

Having successfully used the new OpenLayers.Layer.GeoWebCache to add a local tile cache created using Geowebcache, I thought I would compare against the same data as a wms from my local GeoServer. Looking at the geowebcache.js file there is an option to specify the cache layer as a base layer, so I sent it to false and added a layer switcher to the map Both layers add to the map however there is a significant offset. ![enter image description here](http://i.stack.imgur.com/E8lIU.png) The cache layer is the one that is set to the right. In the geowebcache.js there is no mention of offset needing to be set. Any ideas on what would cause this and what I need to change? thanks ## UPDATE As requested my openlayers code               <script src="http://openlayers.org/api/OpenLayers.js"></script>     <script src="geowebcache.js" type="text/javascript"></script>     <script type="text/javascript">          var map;             function init() {                      var world = new OpenLayers.Bounds(                     0, 0, 700000, 1344000                 );                      map = new OpenLayers.Map({                     div: "map",                     projection: new OpenLayers.Projection("EPSG:27700"),                     numZoomLevels: 11,                     resolutions: [896,448,224,112,56,28,14,7,4,2,1],                     maxExtent: world,                     center: new OpenLayers.LonLat(400000, 500000),                     zoom: 11                 });                      map.addControl(new OpenLayers.Control.LayerSwitcher());                      var cache = new OpenLayers.Layer.GeoWebCache({                       url: "https://url/",                       isBaseLayer: false,                       name: "Cache Layer",                       gridSetId: "zoommap",                   });                      // Add WMS layer to our map                 map.addLayer(cache);                      var bwms = new OpenLayers.Layer.WMS( "Base Map",                   "http://localhost:8080/geoserver/wms?",                   { "transparent":"false",                     isBaseLayer: true,                     "layers":"osgb:aa_base",                     "format":"image/png" },                   { "reproject":"true" }                   );                      // Add WMS layer to our map                 map.addLayer(bwms);      Here is my GWC configuration file                 `          <?xml version="1.0" encoding="utf-8"?>         <gwcConfiguration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://geowebcache.org/schema/1.5.0 http://geowebcache.org/schema/1.5.0/geowebcache.xsd" xmlns="http://geowebcache.org/schema/1.5.0">       <version>1.5.0</version>       <backendTimeout>120</backendTimeout>       <gridSets>         <gridSet>           <name>zoommap</name>           <srs>             <number>27700</number>           </srs>           <extent>             <coords>               <double>0.0</double>               <double>0.0</double>               <double>700000.0</double>               <double>1344000.0</double>             </coords>           </extent>           <alignTopLeft>false</alignTopLeft>           <resolutions>             <double>896.0</double>             <double>448.0</double>             <double>224.0</double>             <double>112.0</double>             <double>56.0</double>             <double>28.0</double>             <double>14.0</double>             <double>7.0</double>             <double>4.0</double>             <double>2.0</double>             <double>1.0</double>           </resolutions>           <metersPerUnit>1.0</metersPerUnit>           <pixelSize>2.8E-4</pixelSize>           <scaleNames>             <string>zoommap:0</string>             <string>zoommap:1</string>             <string>zoommap:2</string>             <string>zoommap:3</string>             <string>zoommap:4</string>             <string>zoommap:5</string>             <string>zoommap:6</string>             <string>zoommap:7</string>             <string>zoommap:8</string>             <string>zoommap:9</string>             <string>zoommap:10</string>           </scaleNames>           <tileHeight>250</tileHeight>           <tileWidth>250</tileWidth>           <yCoordinateFirst>false</yCoordinateFirst>         </gridSet>       </gridSets>       <layers/>     </gwcConfiguration>      The data is stored in a PostGIS database and the projection is definitely EPSG:27700. As you can see I have defined the projection in my OpenLayers code and included the same resolutions as my geowebcache configuration resolutions.


Troubleshooting why ArcGIS Model works on one PC but not another?

Do you have specific expertise you could share of examples where an ArcGIS Modelbuilder has worked on one PC but not on another? Are there any issues between different Windows versions? There is a related question here Model not editable on a different PC In my example I have a model that runs to completion on a Windows 8 machine. I run the models from an external hard drive. When the same model is run from the same external drive but on a different PC - Windows 7 then the model crashes. The model can be opened, edited and verified on both Pc's.It just crashes on one but not the other. I have explored possible options: ArcGIS Version and service packs - both are 10.1 SP1.   RAM - the PC on which the models work has LESS RAM than the PC on which the models crash OS type - both machines are 64 BIT.   Model build - i have re-built the model by copying and pasting into new / clean models (I did this on the Windows 8 PC though) I am not sure that the cause is the different Windows version, it is just the main difference I can see between the two PC's Any expertise, answers or references to sources of information would be much appreciated. I am using ArcGIS 10.1 SP1 for Desktop Advanced.


How to export all the layers from Table of Content to shp file?

I have got lots of different layers in the Table of Content panel in ArcMap. I want to export them all in shp format in one go. How can I do that? So far I have been doing it one by one by right clicking on the layer-->data-->export as shp. and it is taking longer time. I want to do them all together.


Polygonize.py: AttributeError: 'NoneType' object has no attribute 'CreateDataSource'

**Given a topographic raster tif** of an european country where elevations are simplyfied to **either 0, either 200**. **How to create a polygon ?** * * * **Comment** : With the following polygonize.py command:               gdal_polygonize.py level200.tif -f "ESRI_Shapefile" level200.shp      I get to following error:               Creating output level200.shp of format ESRI_Shapefile.     Traceback (most recent call last):       File "/usr/bin/gdal_polygonize.py", line 164, in <module>         dst_ds = drv.CreateDataSource( dst_filename )     AttributeError: 'NoneType' object has no attribute 'CreateDataSource'


Pure JavaScript Library for Geometry Operations

Does anyone know of a pure JavaScript library for doing geometry operations such as buffer, union, intersects, etc? I want to play with doing these operations in the browser. It looks like GeoScriptJS has some dependencies.


Are there any Indoor GIS platforms?

What sort of infrastructure is needed to allow me to write a simple mobile app for indoor navigation? Professor Mike Goodchild said: > the average American only spends 13 percent of the time outdoors. GIS-based > services help us find restaurants and hotels, but they offer almost no > support for navigating in the complex indoor spaces of shopping centers, > hospitals, mines, or airports. On my smartphone, I'd like to show a floor plan oriented to the real world, centered on my location.


Pure Python Library for Geometry Operations

Does anyone know of a pure Python (no C or Java dependencies) library for doing geometry operations such as buffer, union, intersects, etc? I'm looking for something that Google AppEngine compatible. Thanks!


Topology Edit Tool in ArcGIS Engine

Is a Topology Edit Tool available "out of the box" for ArcGIS Engine 10? Or do I have to write one myself?


Renaming legend items in ArcGIS for Desktop?

Can someone please tell if it is possible to rename legend items in the map layout in ArcGIS for Desktop? If yes, how can I do it?


Customize geocoding locator styles in an ArcGIS Server environment

Using ArcGIS Desktop, it is relatively straightforward to customize locator styles by editing the corresponding CLS files. We are struggling to do the same in a server environment. We have created a locator in ArcSDE (9.3.1) for Oracle 11g and a corresponding _Geocode Service_ in ArcGIS Server (9.3.1). How do we customize locator styles in this environment?


ReClassify Vector Data Between Values

I would like to be able to take all values between 1 and 10 and have a field define them as 1, and all values between 10 and 20 and set them to 2, how do I do that with vector data? I read how to set all building to 20, and grass to 40, but I'm pretty sure that to do that for a range of values, like 1-10, I would have to manually enter each number, and decimal in that range. Am I wrong? and if not, how would I accomplish this? Thanks


Is there a way for multiple users to use an SQLite/SpatiaLite db simultaneously?

Is there a way that multiple users can use the SQLite / SpatiaLite database simultaneously? Thank you for your feedback.


How can I set the output feature type name dynamically?

How can I set the output feature type name so that it consists of a constant part and a variable part, such as "Circle_205", where the number part could be different each time? When using a fanout, this is easy to set, but without a fanout, I do not know how to do this, unfortunately.


Calculating Mean Upslope slope, curvature, etc

I'm trying to generate rasters whose values summarize the mean value of a given parameter (slope, curvature, etc.) of the upslope terrain. I feel like this should be doable using only a flow direction raster and a raster of the parameter of interest, but I don't really know where to begin. I've seen this instruction http://forums.esri.com/Thread.asp?c=93&f=995&t=303114, but I can't seem to figure out a way to interpret it that produces a result that makes any sense. I'm familiar with ArcMAP, QGIS, SAGA, and a bit of GDAL and GRASS, so I'll gladly accept instructions for any of these platforms.


geowebcache tiles not showing up in folder

I am using geoserver 2.5.1 and am atempting to use the intergrated geowebcache.I have installed tomcat and am using the webapp process for the geoserver. I managed to add all the tiles and got the jai working. when i had tested out the first time of installing geoserver and the tiling on my local host it worked in seeding the layers and creating cached tiles. The only problem is i don't exactly remember what I did and all the things that i remember what was dont i did it. I then istalled the tomcat and geoserver on our developer server so it is now using an ip address instead of a local host, but for some reason all the things i tried with the localhost does not seem to work on the developer one. I also noticed when I either add:               <context-param>             <param-name>GEOWEBCACHE_CACHE_DIR</parm-name>             <parm-value> C:\temp</param-value>         </context-param>          then it seems to make pink tiles on my map. and when I create a folder after setting up the environmental variables at the system variables in the C:\temp, when I create a folder in my C drive that matches the environmental variables cause i thought u might have to create the folder for it to work but it just seems to make my geoserver work disapear and makes it as if has installed all over again but when I delet the folder then i get my data back. Can any one help with this problem. I have looked through all the questions that vaigley match what im trying to do but to much availe im still having problems and the geoserver and geowebcache documentation is not making too much sence. When I click on the side of the geoserver under serice Capabilities when I click the WMS section it goes to a 404 page on either one of those but when I click on my localhost it work fine and gives me an xml page.


vector layer, no more editing is allowed

I have a polygon vector layer with already 529 objects but without any attributes so far and now I get the message that shapefiles without attributes are treated as write protected. What can I do to go on working with my shapefile?


How do I turn off labels that have null values? I am using a leader with this label but I want it turned off if the values are null


Possible to downgrade Postgresql and PostGIS versions and still be compatible with latest OpenGeo Suite?

I'm trying to connect ArcGIS Desktop 10.1 to PostGreSQL/PostGIS tables. I have PostGreSQL 9.2/PostGIS 2.0, which was installed with the latest OpenGeo suite. Unfortunately ArcGIS direct connections to PostGres are only supported by ESRI for version 9.1.3. Would it be possible to downgrade my version of PostGres 9.2 to 9.1.3 while maintaining the other up-to-date components of the OpenGeo Suite (i.e. geoserver, geowebcache, etc.)?


GeoServer WCS geotiff style not loading in ArcMAP

I have published a GeoTIFF file using GeoServer's (2.4.5) WCS service. I also defined a colormap style on GeoServer. I know the style works, because, when I load the map through WMS the colormap is there and the legend image is also generated. But when I try to load it into ArcMAP or QGis using WCS, I just get a stretched gray scale. Opening the same GeoTIFF file directly from the catalog in arcmap, lets me calculate the statistics and histogram, and then I can define and edit a colormap for that layer, but this option to calculate the statistics for the WCS raster is not available. I also tried to create a classified or unique value colormap in the symbology tab at the properties dialog, but those options are not available for the WCS, only for the file opened directly. How can I make ArcMap take into account the style information I created using GeoServer or, alternatively, how can I make ArcMap let me create and use a classified colormap for this WCS raster. Thanks to anyone who tries to help.


Pass Queried Feature Set to geoprocessor as a parameter

I am new to geoprocessing services and tried to publish my first. I created a simple model with one parameter, a featureset, and I am intersecting it with another layer which is specified in the model and uploaded to the server. If I pass the required parameter,as below, it never executes. If I pass an empty parameter object, var params = {}, it runs.                   var app = {};         app.qtCounties = new QueryTask("http://myserver/arcgis/rest/services/PA_Counties/MapServer/0");         app.qCounties = new Query();         app.qCounties.returnGeometry = true;         app.qCounties.outFields = ["*"];              paCounties.on("click", getData);function getData(evt) {                 console.log("In GetData The Event graphic is " + evt.Graphic + "Point is ", evt.mapPoint.x, evt.mapPoint.y)                 var county, promises, qGeom, point, pxWidth, padding;                      point = evt.mapPoint;                 pxWidth = map.extent.getWidth() / map.width;                 padding = 2 * pxWidth;                 qGeom = new Extent({                     "xmin": point.x - padding,                     "ymin": point.y - padding,                     "xmax": point.x + padding,                     "ymax": point.y + padding,                     "spatialReference": point.spatialReference                 });                      app.qCounties.geometry = qGeom;                      county = app.qtCounties.execute(app.qCounties);                 console.log("deferreds: ", county);                 promises = new all([county]);                 promises.then(handleQueryResults);                 console.log("created d list");                           function handleQueryResults(results) {                     console.log("queries finished: ", results);                          gp = new Geoprocessor("http://myserver/arcgis/rest/services/TestIntersectModel/GPServer/TestIntersectModel");                     gp.setOutSpatialReference({ wkid: 4326 });                               var params = { "Input_Polygon": results[0].features };                     gp.execute(params, completed);                     function completed(res) {                         console.log("Completed GeoProcssing", res)                     }                               console.log("Params ", params)}      When the query runs I get a valid object in results which is set as the lone parameter. Apparently I am not passing the parameter as a featureset but not sure how else to pass it? Any help would be appreciated. I published my service using this example. Though, I did not publish it as a map service, the last step, and I am trying to access it via javascript api instead of the server web page method. The model works fine when run in desktop and providing the parameter manually.


How do you edit a stack of polygons simultaneously?

Using ArcMap 10.1. Lets say you have 100 polygons that all are in the exact same shape and in the exact same place. They appear to be one polygon. How would you edit the shape of all 100 at the same time, can you share vertices among the 100 polygons? Can you join all 100 and keep their separate attributes and Object ID's?


Sending coordinates via VHF Radios to Computers

I need to send and receive coordinates in NMEA format from a VHF radio to a computer. Any suggestions where to look in order to accomplish this task? The transmission will occur only when the user presses the PTT button. Thank you all.


Halo in OpenLayers (Line, Vector)

How to make a halo around the line of one pixel? For example, line (vector) hase blue color and its frame (one pixel) the black color. Thanks!


Vector Building Footprint Resources - Tokyo

I typically know where to look for this data in the United States, but I'm at a loss when looking for building footprint shapefiles abroad. I thought I could find what I was looking for with Open Street Map data, but when I check out http://downloads.cloudmade.com/asia/eastern_asia/japan/tokyo#downloads_breadcrumbs I don't get the files I need. Anyone know other resources, either official or osm?


How geographically accurate is Google Earth?

I'm using a KML file which I have loaded in to Google Earth. I am looking at some islands, and see items such as the following island: ![enter image description here](http://i.stack.imgur.com/nSYhr.jpg) Note the blue region is the polygon describing the area provided, and the image in the background. Sometimes I see similar shapes, but they are off a bit, such as below: ![enter image description here](http://i.stack.imgur.com/iBSpd.jpg) Bottom line is, I'm trying to get as accurate of a map of some of these island nations that I can. Is it fare to use the image that comes from Google Earth to attempt to make a better representation of such islands, or is there enough inaccuracy in the creation of Google Earth islands that it is not worth making any changes?


Spatial Views in SDE - What causes them to become unregistered from the geodatabase

Spatial views in ArcSDE allow you to join columns from a 'non-spatial' table in the database to a table with a 'geometry column'. They can also allow you to format and choose the attribute columns that you want to have included in your feature class. A spatial view is created with the SDE commandline tools to 'register' the view with the geodatabase. The view won't show up in ArcCatalog unless it is registered. I have a data maintenance process that utilizes spatial views. After running unattended for close to a year, I am now having a problem where the spatial view becomes partially unregistered from the geodatabase. This prevents the geoprocessor from seeing the feature class. It also introduces the fairly common SDE issue where you can't re-create the view because the tool tells you that it already exists, but you can't delete it because the tool tells you that it doesn't exist. Has anyone else run into this issue and come up with either a prevention or remediation strategy. Platform: ArcSDE 9.3x, Oracle10g, UNIX.


Python - indentation error

I've started learning python for future use in QGIS and using Ubuntu, installed with Python 3. I'm doing the tutorials from the great book for newbies "A byte of python". I'm having troubles running some python-programs from the chapter "Control overflow", all with the same error. For example running this file of mine, "while.py" : Input:               number = 23     running = True     while running:     guess = int(input('Enter an integer : '))     if guess == number:     print('Congratulations, you guessed it.')     running = False # this causes the while loop to stop     elif guess < number:     print('No, it is a little higher than that.')     else:     print('No, it is a little lower than that.')     else:     print('The while loop is over.')     # Do anything else you want to do here      Output(the error):                 File "if.py", line 4         print('Congratulations, you guessed it.') # New block starts here             ^     IndentationError: expected an indented block     morck@morck-N150-N210-N220:~/dokumenter$ python3 while.py       File "while.py", line 4         guess = int(input('Enter an integer :'))             ^     IndentationError: expected an indented block     morck@morck-N150-N210-N220:~/dokumenter$      Where the right output according to the tutorial should have been:               $ python3 while.py     Enter an integer : 50     No, it is a little lower than that.     Enter an integer : 22     No, it is a little higher than that.     Enter an integer : 23     Congratulations, you guessed it.     The while loop is over.     Done      Can't figure out what causes the error and need some insight understanding this. Thank you


How to know if shapefile is georeferenced?

I have a shapefile which is located in province in indonesia. it contains many sub-province if i removed sub regions inside a shapefile, and it leaves a small region, and my question is that small region's scale is as same as a previous scale into a map how to reset a new scale that i want?


How to save a raster and vector into a single PNG file in GRASS?

I am trying to save a raster and vector into a PNG file. The vector is overlayed on top of the raster map. I was only able to save the raster file into a png using r.out.png but without the vector.


Looking for .Net alternative to Mapxtreme

I'm pretty new to the GIS area. I was involved in a project that used MapXtreme server and MapXtreme SDK to query the tabs (as in SearchNearest , SearchInRadius etc...) I'm looking for an open source alternative that I can integrate in .Net web app that will use OpenLayers + Tile Cache and I'll be able to query Tab (or Shape) files after the user pin the map. Thank you in advance


Extract certain area of contours/satellite images

I have 2 satellite images (jpeg2000 format) and 2 xyz-files from the same area. I am trying to extract certain region from the area including contour lines and the satellite image in order to import these into Google Sketchup for terrain modeling. I have been able to create contour lines from xyz-files. Anyway, I would like to first merge contours and then satellite pictures and finally extract only certain part of the data (both contours and satellite pictures). Is there some kind of instruction available that would help in a problem like this?


spgrass6 and GIS_LOCK

I would like to thank's everyone first, i learn a lot here (gis.stackexchange) about GIS. I have one question about the use of GRASS within R session, i'm able to do some basic task, but i have one important issue is to use GRASS graphics through spgrass6::execGRASS. I'm aware of the capabilities of R in graphics (lattice, ggplot and others), but i would like to be able to use GRASS graphics because of some option like nviz. Here is a minimal exemple               require(spgrass6)     require(spatstat)     # to use SpatialGridDataFrame in ggplot     fortify.SpatialGridDataFrame <- function(data) as.data.frame(as.im(as.image.SpatialGridDataFrame(data)))          # initialisation and the use of spearfish60 data     initGRASS(gisBase = "/usr/lib/grass64", home = tempdir(), gisDbase = "/home/dickoa/GIS/grass/grassdata/", location = "spearfish60", mapset = "usr1", override = TRUE)          # verif     gmeta6()          execGRASS("g.list", parameters = list(type = "vect"))          parseGRASS("d.mon")          # and this command gave me errors     execGRASS("d.mon", parameters = list(start="x0"))      and the error message is :               ERREUR :Unable to get GIS_LOCK enviroment variable value      And generaly, i really like the R workflow using emacs (ESS) and the idea of keeping everything in script, it's one of the main raison for me to use grass within R, so i want also to ask for other R and GRASS users if this integration through spgrass6 (Bivand 2011) can allow me to do everything as in interactive session of GRASS. here is my R session info (i use Kubuntu 10.10 as OS)               R version 2.12.2 (2011-02-25)     Platform: x86_64-pc-linux-gnu (64-bit)          locale:      [1] LC_CTYPE=fr_FR.UTF-8       LC_NUMERIC=C                    [3] LC_TIME=fr_FR.UTF-8        LC_COLLATE=fr_FR.UTF-8          [5] LC_MONETARY=C              LC_MESSAGES=fr_FR.UTF-8         [7] LC_PAPER=fr_FR.UTF-8       LC_NAME=C                       [9] LC_ADDRESS=C               LC_TELEPHONE=C                 [11] LC_MEASUREMENT=fr_FR.UTF-8 LC_IDENTIFICATION=C                 attached base packages:     [1] grid      stats     graphics  grDevices utils     datasets      [7] methods   base               other attached packages:      [1] spgrass6_0.6-26 XML_3.2-0       rgdal_0.6-33         [4] sp_0.9-79       spatstat_1.21-5 deldir_0.0-13        [7] mgcv_1.7-4      ggplot2_0.8.9   proto_0.3-9         [10] reshape_0.8.4   plyr_1.4        MASS_7.3-11              loaded via a namespace (and not attached):     [1] lattice_0.19-17    Matrix_0.999375-48 nlme_3.1-98


How to get an older version of OpenStreetMap data?

For some reason in the map of the Dominican Republic's Capital there are a bunch of streets which doesn't have any names. I had an OSM file which I downloaded ealier this year which did have those streets name. I really don't know WHY the names has just dissapeared, but I would like to know if there is a way that I can get them back. Maybe I can download an older version and then re-upload it so the current version get the streets' names back. So can you tell me how to get an older version of the OpenStreetMap or can you give me any other alternatives to get the streets' names back? Thanks in advance.


Export Map Schema\Metadata

I've been digging around, but I can't seem to find out if it's possible. I create a series of maps for a client and I need to document all the specifications in the map. So I need to create a spreadsheet/word doc of all the properties set in each layer (i.e. symbology colors, border thickness, definitions queries, label expressions, source, coordinate system...basically all the settings in the layers properties dialogue box) Same thing for the data frame properties settings. Is there a function in ArcMap to do this? Thanks, Mike


Polygon to Polyline tabular data transfer

I am working with a Divisional database. The division is divided by districts and then the district is further sub-divided by its micro units called sub- districts. Its topological relationship was error free and in the table the polygon data were well defined in its sub-district, district and divisional columns. Now I have drawn its road network throughout the division. There are some highway with unique name that covers more than 6-7 sub-district polygon. Now I want to create a road database that will break the road at the sub- district boundary line and join the polygon data (Sub-district, district and divisional data) to the clipped road with its existing database. I think it is possible but I couldn't find any solution. Can anybody help me?


Client Side Cache google map

I need to Cache the google map on the client side through the openlayer.I havent tried the client side cache yet and have very little idea about it too.


Road Topology Problem solution for junction

I am working with a Road Network. I have digitized the lines with AutoCAD Map 3D. Then Imported it to ArcMap. After entering all kind of database I have created Routing Dataset. But unfortunately its not giving the desired route. The most probably problem may be the junction. I think there are few problems with junction between the road. Its a huge database and it cant be check manually every junction. Is there any way to create a network topology to check the junctions easily whether the roads snapped or not? Thanks


Multiple vertices after editing giving wrong start and end x, y co-ordinates

I have a small problem which I have been fighting to solve but in vain. Initially I generated some polylines across the river at various locations. I found some of them are smaller in size and not fitting the river width, Therefore, I edited those using advanced editing tool by using extend polyline tool. However,I did not have knowledge that extending would create one more vertex in the middle. When I am computing distance using my script, the script is calculating distance between two earlier vertices it did not consider the another end vertices to compute the x,y of the actual end point of the modified lines. Please suggest me how to get solution. I tried to delete middle vertices still I find wrong distance. Think that wanna to rebuild/repair the geometry, I am not sure. Thanks and appreciate your help!


How to set up a Coverage Layer for Atlas Plugin?

Has anybody utilized the Atlas plugin? I am starting to take a look and setting it up on a project. My question is how do you set up the layer that is utilized for the coverage layer. Is there a way to get a polygon the mimics the view of the map area shown in the Print Composer?


Passing selected polygon to INTERSECTS filter in a WFS request

In the code below,                  <ogc:Filter>          <ogc:Intersects>            <ogc:PropertyName>the_geom</ogc:PropertyName>            <ogc:Function name="querySingle">               <ogc:Literal>sf:restricted</ogc:Literal>               <ogc:Literal>the_geom</ogc:Literal>               <ogc:Literal>cat = 3</ogc:Literal>            </ogc:Function>          </ogc:Intersects>        </ogc:Filter>      i'd like to replace                  <ogc:Literal>sf:restricted</ogc:Literal>        <ogc:Literal>the_geom</ogc:Literal>        <ogc:Literal>cat = 3</ogc:Literal>      with a polygon selected by a user. I get the polygon from a selection event. I've tried a number of options, but none is working, yet. Any assistance will be highly appreciated. My environment: GeoServer 2.1.3, OpenLayers 2.11. **UPDATE:** I've transformed my geometry to `EPSG:4326`, the one used by my layers in GeoServer:               var geometry = event.feature.geometry.transform(new OpenLayers.Projection("900913"), new OpenLayers.Projection("EPSG:4326"));      The event.feature.geometry represents a polygon selected by a user. I've also converted the geometry to WKT format as shown:               var wktParser = new OpenLayers.Format.WKT();     var feature = new OpenLayers.Feature.Vector();     feature.geometry = geometry;          var wktGeom = wktParser.write(feature);      I've then passed the geometry in `WKT` format to the filter as shown below:               '<ogc:Filter>' +     '<ogc:Intersects>' +         '<ogc:PropertyName>the_geom</ogc:PropertyName>' +         '<ogc:Function name="querySingle">' +             '<ogc:Literal>ws:layer_2</ogc:Literal>' +             '<ogc:Literal>the_geom</ogc:Literal>' +             '<ogc:Literal>INTERSECTS(the_geom,' + wktGeom + ')</ogc:Literal>' +         '</ogc:Function>' +     '</ogc:Intersects>' +     '</ogc:Filter>';      But when I send a request, the following error is returned: `<ows:ExceptionText>Process failed during execution java.lang.ClassCastException: org.geotools.filter.AttributeExpressionImpl cannot be cast to org.opengis.filter.Filter org.geotools.filter.AttributeExpressionImpl cannot be cast to org.opengis.filter.Filter</ows:ExceptionText>`. Any idea on what I may be doing wrong.


Importing .svg images to use as Symbols in ArcMap 10.1

I have several .svg files that I want to use as symbols in ArcMap 10.1. However, I do not see any import feature or the sort to use these .svg pictures. Thanks


How to get an GeoExt LegendPanel with image/png instead of image/gif?

I am using a `GeoExt.LegendPanel` to show legends for my various layers in _OpenLayers_. The `GeoExt.WMSLegend` supports configuring which image format to use, but the LegendPanel does not utilize this causing the WMSLegend to fallback to _image/gif_. So far I have manually edited the _GeoExt.js_ minified file to make the WMSLegend use _image/png_ as default instead of _image/gif_ , but I would prefer to parameterize this. **Am I missing some way to configure my LegendPanel to use _image/png_ as my WMSLegend image format?**


Algorithm for estimating position of many objects and differentiating those?

Let's assume a crowd-sourced tree location use case where a research team asks hikers to GPS the location of a specific tree type in case they encounter it. This will lead to a large number of longitude-latitude points each identifying the measured (noisy) GPS location of a tree. The researchers would now like to compute from those measurements a map of those trees. That means they have to differentiate location point estimates for close trees and after assigning the estimates to a specific tree calculate the location of that tree. Now trees don't move and GPS measurements can be pretty inacurate. What clustering algorithm would be the canoncial choice for this application? (If you have an R package::function to suggest please tell me)


How to get the coordinate system from a PostGIS database?

My question is probably amazinlgy stupid, but I can't find the answer myself. I would like to extract from a database the latitude and longitude of points. For now, I'm getting x(the_geom) and y(the_geom), and I would like to know what is the coordinate system of the results I get. How can I know this?


create POV-Ray image from DEM-file in grass

I am working on `r.out.pov` Tool of grass 6.4 creating a POV-ray(beautiful 3D) image from an elevation raster. ![enter image description here](http://i.stack.imgur.com/wQjiB.jpg) You can see this link for more information about 3D analysis of `GRASS`.   r.out.pov manual   Can anyone help me(step by step for windows) creating such an image of my DEM file? and some help about targa file (.tga).


Polygon country boundaries in decimal degrees

Using Google Maps, I'd like to create draggable polygons (on the fly) of country boundaries (they don't need to be particularly precise). Something similar to this, but for countries. So I want the boundaries in decimal degrees, but I can only find the data in .shp or kml/kmz files via sites like: shp:   * http://www.naturalearthdata.com/   * https://hiu.state.gov/data/data.aspx   * http://www.gadm.org/ KML:   * https://www.google.com/fusiontables/DataSource?docid=1N2LBk4JHwWpOY4d9fobIn27lfnZ5MDy-NoqqRpk ... but I'm unsure about how I go about extracting decimal coordinates from those data sources. Any advice on how to best solve this problem? Thank you.


Can we use procedures in a Query layer (ArcGIS Desktop 10.1 & Server 10.1)?

I have one basic question that.. Can we use procedures in Query layer (ArcGIS Desktop 10.1)?? Currently I am using query layer for ArcGIS Desktop 10.1 and its working fine . My DBA person told me that its difficult to modify query for each time.. As per discussion he told me that for large database its difficult to use query layer he suggested to use procedures.. I searched on Google and ArcGIS help..but there is no such information.. We are using Sql Server 2008 r2 , ArcGIS Desktop/Server 10.1.. So any help/links will be highly appreciated : )


What is the Best Practice for ArcGIS Server File Structure?

My organization is trying to decide how to best organize our file structure for services we put on our ArcGIS Server. As of now we have subfolders within the root so our structure is:               http://<servername>/arcgis/rest/services/<subfolder>/<servicename>/MapServer      However, after looking around most other organizations we have found have a structure of:               http://<servername>/arcgis/rest/services/<servicename>/MapServer      Essentially just putting all the services in the root. Is there a best practice on this? I can see reasons for both, and I can't really see an issue with subfolders, but the fact that most organizations put them in the root makes me wonder.


Caching / Preloading data for use with WMS queries

Hoping someone can help me with this issue. I've got a map implemented in my web application using OpenLayers that makes WMS queries to GeoServer that in turn queries a Postgres (PostGIS) database to produce WMS tiles. It also makes use of WMS GetFeatureInfo to get information about features being moused over. Because of the amount of data that is being queried in the initial load for the tiles can take anywhere between 1-10+ minutes depending on the data that is being queried (query can be adjusted by date/time ranges and a few other properties), which is acceptable because it's a lot of data. But I've got a couple of performance related issues that I'm trying to get around.   1. Every time the zoom level is changed the database has to be re-queried. Is there a way the data can be cached so that it doesn’t have to be re-queried for each change in zoom level? The data doesn’t change depending on zoom level so the query being run is returning the exact same result each time.    2. When a user mouses over a feature, a GetFeatureInfo request is made and a popup is shown over the map detailing that feature. It once again has to run the whole query again and then it narrows it down to the feature that has been moused over.  Previously before changing to using WMS we generated a single KML file from the data we got from our database query and then this would be used for loading the map at all zoom levels and getting the feature info. We had to change from this approach to deal with bigger and more complex polygons. So simply, is there anyway to get GeoServer to use a cache result of the query data or is there any way I could perhaps generate the KML file how I was before but then pass it to GeoServer to render it as WMS tiles? Would much appreciate any input on the matter or any suggestions to get around the problems I've stated. Thanks in advance, Mark


Why is the dijit.popup not working correctly?

I take the following steps:   * Click 2 overlapping features from 2 different featLayers.   * Popup auto-selects and highlights map.infoWindow.features[first object]   * The popup content is actually from map.infoWindow.features[second object] After you navigate to the second graphic and back, the popup corrects it's self?? here's an example using esri data: http://jsfiddle.net/92Q2G/1/ Any advice? Thanks.


Geoserver - layer from sql server

I am new to Geoserver (version 2.4.3). I have configured SQL store and then tried to create a Layer over one of my views with the correct coordinate system, when I tried to preview the layer using openlayers - I got this error in the logs.               Caused by: java.io.IOException         at org.geotools.jdbc.JDBCFeatureSource.getReaderInternal(JDBCFeatureSource.java:610)         at org.geotools.data.store.ContentFeatureSource.getReader(ContentFeatureSource.java:563)         at org.geotools.data.store.ContentFeatureCollection.features(ContentFeatureCollection.java:165)         ... 108 more     Caused by: com.microsoft.sqlserver.jdbc.SQLServerException: Incorrect syntax near the keyword 'FROM'.         at com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:197)         at com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(SQLServerStatement.java:1493)         at com.microsoft.sqlserver.jdbc.SQLServerStatement.doExecuteStatement(SQLServerStatement.java:775)         at com.microsoft.sqlserver.jdbc.SQLServerStatement$StmtExecCmd.doExecute(SQLServerStatement.java:676)         at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:4575)         at com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:1400)         at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(SQLServerStatement.java:179)         at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(SQLServerStatement.java:154)         at com.microsoft.sqlserver.jdbc.SQLServerStatement.executeQuery(SQLServerStatement.java:611)         at org.apache.commons.dbcp.DelegatingStatement.executeQuery(DelegatingStatement.java:208)         at org.apache.commons.dbcp.DelegatingStatement.executeQuery(DelegatingStatement.java:208)         at org.geotools.jdbc.JDBCFeatureReader.<init>(JDBCFeatureReader.java:140)         at org.geotools.jdbc.JDBCFeatureSource.getReaderInternal(JDBCFeatureSource.java:580)         ... 110 more     2013-12-29 12:49:52,626 INFO [geoserver.wms] -      Request: getServiceInfo     2013-12-29 12:49:52,632 ERROR [geotools.rendering] - Error querying layer     java.lang.Exception: Error transforming bbox         at org.geotools.renderer.lite.StreamingRenderer.getStyleQuery(StreamingRenderer.java:1068)         at org.geotools.renderer.lite.StreamingRenderer.processStylers(StreamingRenderer.java:2009)         at org.geotools.renderer.lite.StreamingRenderer.paint(StreamingRenderer.java:837)         at org.geoserver.wms.map.RenderedImageMapOutputFormat.produceMap(RenderedImageMapOutputFormat.java:481)         at org.geoserver.wms.map.RenderedImageMapOutputFormat.produceMap(RenderedImageMapOutputFormat.java:251)         at org.geoserver.wms.map.RenderedImageMapOutputFormat.produceM


change style of newly drawn points

I've a vector layer with a bunch of draw controls on it. You can add polygons, points and you can modify polygon. Now I changed the style of the points so they have a nice pin-like image. But them I noticed when I select the modify polygon tool and select a polygon, the handles on the polygon are also replaced by my point-image. How do I fix that?               this.panel = new OpenLayers.Control.Panel({             allowDepress: true,             autoActivate: false         });         this.controls = {             "polygon": new OpenLayers.Control.DrawFeature(this.layer, OpenLayers.Handler.Polygon, {                 "title": "New Zone"             }),             "POI": new OpenLayers.Control.DrawFeature(this.layer, OpenLayers.Handler.Point, {                 "title": "New POI",                 "displayClass": "olControlDrawPoi"             }),             "modify": new OpenLayers.Control.ModifyFeature(this.layer, {                 "standalone": false,                 "title": "Edit Zone"             }),             "clear": new OpenLayers.Control.Button({                 displayClass: "olControlClearLayer",                 trigger: myLocations.clearLayer,                 title: "Clearlayer"             })         };         for (key in this.controls) {             this.panel.addControls(this.controls[key]);         }              myMap.map.addControl(this.panel);      I tried adding the style in the Point Handler but that has no effect. I also tried to set a feature property so I can use a symbolizer in the style, but i can't figure out how to add this property before the feature is actually drawn. (so this works, but only after a layer.redraw(). So I want to have defautl styling for the polygons and its handels when its in modify mode, but I do want a nice marker image for my newly drawn points. Any ideas?


How to fill the area bounded by lines in QGIS?

There are two types of area I want to fill color:   * The areas bounded by a line, such as a building   * The area bounded by different lines, such as the river I don't know how with QGIS. I only know how to fill colors in polygons but bot lines .May you provide some suggestions? Thanks! The image here shows that the building and rivers are composed of lines: ![The image here shows that the building and rivers are composed of lines](http://i.stack.imgur.com/3yLVT.png)


How to convert (geodetic pose + cartesian offset) to geodetic position

I am in search of an algorithm to solve the first/direct geodetic problem precisely in 3D. The input is:   1. a geodetic (not geocentric) position (WGS84, height is above the WGS84 reference ellipsoid)   2. heading (relative to true north)   3. pitch and roll (relative to gravity, which isn't necessarily pointing towards the center of the earth)   4. a 3d-offset from the pose P (defined by 1,2,3) to a point A, given in cartesian coordinates (meters). The output should be the geodetic position (again, WGS84) of point A. I have read Algorithm for offsetting a latitude/longitude by some amount of meters and this is how I've computed the solution in the past. It is obviously computationally efficient, but not precise enough anymore. Currently, my idea is to   1. convert 1. to ECEF, populating the 4th column of a 4x4 matrix with the solution.   2. incorporate the angles/orientation into that matrix   3. multiply the matrix with the 3d vector to A to compute the position of A in ECEF.   4. convert this back to Geodetic WGS84 (which isn't quite straightforward). Of course, I still would like things to be fast, but precision has a definite priority here. My questions:   * What do you think of this approach? Does it work, is it precise? (I fear that compensating for pitch/roll not being relative to the center of the earth would probably imply a LOT of additional complexity).   * Is PROJ.4's pj_transform() capable of computing the conversions in steps 1 and 4? If not, what C/C++ library can you recommend? This must be a common routine in some library?! Note to whuber: Thank you for referring to 30448! I think I'm slowly starting to resolve misunderstandings, getting an idea of what you do. Questions about your answer to that question:   * When you say "geocentric", you mean cartesian coordinates from earth center (=ECEF), right? (I first interpreted "geocentric coordinates" just like "geodetic coordinates", except the latitude being determined using earth-center instead of ellipsoid-normal. Now I know that "geocentric latitude" != "geocentic coordinates". Whew.)   * In the first image of 30448, you show "the geocentric frame at the North Pole". The origin of that coordinate system really is at the center of the earth, right? But if your first image started at earth's center, simply rotating wouldn't get you to the origin of the local coordinate system. So why does it start at (0,0,6370) in the first picture? You could have also chosen (6370,0,0), but then rotations would be different. Is it that each initial offset corresponds to an Euler convention (Z-Y'-Z'')?   * If so, it then seems to me that my drafted approach is very much similar to your solution at 30448. Are there other approaches that are more precise? Given I compute using doubles, what accuracy do you expect?   * Slightly OT: At the end, you add a local Z displacement motivated by differences against MSL - but I thought the WGS84 datum you referenced earlier is not a tidal/MSL datum, but an ellipsoidal. Assuming you sticked to WGS84, you'd add the local Z offset based on the distance to the ellipsoid, right? @whuber, @martin f: thanks for your quick replies and patience - I read the whole day, trying to understand more.


FileGDB open API and tools based on it

As we know esri shared their library which makes it possible to work with FileGDB format without using ArcObjects. So the question is what kind of applications could be created in order to help GIS specialist to solve their tasks related with this format? For instance, I have an idea to create an opensource tool(GPL) which converts FileGDB to Shapefile (or other format) and backwards. Will it be in the demand? or perhaps somebody have already developed such tool? I will be grateful for any ideas about that (as well as collaboration ideas).


Is there a described GIS method for creating catchment areas based on nearest driving distance?

ie. a combination of Voronoi polygons with isochrones, so that the Voronoi polygons are based on driving distance instead of Euclidean distance. Is there a name or a described method for this?


Adding an image instead of standard svg to Polymaps

I wanted to add a custom marker to my demo: http://drewwells.net/craigmaps/ Instead, I had to make a red dot to specify the place I wanted. Adding an image seems to want to layer that, but all I want is to stick the center of an icon to a lon/lat I specify. On the same topic, is there any other way to put a point on the map than setting up a geoJSON with geometry set to point. This seemed counterintuitive, but was the only way I could figure it out with just the docs and demo to go buy.


Can one batch-automate the creation of QGIS heatmaps?

I have 4k point shapefiles, from which I would like to generate heatmap TIFFs using the QGIS heatmap plugin (or a functional equivalent featuring triweigth, radius and cell size selection). Is there any way to batch / script / automate this? I.e. "add vector shapefile, run heatmap plugin with specific options, remove vector shapefile and raster heatmap, add next vector shapefile, repeat..."?


Open Street Map and PostgreSQL what do I exactly need?

I make my first steps in the GIS world and everything is very new for me even if I work on a "huge" project (ie: for a single programmer) very related to maps. My project needs to know informations below for any location of the world:   * Road type   * Road name   * Road coordinates   * City boundaries   * Water way name   * Water way coordinates I found that I could have all this informations thanks to Open Street Map and my project begins to work thanks to this. But now I need to work on bigger maps (ie: bigger than the 50.000 XML nodes limit OSM export provides). I know I need to put the whole planet in a database. There is a lot of documentation about PostgreSQL and Open Street Map on the Internet but I don't know where to begin. In fact I found documentation about Osmosis in order to put a planet dump in a database, but I also found about osm2pgsql. The point is I don't know what is the best for me. It seems (but I can be wrong) osm2pgsql has been made in order to render mapnik maps, thing I don't need at all because I have to know roads/cities/water ways informations... But I am not sure to have correctly understood what mapnik can do. My question is: What can I use to insert OSM datas in a database in order to reuse it later as easily as an OSM exported file? Thank you. **EDIT:** The computer I use is a dedicated server (Intel(R) Pentium(R) E2180 2.00GHz and 2GB of RAM) running a GNU/Linux Debian. PS: I know my question seems dumb, because osmosis can insert but also extract a xml file from a database. Anyway, I need to know how you would do it. PS: If someone knows where to find nice OSM+database tutorials for beginner I would appreciate!


Missing Layer in OpenLayers

When I try to include the "fwp layer" from geoserver 2.4 (Ubuntu 12.4 VServer) into my code it doesn't show up. But the geoserver layer preview (OL) shows the right image. The GeoExplorer preview shows only pink tiles with a questionnmark. The fwp layer is a Geotiff file which I had transformed with `gdaladdo -r average FWP_neun1.tif 2 4 8 16` Here is the actually website: WEB GIS where it should work. Thanks a lot for your help!


Is there an event fired when a kml layer has finished loading in google maps? Google maps api version 3 To add a layer I have code like:               var layer = new google.maps.KmlLayer(layerUrl, { map: map, preserveViewport : true });      To remove a layer, I have code like:               layer.setMap(null);     layer = null;      The kml are rendered by google maps as images on the clients machine (i.e. the polygons are not created on the client). I have a number of kml files displayed on a map. When the user clicks a button, I remove those KML layers, and replace them with other similar KML layers (depending on user input). The transition is a bit slow. The user sees the map without any KML layer for about 30 seconds. I would like to display a loading sign, from the moment the user clicks the button, to the time that the KML layer finally appears. I need some way to decide when to remove the loading sign. Thanks **edit:** Looking at stackoverflow (I should have checked), they suggest using:               google.maps.event.addListener(layer, 'metadata_changed', function () {      e.g. here: http://stackoverflow.com/questions/5668816/google-maps-api-3-loading-icon On my first draft, that event seems to fire some time before the layer is actually displayed, but I shall investigate further.


What alternatives to Orfeo are out there and what are the pros and cons of each?

I'm interested in using a library for abstracting the common, repeatable tasks that entail the usage of GDAL (like registiring a driver, getting bands.. etc). In general, GDAL is "low-level" and most of the time there are a lot of copy-pasted code all over a project. I need something on-top of GDAL that hides all the "day-to-day" tasks. For example, for rasters I'd like to have a cube-based view of the it (kind-of what the python bindings do but for C++). Orfeo seems to fit the bill (taken from Orfeo's homepage):   * image access   * filtering   * feature extraction   * image segmentation   * classification   * change detection But I'd be using only its image-abstraction functionality, so it seems an overkill. Before embracing the use of it I'd like to know if there are other alternatives and what are their pros and cons.


Web Browser ActiveX control error

I am getting this message (attached) that says: "An ActiveX control on this page is not safe. Your current security settings prohibit running unsafe controls on this page. As a result this page might not display as intended." I have ArcGIS version 10, and installed it on Windows 7, 32 bit. What should I do?


How to get the geometry type of an empty PostGIS table?

I have a web application that needs to know the geometry type of a PostGIS table's geom field before inserting rows into it. I use the following query to determine the geometry type of the geom column:               SELECT GeometryType(geom) FROM my_schema.building LIMIT 1      This returns the geometry type of an actual row, so it does not work when my table is empty. How do I determine the geometry type of the geometry column itself?


Trying to build GDAL's ECW plugin in 64 bit Linux

I'm trying to build the GDAL's ECW plugin in Linux. I'm using the latest version of the SDK from Intergraph's site (5.0). It fails because it tries to compile against the 32 bit version of the library and not the 64. Here's the error message where the process dies:               /usr/bin/ld: skipping incompatible       /usr/local/ecwjp2_sdk/lib/x86/release/libNCSEcw.so when searching for -lNCSEcw     /usr/bin/ld: skipping incompatible         /usr/local/ecwjp2_sdk/lib/x86/release/libNCSEcw.a when searching for -lNCSEcw     /usr/bin/ld: cannot find -lNCSEcw      I have pointed ldconfig to look in /usr/local/ecwjp2_sdk/lib/x64/release, but that seems to be ignored. Is there any way to force it to look in the 64 bit version's directory, or can I get away with changing the symlinks for the 32 bit version and have them point to the 64's instead?


Map hosting options

I'm trying to figure out how to best get started on a web-mapping project, and am wondering about where I should host my maps from. In terms of my skills, I'm quite good at desktop mapping and cartography, and I've got mediocre PHP, mySQL, HTML and CSS skills - but I want to create this really fantastic interactive web map site that will (in my dreams only, probably!) have some kind of base layer, then overlay my own township and section grid, and have possibly hundreds of thousands of sample points. Each of these points will have data attached, and when clicked, will display it's info in a pane, and then provide the ability for registered users to comment on and discuss it. I'd like to also get some kind of feedback (thumbs up/down) ability for each user comment. Maybe I'm too optimistic, but this is what I'd like to have in the end. My reading tells me I need a stack containing something like postGIS, MapServer, and OpenLayers. But I use inmotion for my current web development and learning, which I really like, so rather than waste time figuring out how to install all of these packages there (if I even can), is it better to go with an outfit like mapserverpro.com, which has this stuff set up already and specializes in GIS hosting? The price of their hosting packages is not a problem, and I just want to get pointed in the right direction to start with. I guess that my short question is: does anyone here have an opinion on what mapserverpro.com is like? Even mapserving.com? Or would a generic hosting service usually be able to handle the stack that I mentioned, and efectively be able to handle what I picture as being a large amount of GIS data? Also, if anyone has any comments on how to most efficiently tackle a project like this, then please feel free to set me straight.


How to change the order of features in a shapefile?

I have a shapefile and I want to change the order of the features. Is that possible using ArcMap?


Faster way than Spatial Join to join field from attribute table to address table?

I have a table of addresses for every state in the nation. I just recently finished doing spatial joins and adding in census block/tract data per state. I have a national shapefile of CoreBasedStatisticalAreas, is there a faster way to add one field from this attribute table to my completed address tables (millions of records) than doing Spatial Joins?


Moving a shape around the earth while maintaining the proper projection

What is the transformation needed to be taken on every data point of a shape to rotate that shape around the globe. I'm trying to figure out the math behind this kind of transformation so I can create something similar to this using leaflet and d3 https://gmaps- samples.googlecode.com/svn/trunk/poly/puzzledrag.html **Edit:** To be clear, I am looking to achieve this using leaflet, D3, and javascript not desktop GIS software. My end product will a function that takes a point `(lat,lng)` shifts it by an amount `(shift_lat,shift_lng)` and returns `(new_lat,new_lng)`


What is the best way to migrate an SDE Database

We have a prod database, with an SDE schema. We want to install a new SDE instance 9.3.1 and link it to a copy of the prod database. ArcSDE 9.3.1 on Linux SLES 4 Now, what is the best way to do this. It isn't an upgrade, so you cant really upgrade the SDE install I think? If you simply install the SDE on top of a pre-existing SDE schema, there are all sorts of links broken, indexes, data issues, etc. So, if I am correct, then is the only way to go, is to build an empty database (save from the users table) and then import all of the data via sdeimport (obviously using the date from a sdeexport)? I am not normally involved with SDE, preferring to leave it with those mystical creatures, the DBA's, but I can't find one here (I believe they Apparate and Disapparate without control) so have no option but to do this myself, and find myself without the 100% self belief it is the right way to go. Any ideas? **EDIT** We have no way of accessing the original data live, so have to export the Oracle data from one area to another, before we can access it e.g. we cannot simply access the live data 'live' as such.


How to read an Excel sheet in ArcPy script

I'm writing a python code to convert X,Y points in excel to shapefile. In this process i have toread xy points from shhet1. What is the step i have to include in my process to read data from sheet1 of an excel work book(97-2003).   I wrote a code as follows..               import arcpy       from arcpy import env       import Xlrd       env.workspace="E:\"       input_table="123.xls\Sheet1"       But its not working.Please advice.


Arcpy text strings as gp expressions

I’m using a while statement to count down from x until it = y. Each loop decreases x by 1. This variable (among other variables) is passed into a geoprocessing tool’s expression variable as a string. The string exactly mimics a user specified expression. Alas the ArcPy .gp does not accept my identical variable as an expression. How does one take a text string, and pass it off as a text expression?               ####### Raster values to separate rasters     import arcpy     arcpy.CheckOutExtension("spatial")          ######## Script arguments          FolderLocation = "C:\\Data\\Testing\\"     InRaster = "C:\\Data\\ basin00_dem"          TopVal = 236     BotVal = 127     Range = TopVal-BotVal     print "There are: "+ str(Range) +" values to iterate"     print " "     SingleValue = "s1_"          MegaCount = TopVal          while (MegaCount) > BotVal:         MegaCount = MegaCount-1         ## Reclass Single Values         SingleValueName = SingleValue + str(MegaCount) +".tif"         SingleValueNamePath = FolderLocation + SingleValueName         RC1 = "\"" + str(BotVal) +" "         RC2 = MegaCount -1         NODATA = " NODATA;"         RC3 = str(MegaCount) +" "         RC4 = str(TopVal)+ " "         Val = "1 " + "\""         Qu = "\""         Equ = str(RC1) +str(RC2) + NODATA + str(RC3) + str(RC4) + str(Val) +str(Qu)         Range = Range -1         print "Number: " + str(Range) + " Equ: " +str(Equ)         arcpy.gp.Reclassify_sa(InRaster, "Value", Equ , SingleValueNamePath, "NODATA")               # WORKING .GP     # arcpy.gp.Reclassify_sa(InRaster, "Value", "127 233 NODATA;234 236 1", SingleValueNamePath, "NODATA")     # Example print of Equ: "127 129 NODATA;130 236 1"


Creating sign locations from an existing database with offset & dist to nearest intersection (buffer analysis)?

I have a database of 22,000+ signs that contains the offset from centerline along with a distance to/from the edge of pavement to a specific intersecting road for each sign. I also have a street centerline layer and pavement polygon layer with edge of pavements. I'm trying to create point features for the signs based on the offset from centerline and the distance from the nearest intersecting roadway. Looking for some ideas on what tools to use for this analysis (buffer, selectlayerbylocation, etc?) ![graphic representation](http://i.stack.imgur.com/3sJ4I.png)


More zoom in base layer in openlayer.

I have some GIS project to do, in this project I need to place something like 20,000 trees on a map.   So I did a web app with .net that includes map that based on OpenLayers with bing base map. My problem is that I need to get more closer to the base map, because the maximum scale that I can get is 50 ft, but I need to be much closer to place the tree in the right place. Is there any way to make option to do more zoom? More then 50 ft? I tried to change the zoom levels or the resolution, but nothing worked for me until now.   Maybe I need to use other base map then bing?   Or maybe I cannot get closer on raster map?   Thanks.


Is there a way to delete definition querys of multiple layers in ArcMap 9.3.1?

I'm searching for a way to freeze/delete definition queries of several layers at once (instead of doing it manually by opening the properties of each layer). I'm working on a SDE 9.3.1 Geodatabase.


Proper disposal of layers

I have a group layer. Its purpose is to show feature layers over a base map. Those feature layers are logically grouped into categories and we provide the ability to add/remove whole categories through a menu. The categorization is done using a dictionary `layerCategories <string [category name], List<IFeatureLayer>>` When I want to delete a category, I do something like the following               void deleteCategory( string categoryName){       foreach(var layer in layerCategories[categoryName]){         theGrouLayer.Delete(layer); // delete layer from group layer       }       layerCategories.Remove(categoryName); // remove layers (along with the category)     }      The code works, what I ask if it could be done better. I mean, are the layers disposed properly this way or should I do something explicitly? Thanx in advance


Errors when converting MapInfo .tab to .dxf

I am trying to convert some MapInfo files to .dxf format using OGR2OGR using the following command:               OGR2OGR -f "DXF" "input.dxf" "output.TAB" -overwrite -skiperrors      When I run this I am getting a lot of errors which say "DXF layer does not support arbitrary field creation, field 'xref' not created". **Can you not attach data to records in DXF files?** I am also getting the error "No known way to write feature with geometry 'none'" and the same for "Multi Point". **Which geometry types can DXF support?** Update: In Mapbasic the Export command allows exporting to DXF, thereby negating the need to use OGR2OGR.


How to fix QGIS Server internal server error when using shapefiles?

i read all the questions with 500 server error i could find on the net but nothing seems to solve my problem: I installed qgis and all depending packages on a debian server. The first REQUEST=GetCapabilities worked fine and i created a qgs project file in qgis desktop on my windows workstation. Then i moved the project file + shapefiles to the cgi-bin directory and changed the permissions to do everything for everyone. Calling REQUEST=GetCapabilities then gave me a nice output but no layers. The problem was I forgot to change the path to the shp files. After changing it and retrying the REQUEST=GetCapabilities i got the 500 internal server error. In apache log it only says "premature end of script headers: qgis_mapserv.fcgi" - nothing else. no missing libary. To make sure it wasn't something with a specific shapefile i created a project with a single raster layer and a png file. I copied both to my cgi-bin folder again. And surprise. This is working. I get my raster image displayed I also tried to put the shapefiles into my home directory and pointed the path in the project file there --> 500 tried absolute and relative pathes in project file --> 500 Any ideas why qgis desktop is working with my shapefiles but qgis server doesn't?


How to convert a point layer to a raster grid that shows the frequency of points per cell in QGIS

I have a point layer that shows the distribution of a species. Is it possible in QGIS to convert this point layer to a raster grid in which the value of each cell corresponds with the amount of points within that cell? Until now, I only managed to attach attribute values to the grid cells. I have already added a column in my attribute table that has the value '1' for each point, hoping that there is a way to use a sum of attributes for each grid cell. Can anyone please help me? Thanks!


Dividing polygon with another polygon?

I am working in ArcMap 10. I am trying to divide a polygon with another polygon. I don´t want to clip any part away, but only to divide the polygon? The polygons are stored in two different layers. I would like to do it using the ModelBuilder tool. I have tried the split function but it is not working. In this tool I have to choose an input and a field that the division is based on, but none of the fields are working.


exporting metadata from gps camera to spreadsheet

I have a question involving exporting metadata from a GPS camera to an application such as a spreadsheet. In essence, I'm working with a significant number of images taken with a GPS digital camera. The GPS coordinates are embedded in the metadata that is accessed when you open the “properties” tab on the jpg file. Is there a computer program or tool available that can extract that metadata automatically and put it into a file that can be manipulated (e.g., put the GPS coordinates in a spreadsheet)?


Generating "weighted convex hull"

sadly I don't have any keyword that reflects what I'm looking for: I have a vector layer consisting of points, which have an integer attribute ("signal quality" here), that I want to plot as a convex hull. While the resulting shape is what I expected, I want to have some **colouring on the shape** that represents the quality level, too. IMHO a heatmap would only add simple spots, but is there a way to generate something that looks like a **weathermap** like multicolored shapes? I tried buffers but didn't managed it to bring everything playing together :/


Using floating point raster image for majority filter in ArcGIS?

I'm trying to do filter images using Majority filter in ArcGIS. My input images is a float point raster image in .img format. There is an error saying "Invalid parameters". What does it mean?


Update database via osmosis and osm2pgsql too slow

I got a box with the current hardware config:               CPU: Intel Xeon E3-1220 V2 3.1 GHz     RAM: 10gb     Hard Disk: Western Digital WD10EZRX SATA Hard Drive          OS: Centos 6.5 64 bit     DB: PostgreSQL 9.3.2      and PostgreSQL got following config               shared_buffers = 1024MB     work_mem = 256MB     maintenance_work_mem = 4096MB     fsync = off     synchronous_commit = off     checkpoint_segments = 100      I imported the entire OSM Europe data into PGSQL DB with the following command:               osm2pgsql -c -d gps -U gps --cache 8000 --number-processes 4 --slim europe-latest.osm.bz2      and it took 6 days to complete... it's a lot but it's ok... now i want to keep my DB updated with the combo of `osmosis + osm2pgsql` cmds:               osmosis --read-replication-interval workingDirectory=/osmosisworkingdir/ --simplify-change --write-xml-change - | \     osm2pgsql --append -d gps -U gps --cache 8000 --number-processes 4 -s -      Well... this takes MORE than one day to just align single day changes! That makes impossible to keep my local DB aligned! Am i doing something wrong? Should i upgrade my RAM? Why updating is SOOOOOOOOOO damn heavier than load data for the first time?


How to get the direction raster from r.walk or r.cost

I am trying to use r.cost and r.walk and r.drain to calculate the shortest path from an archaeological site to the nearest basalt source. I am using all this algorithms with the processing toolbox (I have no grass experience...). I am able to run both r.cost and r.walk but when I try to use r.drain I have a python error. I thought I can use the rasters created to obtain the path in another program (Yes, like ArcMap). In order to do so I need the "movement direction raster" that you are suppose to get either from r.walk or r. cost. Nevertheless, when I use r.cost or r.walk from the processing toolbox and I can only visualize the cumulative costs rasters and not the direction ones. I also looked for an option to define a name and a path for the movement direction raster showing advanced parameters, but I have no luck either. ¿Does somebody know how to produce this movement direction raster? (if possible from the processing toolbox). I am using Dufour 64bits on win7 16mb of ram (standalone install and osGeo4w install) Thanks in advance Gerardo PS. This is the Python error: An error has occured while executing Python code: Traceback (most recent call last): File "C:\Users\IIAMaps/.qgis2/python/plugins\processing\gui\AlgorithmExecutionDialog.py", line 208, in accept self.setParamValues() File "C:\Users\IIAMaps/.qgis2/python/plugins\processing\gui\AlgorithmExecutionDialog.py", line 143, in setParamValues self.paramTable.valueItems[param.name]): File "C:\Users\IIAMaps/.qgis2/python/plugins\processing\gui\AlgorithmExecutionDialog.py", line 189, in setParamValue value.append(options[index]) IndexError: list index out of range Python version: 2.7.5 (default, May 15 2013, 22:44:16) [MSC v.1500 64 bit (AMD64)] QGIS version: 2.0.1-Dufour Dufour, d94c044 Python path: ['C:\Users\IIAMaps/.qgis2/python/plugins\processing', 'C:/PROGRA~1/QGISDU~1/apps/qgis/./python', 'C:\Users\IIAMaps/.qgis2/python', 'C:\Users\IIAMaps/.qgis2/python/plugins', 'C:/PROGRA~1/QGISDU~1/apps/qgis/./python/plugins', 'C:\Program Files (x86)\ArcGIS\bin', 'C:\PROGRA~1\QGISDU~1\bin\python27.zip', 'C:\PROGRA~1\QGISDU~1\apps\Python27\DLLs', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\plat-win', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\lib-tk', 'C:\PROGRA~1\QGISDU~1\bin', 'C:\PROGRA~1\QGISDU~1\apps\Python27', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site-packages', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site-packages\PIL', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site-packages\win32', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site-packages\win32\lib', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site-packages\Pythonwin', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site- packages\Shapely-1.2.18-py2.7-win-amd64.egg', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site-packages\six-1.3.0-py2.7.egg', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site-packages\wx-2.8-msw-unicode', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site-packages\xlrd-0.9.2-py2.7.egg', 'C:\PROGRA~1\QGISDU~1\apps\Python27\lib\site-packages\xlwt-0.7.5-py2.7.egg', 'C:\Users\IIAMaps\\.qgis2\python\plugins\mmqgis/forms', 'C:\PROGRA~1\QGISDU~1\apps\qgis\python\plugins\fTools\tools']