title: How to switch off symbol when label is unplaced due to conflicts?

text: Using either the standard ArcMap labelling engine, or the Maplex engine, it is possible to automatically omit labels from the map when the area is too congested. Eg in the centre of this image, there are too many towns close together so their labels aren't placed: ![enter image description here](http://i.stack.imgur.com/hiIEx.png) Is there a similar method to switch off those towns' **symbols** as well? Ideally I'm looking for something automated, which works based on the current viewport (in the same way that the labels are automatically re-positioned if you pan or zoom the map)


title: ArcGIS 9.2 - Problem importing raster into geodatabase

text: When I try to import a raster (jpg or tiff) into a file geodatabase using ArcCatalog, MS Picture Manager opens and tries (unsuccessfully) to open RasterConversion.py located in my ArcGIS program files ArcToolBox\Scripts. What am I doing wrong? Any help greatly appreciated.


title: pgrouting shortestpathfromAtoB multiple pairs

text: I've got to solve a shortest path problem between multiple location pairs. E.g.: A to B C to D E to F etc. These pairs are stored in a table routing_basis like hkey; A; a.lat; a.lon; B; b.lat; b.lon I use the function described here (changed it a bit to get back a row called hkey): Route between lat/lon points and return ordered geometry with heading I then use the query               SELECT hkey, st_union(geom_way),sum(cost) FROM      pgr_fromAtoB('at_2po_4pgr',15,15.402234,48.360803,15.624435,48.20798) group by hkey      to get the aggregated costs. Now I want PG to do the calculation for all the pairs found in the table routing_basis. How can I get PG to do this? I have no clue! Thanks for your help. Carsten EDIT:   Sorry, maybe I should be a bit more precise. I want PG to do a workflow like:   1. Calculate route A to B (PG takes the lat/lon from table basis_routing) SELECT hkey, st_union(geom_way),sum(cost) FROM pgr_fromAtoB('at_2po_4pgr',15,15.402234,48.360803,15.624435,48.20798) group by hkey   2. Write the result into a result table   3. Calculate route C to D (PG takes the lat/lon from table basis_routing) SELECT hkey, st_union(geom_way),sum(cost) FROM pgr_fromAtoB('at_2po_4pgr',25,18.402234,44.360803,19.624435,44.20798) group by hkey   4. Write the result into a result table   5. Calculate route E to F Any ideas? Thanks for your help Carsten


title: Low quality legend in QGIS

text: I am sorry to repeat a question already asked by someone else, but it has not been answered yet. When I create a map in QGIS the legend symbols for some reasons have a very bad resolution and are not saved as vector element but as pixels. Already in the QGIS-Window the legend looks bad and it doesn´t get better if I export it in high resolution. However, the symbols in the map are saved as vectors and very sharp. Any idea what might be the reason? Thanks for your help in advance!


title: What are necessary GeoExt dependencies?

text: Is use of **OpenLayers-2.11** , **GeoExt-1.1** and **ext-4.0.7-gpl** supported . I have only included ext-all.js in the script src. Should I include others too?


title: Location for floorplan

text: Is there an application / service where I can put my floorplan of a building en 'position' it on the right place on the earth? (The buildings location). I found TileMill an application where I can import an raster image in. Howerver the image covers the entire world. When importing I supplied an 900913 'string' with some information about the location and size I presume.               +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0.0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs +over      With the above string the building 'covers' the entire earth. Is there a way to get the 'correct' string so I can place it over the correct building? Kind regards


title: Openlayers Overview - disappearing layers

text: when I do this:                   var options = {             autoPan : true,             size : new OpenLayers.Size(300, 200),             layers : this.map.layers,             mapOptions : {                 allOverlays : true             }         };         var ov = new OpenLayers.Control.OverviewMap(options);              this.map.addControl(ov);      my layers are only shown in the overview window. The layers disappear from the main screen. Any suggestions how to fix it?


title: Insanely large house numbers in TIGER data

text: I'm parsing the US TIGER data and I'm coming across huge house numbers. example: 10100005 Thousand oaks drive, st johns, florida Google maps, and open street maps - nominatim says this is valid! Im not from the US so im finding this very confusing, Any thoughts? links: https://www.google.com/maps/place/10100005+Thousand+Oaks+Dr/@30.2107612,-81.381784,17z/data=!3m1!4b1!4m2!3m1!1s0x88e437b298499921:0xbf10cbfa2e69c84a http://nominatim.openstreetmap.org/search?q=10100005%20Thousand%20oaks%20drive,%20st%20johns,%20florida&format=xml&addressdetails=1 EDIT: if the housenumber is > 100000, should i just drop it?


title: Does PostGIS have separate implementation of GiST index from PostgreSQL?

text: I want to know if PostGIS has a separate implementation of GIST index or it reuses the GIST index implementation provided by Postgresql?


title: Create points from lines

text: I used the Bearing Distance to Line command (Data Management) in arc to convert UTM coords (i.e. of a plot center), bearing and distance to the figure shown below. The end of each line represents a tree location. How can I convert these lines to points in order to represent tree locations as a point shapefile? Thanks for the help. ![enter image description here](http://i.stack.imgur.com/JnqQa.jpg) **Edit** : The final model and final product based on help from others: ![enter image description here](http://i.stack.imgur.com/LSyJH.jpg) ![enter image description here](http://i.stack.imgur.com/ZgdqG.jpg)


title: Simple PostGIS ST_Distance query for two points from the same geometry table?

text: _Note: This question was published at Stackoverflow atfirst._ I have a geometry table `points_table` with `SRID 4326` and a few points in it. I need to find a distance between a pair of points (features) from this table. I would like to select one point with `id = X` and another point with `id = Y` and then find a distance between them with `ST_Distance` function. I know how to query these two points from the database:               select * from points_table where id = X or id = Y;      But this query returns a result, which I do not know how to pass to `ST_Distance`, because `ST_Distance` takes 2 parameters. I have tried `Select ST_Distance(select the_geom from points_table where id = X or id = Y);` But it is obviously wrong. How can I find the distance between two geometry points (features) from a table? P.S. All the examples I have found so far show the ST_Distance usage with points hardcoded into the arguments of the ST_Distance function. I have not found an example, where ST_Distance is used to calculate a distance between two points from the same table.


title: What projected coordinate system to use for whole of USA?

text: I need to determine a projected coordinate system for a wide area that exceeds more than one zone? For Example: If I want to give US a UTM projection which zone will be represent the whole US? P.S. GCS is not an option because measuring is not supported with GCS.


title: What are the implications of changing the AutoCommitInterval on file geodatabase inserts?

text: All, I was wondering if anyone has any advice or "tales from the dark side" about changing the AutoCommitInterval property of the ITransactionsOptions interface? It's the sort of thing I generally leave well alone! I am developing some code that populates dictionaries with a lot of information. The dictionary key is an integer and the item is an ArrayList with potentially several thousand entries and I can have many thousands of key/item entries in my dictionary. Ultimately I want to write the lot to a File Geodatabase Table. I was hitting the out of memory exception so a solution was to periodically write the contents of the dictionary to the table, clear out the dictionary and continue in my loop. This works but the process of writing the dictionary data to the table is quite slow (as it's writing millions of rows) and I was looking for ways to improve performance. My code is using an insert cursor with row buffering and I believe that section of code is as optimal as I can get it, so I was looking at the best practice page on the ESRI website when I picked up on the idea of changing the Auto Commit Interval. I've never tinkered around with that before and I was wondering if people had any advice, it looks like I can set that to zero and do the commit right at the end, is this advisable, does it actually improve write performance? Thanks Duncan


title: Is there another way to acces the histogram in ArcGis 10

text: i need the histogram of the frequency to heights distribution like in the attached picture. Is there another toolkit to access this data? A screenshot is not suitable :) The attribute table is not helpful, too. ![Symbology](http://i.stack.imgur.com/sfMgd.jpg)


title: Where is the server.dat equivalent at 10.1?

text: Prior to 10.1, I could locate the **server.dat** file, and programmatically find out the arcgisoutput folder URL location (virtual directory when using IIS) e.g.               <Directory>      <Path>c:\arcgisserver\arcgisoutput</Path>      <URL>http://lap-303689/arcgisoutput</URL>      <Description></Description>      <Type>output</Type>      <Cleaning>sliding</Cleaning>      <MaxFileAge>600</MaxFileAge>     </Directory>      At 10.1, the arcgisserver folder default location is now: _C:\arcgisserver\directories\arcgisoutput_ This is fine, but **how do I find out what URL was set to in the post install?** I understand that there is now an embedded Tomcat within 10.1 (similar to Java edition of AGS), but I am unsure on which file contains the URL info (including the port number). -EDIT-   **Have reopened this Q, as have agreed with FredP that there should be a better approach to get the arcgisserver physical AND virtual paths from ArcObjects.**


title: WMS GetFeatureInfo with No Location

text: I am using Geoserver with OpenLayers. I would like to return all the feature type details in a specific layer exactly as GetFeatureInfo does for a specified location. I tried using GetFeatureInfo with the x and y parameters but it insists on a location being specified. Basically, I need the details of all the feature types in the layer, including the geometry. There may be a better way to do this, however, after hours of searching, I have been unable to find one. Can anyone help? Many thanks, Adam


title: How to measure water ties

text: I was using Arc Gis to measure water ties from the edge of buildings. It was so easy, I just had to click on a circle and it would show the distance on the bottom of the screen. I would measure from another corner and at the intersection of the two circles was where the curb box is. Done. In QGIS, I can not find where or how to do this. Is there a way? It is such a simple concept that eludes me.


title: Why is the OSM map itself is not visible in my qgis window?

text: I'm new in working with QGIS. I have tried to download an OSM map of Rome and its surroundings into my QGIS. As far as I am concerned, I have followed each step which I could find on various websites. In fact I do see the three layers of my OSM map in the side bar (points, polylines and polygons). However, I do not see the map itself. Does anyone have an idea what my mistake might be? In the meantime, I tried another way. I have downloaded the "Isle of Man"-Shapefile from Geofabrik. I was able to import all vectors for all data that are meant to appear in the map. In the end I saw the outline of the Isle of Man, the houses, the rivers etc. However, I do not see the map itself. What did I do wrong? Thank you very much for your support! p.s.: I have a new laptop, 64-bit, Windows 8, QGIS 2.4


title: Making single polygons from a shapefile

text: I created a shape file a while ago with several (20+ polygons) in it. I was wondering if there is a way to symbolize these polygons with unique symbols. Basically all I actually want to do is color them differently from each other, and I don't think I can do this when they are all in one file.


title: Map algebra from files in multiple directories

text: I'm a rookie in python programming. I want to do map algebra for multiple rasters but these rasters are in different folders. Here's the code ive created so far:               #Importing modules     import arcpy     from arcpy import env     from arcpy.sa import *          #Files name     name1 = "BR_CRU_PRE"     name2 = "BR_CRU_ETP"          #Workspace     path = r"C:\Users\Ibytee\Documents\FUNCEME\ParaGiullian\Dados_ArcGIS\PRE_ETP"     env.workspace = path          #Checking for extension     arcpy.CheckOutExtension("Spatial")          #Creating raster lists     folders = ["PRE","ETP"]     env.workspace = path +"\\"+ folders[0]     a = arcpy.ListRasters(name1+"*", "TIF")     env.workspace = path +"\\"+ folders[1]     b = arcpy.ListRasters(name2+"*", "TIF")          #Executing the loop     for p, etp in zip(a, b):          print p          outRaster = Raster(p) - Raster(etp)          outRaster.save(path+"\\PRE_ETP_SUB\\"+"sub_"+name1+"_%s" %etp)          print "sub_"+name1+"_%s" %etp      This script seems to be accessing the right folders and creating the raster list, but when it comes the time to do the map algebra, looks like the script searches the rasters in the wrong folder. Here's the error I get:               C:\Python27\ArcGIS10.1\python.exe C:/Users/Ibytee/Documents/eclipse_workspace/Scripts/teste.py     BR_CRU_PRE_ANO1971.tif     Traceback (most recent call last):       File "C:/Users/Ibytee/Documents/eclipse_workspace/Scripts/teste.py", line 24, in <module>         outRaster = Raster(p) - Raster(etp)     RuntimeError: ERROR 000732: Input Raster: Dataset BR_CRU_PRE_ANO1971.tif does not exist or is not supported          Process finished with exit code 1


title: Changing value field when applying symbology from layer using Python Add-in?

text: I have a python addin button that creates a layer file from a polygon feature class in ArcMap. I want to take that layer file and, with user input from a combobox, apply it back to the feature class using a different value field. For example, I have a feature class called "names" with the following attributes: ![attribute_table](http://i.stack.imgur.com/DPcTI.png) And I want to create a layer file based on the unique values for Name and then use that layer file to display Name_Change1 and Name_Change2 so that my colors remain consistent for each unique value (ex: Finnley is always purple, Dylan is always green). This is possible in ArcMap by importing the symbology from the layer file and changing the value field. However, I need this functionality in a python toolbar. Right now, I am creating separate layers for each field and using those. This works but it requires a lot of set-up in order to use the addin:               if combobox_value == "Name_Change1":         if arcpy.Exists("Name_Change1.lyr"):             arcpy.ApplySymbologyFromLayer_management(names, "Name_Change1.lyr")      But I want it to be something like:               if combobox_value == "Name_Change1"         if arcpy.Exists("Name.lyr"):             #assign/change value field of Name.lyr             arcpy.ApplySymbologyFromLayer_management(names, "Name.lyr")      Where symbology is always pulled from "Name.lyr". I guess I really wish that the ApplySymbologyFromLayer tool had a parameter for the value field, but that doesn't seem to be the case. And I haven't found another tool/method that will allow this. Does anyone have any ideas?


title: Using Engineering symbols (*.svg) in QGIS?

text: QGIS looks straight forward except for the symbols or icons. I have created SVG symbols and when I place my pointer to the obvious blank areas in the symbol library a pop-up says that my symbol is there, yet nothing shows in the icon library. I insert the "ghost" svg into the map and Nothing shows on the map. Can anyone tell me how to get an SVG file to work in QGIS?


title: Finding equivalent API-supported data to the 2000 Census

text: I'm having some difficulty choosing Census datasets for a project that involve various SES measures at the block-group level. I'll be looking at things like median household income and percentage of people over 25 who have gone to college. These measures are available in the 2000 Census _and_ I can use API to load them directly into R (the programming language I'll be using for the whole project). **My question** : What is the equivalent source for these measures that is **more recent than 2000 that work with API?** The 2010 Census is formatted differently from the 2000 Census and doesn't seem to offer API functionality for non-demographic data in the SF2. I've considered the ACS 5-year datasets, but I'm worried it won't be as rigorous as the Decennial Census. Here's the website that has API info for 10-year census. http://www.census.gov/data/developers/data-sets/decennial-census-data.html These are the variables for the ACS5. Helpful, but not ideal. http://api.census.gov/data/2010/acs5/variables.html Thank you so much! Let me know if this is too vague.


title: How to find the POI (points of interest) Within a Given Radius?

text: I have a table with x,y coordinates with the_geom column. Now I need to find the nodes (Points Of Interest) present in a given radius. Kindly help me in knowing how to find it. Thanks.


title: Nested Geometric Functions in SLD in GeoServer

text: I want to use nested geometric functions in SLD of GeoServer. For example I want to set some offset for certain type of polygons in my data. Then output of the offset geometric function needs to be given as input to another geometric function isometric to give required extrusion. I tried with following code. the_geom 0 7   the_geom 7 It gives no validation error but in layer preview, it is throwing the following error: > java.lang.RuntimeException: Unable to find function isometric Unable to find > function isometric Is it possible to use nested function, or I am doing something wrong here? Thanks in Advance.


title: generate height data from DTED maps

text: I have 16 DTED maps of (1 degree x 1 degree). I have to generate combined height matrix of maximum 4 (1 degree x 1 degree) DTED maps in my C++ application. Can someone suggest to me which open source GIS API I should use in Windows 7? Thanks in advance. thanks for your valuable reply, i will try GDAL. I have to analyse radio line of sight for two points for communication, that may lie on two different DTED1 map , but the distance between two points will be maximum 150 to 200 km. and one thing more, i will get two points from another application, and i have to send all height information matrix (rows * column) of that area, that area may be on same or two different DTED 1 maps. I am confused about DTED 1 map, Whether it is raster file or vector file, How GDAL process it, as a raster or as a vector.


title: Need Oracle spatial tutorials

text: I am working on Oracle spatial 11g and I am referring to Oracle docs as a learning resource. Does anyone know any more Oracle Spatial tutorials ? We want to integrate Oracle Spatial data with ArcGIS & QGIS. Any help will be great!! Thanks in advance : )


title: How to convert contours and raster surface from Petrel to shapefiles and rasters that can display in ArcGIS?

text: We have Petrel which is used to produce a surface of a geological horizon below the earth's surface. In Petrel we have contours (vectors) and a raster image of the same area, also visualising elevation of the surface. Has anyone got any experience in ways to convert this vector dataset and raster dataset in Petrel to a format suitable for ArcGIS? A previous employee sent it to Petrosys from Petrel, which could then output shapefiles of the contours and a .BIL raster, which I can display in Arc. This, however, is something no current employee has experience with. FME does not handle the regular Petrel output file types of ![enter image description here](http://i.stack.imgur.com/HZ62y.png)


title: WGS 84 Transformation issues with ArcGIS and Global Mapper

text: I have rasters, need to be geo-referenced in WGS 84 datum with Lat/Log (degree). I have geo-referenced using Global Mapper, which we usually used to use, because of its user friendly. Got a vector data of the same raster through other sources, which also used GCS_WGS 84 (Could have been geo- referenced using ArcGIS with GCS_WGS84). When I overlap both the data, found off-set about 300 meters. Checked all data origins and geo-referencing, everything correct, still off-set unavoidable. To check further, I have geo-referenced same raster with GCS_WGS84 in Global Mapper and ArcGIS seperately. I found the same off-set of 300m. Is that really different transformation applied in difference platforms, or any other parameters related to this??


title: How to create a grid of latitudes and longitudes to be displayed in polygon boundry with ArcMap?

text: I'm looking for some direction on how this can be achieved. I have with me a polygons of a country, state and city in geographic coordinate system. A grid of latitudes and longitudes is to be created to be displayed within the polygons. The interval between the graticule grid lines will vary depending on the extent (country/state/city) for which the grid is to be created. The grid needs to be a shapefile or feature class since a conversion to kml/kmz is later required. Are there any tools in ArcMap that will allow to achieve this? Suggestions to write a python script are also welcome if no out of the box solution exists.


title: How to get layer list of layers that are published?

text: I'm stuck. I've been using geoserver with python extension gsconfig library for a while now. Almost everything works as it should be. While there are little things like publish raster images are problematic, there is still workaround that isn't written into the catalog.py class. But there is this where I have no idea how to get around. How do you get a list of layer resource objects that unpublished? catalog.py provides get_layers and get_resources that return layers that are published but not the unpublished layers in a datastore. I could list all the layers (publish and unpublished) in a datastore through geoserver interface but wms/wfs/wcs and even rest does not The wms/wfs/wcs services can return layer information in xml but still no layers that are unpublished. I could understand why that is in this case since it is publish facing but I don't know why REST services have this problem as well. I have searched a lot of forum with no luck. Did anyone manage to find a solution for this?


title: Using custom shortcut keys in ArcGIS while table of attributes is active window

text: I have a custom button which is made using python add-in. I add this button in arcgis desktop and assign a new short-cut key for this button. The problem is this button should be used while table of attributes is active. But short-cut key only works when main acrmap window is active. Is there any way to assign short-cut keys for custom buttons and make them work while table of attributes is active?


title: Rendering a map in QgsComposition on Win 7 / 8 in QGIS 2.2.0 with QgsComposerMap gives blank map

text: I'm writing a plugin for QGIS 2.2.0 which should render a pdf file with a map and some text. The code is working under Linux (current Arch) and Windows XP, but it's not working on Windows 7 or 8. Output PDF on Win 7/8 has all labels, but no map, only blank space. I don't know if it's relevant, but I want to render only raster layers. The plugin is to be runned from QGIS, so it has access to self.iface variable, but I can also use standalone QgsMapRenderer. What am I missing? Please help me! ;) Here is the code I use:               mapRenderer = self.iface.mapCanvas().mapRenderer()     mapRenderer.setLayerSet(input_map_layers) #list of map layers id's     mapRenderer.setOutputUnits(QgsMapRenderer.Millimeters)     mapRenderer.setOutputSize(QSize(map_width_on_print_mm,      map_height_on_print_mm), 300)     mapRenderer.setExtent(rect)          c = QgsComposition(mapRenderer)     c.setPlotStyle(QgsComposition.Print)     c.setPaperSize(210,297)          composerMap = QgsComposerMap(c, 14.7026,113.85,map_width_on_print_mm,map_height_on_print_mm)     composerMap.setFrameEnabled(True)     composerMap.setFrameOutlineWidth(0.5)     c.addItem(composerMap)          printer = QPrinter()     printer.setOutputFormat(QPrinter.PdfFormat)     printer.setOutputFileName(unicode(input_data_fields['output_pdf_filename']))     printer.setPaperSize(QSizeF(c.paperWidth(), c.paperHeight()),      QPrinter.Millimeter)     printer.setFullPage(True)     printer.setColorMode(QPrinter.Color)     printer.setResolution(c.printResolution())          pdfPainter = QPainter(printer)     paperRectMM = printer.pageRect(QPrinter.Millimeter)     paperRectPixel = printer.pageRect(QPrinter.DevicePixel)     c.render(pdfPainter, paperRectPixel, paperRectMM)     pdfPainter.end()


title: Openlayer seems slow when zooming / panning on vector (geometry line) from geojson. Why?

text: I have a layer with 7 lines . when I zoom on some of the lines , the maps seems to be very slow. I thought it might be because I bring a lot of points to the client (that represents the line)               aa     Line Id     Num of Points As Text     ----------- ------------- ---------------------------     1           9971          MULTILINESTRING ((34.797771     2           13180         MULTILINESTRING ((34.808654     3           5465          LINESTRING (34.94746717 31.     4           5397          LINESTRING (34.94746717 31.     5           9550          MULTILINESTRING ((35.104847     6           3770          LINESTRING (34.94746717 31.     7           3770          LINESTRING (34.94746717 31.      Line 1 and 5 are very slow on the map... They are MultiLineString because I use MakeValid on the geometry from MSSQL. Any Idea why this happens ?


title: Problem with multi-threading and geoprocessor tool in c#

text: **What I am doing:** I am trying to run a geoprocessor tool in a background thread other than UI thread. I am passing `string` path of `arcObjects` and creating that `arcObject` in my background thread. Then I am passing those `arcObjects` to `geoProcessor` tool. In UI thread, Button's on click method:               private void btnFindInterction_Click(object sender, EventArgs e)     {         List<IFeatureLayer> layers = GetAllMapFeatureLayers();              string featureLayerPath1 = GetFeatureLayerPath(layers[0]);         string featureLayerPath2 = GetFeatureLayerPath(layers[1]);              Thread worker = new Thread(new ThreadStart(() =>             {                 IFeatureClass featureClass1 = GetFeatureClassFromPath(featureLayerPath1);                 IFeatureClass featureClass2 = GetFeatureClassFromPath(featureLayerPath2);                      var result = RunIntersectTool(featureClass1, featureClass2);                 OnCalculationComplete(intersectedFeatureClasssPath);             }         ));              worker.SetApartmentState(ApartmentState.STA);         worker.Start();     }      The RunIntersectTool method:               string RunIntersectTool(IFeatureClass featureClass1, IFeatureClass featureClass2)     {         IWorkspace workspace = GetTempGDBWorkspace();         string intersectFeatureClassName = "Intersect_result";         string intersectFeatureClassPath = workspace.PathName + "\\" + intersectFeatureClassName;         try         {             var gp = new Geoprocessor { OverwriteOutput = true, AddOutputsToMap = false };             IGpValueTableObject gpValueTableObject = new GpValueTableObjectClass();             gpValueTableObject.SetColumns(1);             var inFeature1 = imperviousFeatureClass as object;             gpValueTableObject.AddRow(inFeature1);             var inFeature2 = watershedFeatureClass as object;             gpValueTableObject.AddRow(inFeature2);                  var intersectTool = new Intersect             {                 in_features = gpValueTableObject,                 out_feature_class = intersectFeatureClassPath              };             gp.Execute(intersectTool, null);             return intersectFeatureClassPath;         }         catch (Exception e)         {             return null;         }     }      **What problem am I facing:** The tool runs perfectly in some machines, but gives error in some machine: _"000732 : : Dataset does not exist or is not supported"_ And this error never happen if I don't use threading. I read help files of Running a geoprocessing tool using background geoprocessing, but I couldn't find anything that says I can't pass arcObjects. There is another problem I am facing. Whenever I ran the tool, it works fine first time(in some machines), but gives error when it creates an instance of geoprocessor at second time. Error message: _"Attempted to read or write protected memory"_. I guess this error is also related to multithreading and arcObjects.


title: How to cover a number of points with disks?

text: I have to cover some points with disks. These disks are not of a fixed size, they have to constraints:   * a maximum diameter, and    * a maximum number of points covered. I would like to minimize/optimize the number of disks centers.   * A point can be covered by two disks, but counts for only one of them.    * All points should be covered. The maximum number of points would be approx 40 per disk, and points are houses: a distribution based on pockets, lines (along roads) and isolated. It is for a whole country, so approx a million of points.


title: What is the correct cartographic projection to calculate a Voronoi tesselation?

text: I have a set of points with known geographic coordinates. I would like to compute a Voronoi tesselation from these points in order to obtain areas of influence. The geometrical area of each Voronoi cell is then to be used to weight measurements obtained at each point. Albeit area being my main interest, the computation of a Voronoi tesselation is a distance based algorithm. Considering that the set of points of interest cover about 5% of the Earth's surface, distances calculated in a, say, equiareal projection will incur in a relevant error. Conversely, if the option is to compute the Voronoi tesselation with an equidistant projection, the resulting areas will in their turn have relevant imprecisions. The correct thing to do seems to be: calculate the tesselation with an equidistant projection, send the resulting cells back to the geographic domain, then re-project them with an equiareal projection and finally compute the areas. But this seems all too convoluted, would there be an alternative process of calculating such a Voronoi tesselation with precision?


title: Problems with gdal1.8 Java bindings gdal.ReprojectImage, produces no data

text: I have a problem with gdal.ReprojectImage from gdal1.8 Java bindings. When I perform the reprojection, the projected image is totally black. And the origin of the projected image is wrong too. There were no errors popping up at all. The code is the following:                          Dataset in_ds = gdal.Open(inPath, gdalconst.GA_ReadOnly);                Dataset out_ds = in_ds.GetDriver().Create(outPath,in_ds.getRasterXSize(), in_ds.getRasterYSize(), in_ds.getRasterCount());                     try {                        SpatialReference dstRef = new SpatialReference("");                        dstRef.ImportFromEPSG(26919);                             out_ds.SetProjection(dstRef.ExportToWkt());                        out_ds.SetGeoTransform(in_ds.GetGeoTransform());                             if (gdal.ReprojectImage(in_ds, out_ds) == gdalconst.CE_Failure)                                System.out.println("something is wrong");                } finally {                        in_ds.delete();                        out_ds.delete();                }      Does anybody know what's going on here? Thanks a lot.


title: Looking for a Java library for tracking positions, and querying regions

text: I have a deceptively simple requirement to create a software component to record and update some mobile position information, then be able to perform simple queries concerning mobiles in a particular area. When I say 'mobile' think aircraft and ocean-going ships. When I say 'simple queries' think 'Give me a list of all the mobiles in some region' or 'Give me the list of all mobiles within X km of mobile Y'. A simple, yet basically complete API for this component in Java might look like this:               import java.util.List;          public interface MobileTracker {          /** Tell us that this mobile should be tracked. */     public void logonMobile( int mobileId );          /** Tell us that this mobile should no longer be tracked. */     public void logoffMobile( int mobileId );          /** Update the current position of the logged on mobile */     public void updatePosition( int mobileId, double lat, double lng );               /** Finds all of the mobiles in the given region (circular or polygon). */     public List<Integer> getMobilesInRegion( /* Region region */ );          /** Finds all mobiles within radiusKm km of mobileId's current location */     public List<Integer> getMobilesNear( int mobileId, double radiusKm );          }      I'm looking for a Java library that will help me implement this. Preferably one that is not GPL, and doesn't have a million dependencies for a bunch of other functions that I don't need. I don't work in the GIS domain, so as I looked here for help, I find myself in terminology-overload. It _seems_ to me I should be looking for a spatial- database. This data doesn't actually need to be persistent here, so I would prefer something I could embed and run in-memory only. This question looked promising, but after a bit of digging on the HatBox site, I see it uses JTS which uses 2-D math, which I don't _think_ is accurate enough for my needs, as I'm dealing with distances of 100s or 1000s of km (maybe this should be another question). My question comes down to: Am I right in assuming I need a spatial-database, or are there better solutions? Can you make some suggestions?


title: Unable to execute ArcPy module outside of ArcGIS environment

text: I am using ArcGIS for Desktop 10.1 (Arc Info license) and ArcGIS for Server 10.1 and automating few things on server level and getting interesting errors. I am overwriting map service through this script. The scripts works fine in ArcGIS Desktop environment. When I tried to run script outside of ArcGIS i.e cmd, it is getting an error. I tried following things at my end:   1. My environmental variable is set properly   2. I have imported all ArcPy, OS modules & toolbox module.   3. After getting an error service is not overwriting.    4. Researching on my side.   5. Script code works fine in the ArcMap Still getting an error & wondering that it is working greatly in ArcMap but outside of ArcGIS why it is not working? Any help will be great !! thanks in advance : ) Please check complete code and screenshots ![Screenshot 1](http://i.stack.imgur.com/NSDI1.png) ![Screenshot 2](http://i.stack.imgur.com/6ZdQn.png)


title: Is OpenGeo Centos6 Repository Broken : Dashboard Geowebcache... missing

text: Hy, Sorry if my french level of english is not fullfilling the requirements of this post. So here is my question : Is it normal for an installation thanks to the official ressource here that the following packages are missing from the repository http://yum.opengeo.org/suite/v3/centos/6/x86_64/ :               Finished Dependency Resolution     Error: Package: opengeo-suite-3.0.2-1.x86_64 (opengeo)                Requires: opengeo-geowebcache >= 3.0.2     Error: Package: opengeo-suite-3.0.2-1.x86_64 (opengeo)                Requires: opengeo-dashboard >= 3.0.2     Error: Package: opengeo-postgis-gui-3.0.2-1.x86_64 (opengeo)                Requires: postgis-gui     Error: Package: opengeo-suite-3.0.2-1.x86_64 (opengeo)                Requires: opengeo-recipes >= 3.0.2     Error: Package: opengeo-suite-3.0.2-1.x86_64 (opengeo)                Requires: opengeo-geoexplorer >= 3.0.2      What is really strange is that I made a test a week ago and it works. Obviously, the update of the repo done the 17/05 probably broke some dependencies? On the other hand, I made the same test on a Ubuntu with the same official tutorial and It works! So is there any other place where the missing packages could be downloaded for centos6 ? I hope this question will be iant approved ;-) Regards


title: How to access raster NoData value?

text: I am trying to programmatically access the NoData value in a raster dataset as shown in the screenshot. ![enter image description here](http://i.stack.imgur.com/CxA6B.png) Two tools that come to mind to describe raster properties do not seem to be able to describe the NoData value: Describe and Get Raster Properties (Data Management). How can I programmatically access (i.e. `print`) the NoData value of a raster?


title: Selecting an item with the mouse in MapBasic

text: This may seem relatively simple, but I'm pretty confused. I have written a mapbasic tool that does things to the table 'Selection' depending on user choices in a popup menu, but currently you need to use the select too to select an item and then run the program. I was wondering how I'd go about selecting an object with a click then it instantly running the main part of the tool? Thanks, Alan


title: Processing time using ArcGIS Hydrology toolbox tools in standalone Python script vs. ArcCatalog

text: My question is: what might cause the ArcGIS 9.3 Hydrology Toolbox Snap Pour Point and Watershed tools to run _significantly_ slower in a Python script versus manually running the tools in ArcCatalog (both runs using the exact same input data files and specification parameters)?? I'm running this script from the windows command line and an IDE (Komodo) so neither ArcMap or ArcCatalog are open during those runs; I'm using ArcGIS 9.3.1 on a Windows XP machine with 4 GB of RAM and plenty of processor power (a Dell Precision machine); and all input data are local; all data are in the same projection. I have pre-processed Flow Accumulation, Flow Direction, and a Feature Class of water-quality sample sites to be used as pour points, and all datasets are in NAD83 UTM 17N projection. The Flow Accum and Flow Dir data files have spatial extents based on Hydrologic Unit Code (HUC) eight digit boundaries. The script iterates through each record in the sample site feature class, determines which eight digit HUC the point falls in, selects and exports the site record as a new feature class in a scratch geodatabase, and then handles the watershed processing using that exported point feature class. I've stripped out comments and some other calls to a "processing log timestamp" function for reporting tool run times just to focus here on the question at hand and have posted the focus section of the script below. The biggest time sinks based on the processing log reporting are the Snap Pour Point tool and Watershed tool. We're talking on the order of 4+ minutes per site using a subset of all the sites for testing, and then 3-4 minutes for each site with the Watershed tool. However, I can take the same single point feature class and the same flow accumuluation and flow direction rasters that the Python script is using, and run the Snap Pour Point and Watershed tools manually in ArcCatalog in approx 1 minute or less for each site (the resulting watersheds are the same as the watersheds the script produces). Example: one of the sites I manually ran the Snap Pour Point tool in 58 seconds via ArcCatalog, while the Python script executing that tool took 3 minutes 59 seconds for the tool to complete. I then ran the Watershed tool manually for the same site and it took 1 minute 1 second in ArcCatalog, while the Python script executing the Watershed tool took 4 minutes 8 seconds for the tool to complete. I'm using a 50 meter buffer for the Snap Pour Point tool in both the Python script and during my ArcCatalog manual run comparisons. As you can see, CONSIDERABLY slower in the command line Python script. I've tried running this in an IDE (Komodo) and then via the Windows command line...same results with both. I've hit a wall with what I can figure out, so much appreciate any suggestions or insight. thanks, Tom               try:         if hucGdb in gdbFiles:           outScratch = scratch + '\\' + delinSiteID + 'temp'           flowAccum = filePath + '\\' + hucGdb + '\\' + 'FA_' + huc           flowDir = filePath + '\\' + hucGdb + '\\' + 'FD_' + huc                tempEnvironment = gp.extent           gp.extent = flowAccum           clause = '[DELIN_ID] = ' + "'" + delinSiteID + "'"           gp.Select_analysis(delinSites, outScratch, clause)           gp.extent = tempEnvironment                outSnapRaster = snapPoint + '\\' + 'p' + delinSiteID                gp.SnapPourPoint_sa(outScratch, flowAccum, outSnapRaster, tolerance)           gp.extent = tempEnvironment                outSnapFeature = snapPoint + '\\' + 'p' + delinSiteID + '_snap'           gp.RasterToPoint_conversion(outSnapRaster, outSnapFeature, "VALUE")                gp.AddField_management(outSnapFeature, "ORIGINAL_SITE_ID", "TEXT", "#", "#", "20")           gp.CalculateField_management(outSnapFeature, "ORIGINAL_SITE_ID", '"' + realID + '"')                gp.AddField_management(outSnapFeature, "DELIN_ID", "TEXT", "#", "#", "20")            gp.CalculateField_management(outSnapFeature, "DELIN_ID", '"' + delinSiteID + '"')                outWsRaster = scratch + '\\' + delinSiteID           tempEnvironment = gp.extent           gp.extent = flowDir                gp.Watershed_sa(flowDir, outSnapRaster, outWsRaster)           gp.extent = tempEnvironment                outWsFeature = basinOutput + '\\' + delinSiteID                gp.RasterToPolygon_conversion(outWsRaster, outWsFeature, "SIMPLIFY")                gp.AddField_management(outWsFeature, "DELIN_ID", "TEXT", "#", "#", "25")            gp.CalculateField_management(outWsFeature, "DELIN_ID", '"' + delinSiteID + '"')                gp.AddField_management(outWsFeature, "ORIGINAL_SITE_ID", "TEXT", "#", "#", "25")           gp.CalculateField_management(outWsFeature, "ORIGINAL_SITE_ID", '"' + realID + '"')          else:       msg = """Site ID """ + realID + """ does not have a geodatabase of       data, moving onto the next site"""       print msg       logFile.write(msg + '\n')          except:     print "ARCGISSCRIPTING ERROR: " + gp.GetMessages(2)     msg = "ARCGISSCRIPTING ERROR: " + gp.GetMessages(2)     logFile.write(msg + '\n')     print "ERROR: " + ErrorDesc.message     msg = "ERROR: " + ErrorDesc.message     logFile.write(msg + '\n')      ## EDIT Just to see what happens, I set up a new ArcToolbox Toolbox and added my python script as a script that I could run. I have the script running based on argument input from a "configuration" text file that it reads in, so in this fashion I just double click on the script and click "OK" as there are no variables to set. I ran the script via ArcToolBox in ArcCatalog, not ArcMap. **The script ran in 7 minutes 32 seconds** vs. 20+ minutes for my same three test sites (same file formats, everything), about one-third of the total time when running the script as a standalone. Running the script in ArcCatalog definitely shaved off a bunch of time on the Snap Pour Point and Watershed tool runs (everything else was already reasonably fast so not worried about other tools/functions) based on my time stamp (tool started...tool finished) reporting I have built in. SO....it seems that there is something going on (or perhaps in this case not going on) when you run a python script outside of ArcGIS (via command line or an IDE) that incurs considerable overhead on raster-calculation tools like Watershed and Snap Pour Point I don't have any special settings (at least that I recognize/am aware of) in the ArcToolBox environments. As far as I know, these are the defaults (I've never messed with them - see attached screenshot). How would these (or a lack of these defaults) impact such tools - is that the issue? If so, can they be set in standalone python code?? I think this is getting closer.....much appreciate any suggestions ![enter image description here](http://i.stack.imgur.com/4Qcvz.png)


title: How to logout when there is no cookie found?

text: I am using Opengeo Suite and through client SDK I created an application. When I run the application, browser automatically shows the login panel. After entering the username and password, it takes me to my application. But there is no way to logout and it don't even get a cookie called **JSESSIONID**. So I didn't get how to make a logout function for this. It logout or what I don't know, but when I close the broswer and enter the url again in new browser, it ask the password again. If I don't close the browser and just close the tab and try to open the application again, it didn't ask the password. So should I have to ask to close the browser again again to login the application with another user. Your help will be appreciable. Thanks Akhil


title: Can one render maps from OpenLayers?

text: My organization has a web application for displaying global and regional climate data and we're considering improvements to it. Our leading idea is to create an OpenLayers-based application to display climate rasters over base layers like OSM or Google Maps. The map may also include some other application-specific vector layers and a color bar or other legend features describing the data. Near as I can tell, this all seems do-able with OpenLayers. One requirement for the project, though, is to be able to export ( _ideally_ from the web-app) publication quality (more-or-less) maps. A typical use case would be something like this:   1. A user, using the base layer as a guide, navigates to their area of interest   2. The user selects a climate parameter (e.g. mean temp for the 2040s) or set of parameters   3. The user hits the "export" button and then downloads a good quality map which includes all of the elements described in the first paragraph. I haven't been able to find anything in OpenLayers about rendering to an image. Does anyone know whether this is possible? And if not what other approaches for rendering could we take? I would suppose that we would need to pass all of the map parameters (bbox, projection, included layers, etc.) out to some external rendering engine; what open source rendering engines our out there?


title: Trouble getting lat/lons from point layer

text: I am following this post about how to get lat/lon information from a point file, but without success. Does this metadata posted below provide information that changes the prescribed method for getting lat/lon for each point?               In layer spatial reference system units : xMin,yMin 1091130.77,1813891.89 : xMax,yMax 1205198.85,1951669.02     Layer Spatial Reference System:     +proj=tmerc +lat_0=36.66666666666666 +lon_0=-88.33333333333333 +k=0.9999749999999999 +x_0=300000 +y_0=0 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=us-ft +no_defs      I have taken the following steps:   1. Loaded a ESRI shapefile into QGIS with one polygon layer.   2. Extracted nodes to create a point layer. Vector -> Geometry Tools -> Add/Extract Nodes. I clicked the option to create new shapfile, then clicked the option to add shapefile to the current project.   3. Right clicked on new point layer, selected 'Save As', and specified target CRS as ESPG4326, and added GEOMETRY=AS_XY in the layer OGR Creation options. This created point layer 2.    4. Clicked on point layer 2, then ran Vector -> Geometry Tools -> Export/Add Geometry Columns.  I ran this entire process 4 times, once with no layer OGR creation options, and once with the Geometry=AS_XY in the layer OGR creation option. I also varied step 4: once with target CRS 'layer' in step 4, once with CRS 'project' in step 4. I also added a step 5, Right click on point layer 2, then save as CSV file. When complete, I right click on point layer 2, click 'Open Attribute Table', and see new XY columns with numbers that are definitely not lat/lons. Also no lat/lons in the csv file.


title: How to highlight routes using a plugin like ATLAS/EASY PRINT

text: First I'm new to GIS and this forum. Secondly sorry my bad English. I use Atlas to auto generate my maps. Eevery "route" has a coverage. At times the "routes" are too close, so the lines cross and it is impossible to make out a specific "route". I really need some advice on this please. Atlas already jumps from "route" to "route" take the .jpeg images for me. I tried to use EASY PRINT but was unsuccessful. ![example](http://i.stack.imgur.com/zbeEk.jpg) The black is what I get by default. The red is what I would like to show for that "route" with the highlighted "route" name (red added with paint). So, in short words, **when that map gets generated for that "route" it should be highlighted and the rest of the "routes" must stay black.** This needs to be done automatically: I have too many maps to do this manually. I'm sorry if this topic has been covered but I did search and can't find help (probably due to lack of correct search, and poor English). I hope you guys understand and can help me as soon as possible. Thank you !


title: API to build GoogleStreet-like photo maps

text: do you know if Google offers a public API to display pictures in a map as they do with Panoranio? just to be clear, I don't want to use Google Street, or publish my pictures anywhere in the Internet, but just have blue dots as you can see in this map if you drag and drop the orange little guy.


title: How to calculate the scale of map tiles accurately?

text: In web maps, there are two coordinate: wgs84 geographic coordinate and web mercator project coordinate. The displayed scale of a world map is the value at equator, and one 256*256 pic can contain the map in web mercator level 0. So we can calculate the scale like this, 1:(2*pi*6378137)/(256/96*0.0254)= **1:591658710.909131**. But in the similar Esri provided service is **1:591657527.591555**(Esri Ocean Map). So, what's the affect in map display with the tiny difference? And how Esri calculate his scale? ps: I was also confused with the same problem in wgs84.


title: Blank map with a single layer while using map server

text: I am just tying to render a map with single layer using map server and I get a blank output. Below is how the map file looks like MAP               IMAGETYPE   PNG     SIZE    900 900     EXTENT  37.078266 6.747135 68.172030 97.403297     SHAPEPATH   "E:/GIS Data/INDIA/2001_State.shp"     IMAGECOLOR  255 255 255              LAYER             NAME    '2001_STATE'             DATA    '2001_STATE'             STATUS  OFF             TYPE    POLYGON               CLASS             NAME "2001_STATE"             STYLE               COLOR 232 232 232               OUTLINECOLOR  32 32 32             END          END             END      END I have saved this map file as prac1.map The following is the URL I am trying to hit for the above map file http://localhost/cgi- bin/mapserv.exe?map=/ms4w/apps/tutorial/htdocs/prac1.map&mode=map&layer=2001_State&mode=map Any help would be appreciated. Thank You. Senthil


title: Can I drop my own templates into the OTB ExportWebMap Tool?

text: At ArcGIS for Server 10.1, there is a print task installed by default. Looking at the web-help, it states: > The PrintingTools service included with ArcGIS for Server references a > preconfigured folder with 8 map layouts. These include basic designs in the > 8.5 by 11 inches, 11 by 17 inches, A3, and A4 paper sizes in both portrait > and landscape orientations. **If you want to use your own layouts, you can > publish your own service** for printing web maps Despite this advice, I want to confirm if it is possible to include additional templates to this Out The Box service, as opposed to having to publish a separate service. Looking at the Service in REST, I can see these templates.   I also found the corresponding templates under:   `C:\Program Files\ArcGIS\Server\Templates\ExportWebMapTemplates` If I drop a new 10.1 MXD into that folder, and restart the PrintingTools service (which now automatically clears the REST cache at 10.1), it will not pick up this new template. ![enter image description here](http://i.stack.imgur.com/R0t0S.png) **Is there any way to configure the underlying GP service behind Export Web Map to accept new MXDs?** I did notice that if I edit one of these existing templates (e.g. add a North arrow) then these changes flow through.


title: arcsde huge size file upload into Oracle spatial

text: I have 35million records (tomtom multinet) of file gdb file in my desktop machine. I need to upload this file into Oracle spatial as SDO_geometry file. I already tested the connection with small size file gdb file and it is success. Is there any best practice here to upload this huge file (from a desktop machine -windows 7 to oracle ? my env: arcgis desktop 9.3.1 (sp2) and arcsde (arccatalog and arsde are in same machine), oracle 10g (db is in different location). Or, whether i have to upload it as splittted files (5m rows each) into oracle spatial, then doing append in a file through arccatalog. I have default dbtune.sde file, commit interval 1000. Pls. share your experience in this.


title: Labeling stacked polygons with different records

text: I work in Oil and Gas and trying to label leases is a huge pain. In most cases there are multiple polygons of the exact same size and shape stacked on each other with records that represent different lessees. The number of lessees per section is unlimited. How can i label these polys so that they look like the annotation in the picture below. Optimally the labels would be sorted on the date field as well. This label is also an expression containing the Net Acres and the Expiration Date. ![enter image description here](http://i.stack.imgur.com/ftgna.png)


title: How to add FP_WGS_84_IBCAO_Polar_Stereographic projection to QGIS?

text: I have a GeoTiff image that is projected (see below) I would like to add this projection to the list of CRS in QGIS. Can someone help me do this? Thank you very much in advance!!! Francis               PROJCS["FP_WGS_84_IBCAO_Polar_Stereographic",        GEOGCS["FG_WGS_84",           DATUM["FD_WGS_1984",              SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],           PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],           UNIT["degree",0.01745329251994328,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4326"]],        UNIT["meter",1,AUTHORITY["EPSG","9001"]],        PROJECTION["Polar_Stereographic"],        PARAMETER["latitude_of_origin",75],        PARAMETER["central_meridian",0],        PARAMETER["scale_factor",1],        PARAMETER["false_easting",0],        PARAMETER["false_northing",0],        AUTHORITY["EPSG","3996"],        AXIS["X",           UNKNOWN],        AXIS["Y",           UNKNOWN]]


title: Two questions about mapnik

text: I newbie have two newbie questions about Mapnik.   1. Does Mapnik allow generation tiles with float zoom level?   2. I have osm file for my region. I want generate images. Where i can download full xml file for it?


title: Problems building QGIS 1.8.0

text: I am very new to QGIS (and the entire Linux thing). I am trying to build QGIS 1.8 on ubuntu 12.04LTS. I specifically need to use the 1.8 version of QGIS. When running the "make" command, I see the following:               e@pe-ThinkPad-Edge-E320:~/dev/cpp/Quantum-GIS1.8/build-master$ make     -- Quantum GIS version: 1.8.0 Lisboa (10800)     -- Found GRASS: /usr/lib/grass64 (6.4.1)     -- Touch support disabled     -- Found Proj: /usr/lib/libproj.so     -- Found GEOS: /usr/lib/libgeos_c.so     -- Found GDAL: /usr/lib/libgdal1.7.0.so (1.7.3)     -- Found Expat: /usr/lib/i386-linux-gnu/libexpat.so     -- Found Spatialindex: /usr/lib/libspatialindex.so     -- Found Qwt: /usr/local/qwt-5.2.3/lib/libqwt.so (5.2.3)     -- Found Sqlite3: /usr/lib/i386-linux-gnu/libsqlite3.so     -- Found PostgreSQL: /usr/lib/libpq.so     -- Found SpatiaLite: /usr/lib/libspatialite.so     -- Pedantic compiler settings enabled     -- Found Python executable: /usr/local/bin/python     -- Found Python version: 2.7.2     -- Found Python library: /usr/local/lib/libpython2.7.so     -- Found SIP version: 4.15.5     -- Found PyQt4 version: 4.9.1     -- Found GSL: -L/usr/lib -lgsl -lgslcblas -lm     -- Ctest Binary Directory  set to: /home/pe/dev/cpp/Quantum-GIS1.8/build-master/output/bin     -- Configuring done     -- Generating done     -- Build files have been written to: /home/pe/dev/cpp/Quantum-GIS1.8/build-master     [ 89%] Built target version     Scanning dependencies of target qgis_core     [ 89%] Building CXX object src/core/CMakeFiles/qgis_core.dir/qgis.cpp.o     Linking CXX shared library ../../output/lib/libqgis_core.so     [ 89%] Built target qgis_core     Linking CXX shared library ../../output/lib/libqgis_analysis.so     [ 89%] Built target qgis_analysis     Linking CXX shared library ../../../output/lib/libqgis_networkanalysis.so     [ 89%] Built target qgis_networkanalysis     [ 89%] Built target ui     Linking CXX shared library ../../output/lib/libqgis_gui.so     [ 89%] Built target qgis_gui     Linking CXX shared module ../../../output/lib/qgis/plugins/libmemoryprovider.so     [ 89%] Built target memoryprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libogrprovider.so     [ 89%] Built target ogrprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libwmsprovider.so     [ 89%] Built target wmsprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libdelimitedtextprovider.so     [ 89%] Built target delimitedtextprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libosmprovider.so     [ 89%] Built target osmprovider     Linking CXX shared library ../../../../output/lib/qgis/plugins/libqgissqlanyconnection.so     [ 89%] Built target qgissqlanyconnection     Linking CXX shared module ../../../output/lib/qgis/plugins/libsqlanywhereprovider.so     [ 89%] Built target sqlanywhereprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libgdalprovider.so     [ 89%] Built target gdalprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libmssqlprovider.so     [ 89%] Built target mssqlprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libpostgresprovider.so     [ 89%] Built target postgresprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libspatialiteprovider.so     [ 89%] Built target spatialiteprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libgpxprovider.so     [ 89%] Built target gpxprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libwfsprovider.so     [ 89%] Built target wfsprovider     Linking CXX shared library ../../../output/lib/qgis/plugins/libqgisgrass.so     [ 89%] Built target qgisgrass     Linking CXX shared module ../../../output/lib/qgis/plugins/libgrassprovider.so     [ 89%] Built target grassprovider     Linking CXX shared module ../../../output/lib/qgis/plugins/libgrassrasterprovider.so     [ 89%] Built target grassrasterprovider     [ 89%] Built target qgis.d.rast     [ 89%] Built target qgis.g.info     Linking CXX executable ../../output/bin/crssync     [ 89%] Built target crssync     Scanning dependencies of target qgis     [ 89%] Building CXX object src/app/CMakeFiles/qgis.dir/main.cpp.o     Linking CXX executable ../../output/bin/qgis     [ 89%] Built target qgis     Linking CXX executable ../../output/lib/qgis/qgis_help     [ 89%] Built target qgis_help     Linking CXX executable ../../output/bin/qbrowser     [ 89%] Built target qbrowser     Linking CXX shared module ../../../output/lib/qgis/plugins/libdelimitedtextplugin.so     [ 89%] Built target delimitedtextplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libdiagramoverlay.so     [ 89%] Built target diagramoverlay     Linking CXX shared module ../../../output/lib/qgis/plugins/libinterpolationplugin.so     [ 89%] Built target interpolationplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/liboracleplugin.so     [ 89%] Built target oracleplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/librasterterrainplugin.so     [ 89%] Built target rasterterrainplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libcoordinatecaptureplugin.so     [ 89%] Built target coordinatecaptureplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libdxf2shpconverterplugin.so     [ 89%] Built target dxf2shpconverterplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libevis.so     [ 89%] Built target evis     Linking CXX shared module ../../../output/lib/qgis/plugins/libspatialqueryplugin.so     [ 89%] Built target spatialqueryplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libsqlanywhereplugin.so     [ 89%] Built target sqlanywhereplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libroadgraphplugin.so     [ 89%] Built target roadgraphplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libzonalstatisticsplugin.so     [ 89%] Built target zonalstatisticsplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libgeorefplugin.so     [ 89%] Built target georefplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libofflineeditingplugin.so     [ 89%] Built target offlineeditingplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libspitplugin.so     [ 89%] Built target spitplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libgrassplugin.so     [ 89%] Built target grassplugin     [ 89%] Built target qgis.g.browser     Linking CXX shared module ../../../output/lib/qgis/plugins/libgpsimporterplugin.so     [ 89%] Built target gpsimporterplugin     Linking CXX shared module ../../../output/lib/qgis/plugins/libheatmapplugin.so     [ 89%] Built target heatmapplugin     Linking CXX shared library ../../output/lib/libqgispython.so     [ 89%] Built target qgispython     [ 89%] Built target t2tdoc     [ 89%] Built target translations     [ 89%] Built target compile_python_files     Linking CXX shared library ../output/python/qgis/analysis.so     [ 89%] Built target python_module_qgis_analysis     Linking CXX shared library ../output/python/qgis/core.so     [ 89%] Built target python_module_qgis_core     [ 89%] Building CXX object python/CMakeFiles/python_module_qgis_gui.dir/gui/sipguipart2.cpp.o     /home/pe/dev/cpp/Quantum-GIS1.8/python/../src/gui/qgsmapcanvas.h: In member function ‘virtual void sipQgsMapCanvas::connectNotify(const char*)’:     /home/pe/dev/cpp/Quantum-GIS1.8/python/../src/gui/qgsmapcanvas.h:461:10: error: ‘virtual void QgsMapCanvas::connectNotify(const char*)’ is private     /home/pe/dev/cpp/Quantum-GIS1.8/build-master/python/gui/sipguipart2.cpp:9597:39: error: within this context     make[2]: *** [python/CMakeFiles/python_module_qgis_gui.dir/gui/sipguipart2.cpp.o] Error 1     make[1]: *** [python/CMakeFiles/python_module_qgis_gui.dir/all] Error 2     make: *** [all] Error 2      So there seems to be a problem with the QgsMapCanvas, but I really don't know how to solve this. Please see the versions of SIP, PyQt4, Python etc. at the beginning of the quote segment. Any help would be appreciated. Thank you!


title: Vector Layer editing in OpenLayers

text: I can draw a polygon in `OpenLayers` by this code.                       var points = [];                  var point = new OpenLayers.Geometry.Point(0, 0);             point.transform('EPSG:4326', 'EPSG:900913');             points.push(point);                  var point = new OpenLayers.Geometry.Point(0, 30);             point.transform('EPSG:4326', 'EPSG:900913');             points.push(point);                  var point = new OpenLayers.Geometry.Point(30, 30);             point.transform('EPSG:4326', 'EPSG:900913');             points.push(point);                  var point = new OpenLayers.Geometry.Point(30, 0);             point.transform('EPSG:4326', 'EPSG:900913');             points.push(point);                  var ring = new OpenLayers.Geometry.LinearRing(points);             var polygon = new OpenLayers.Geometry.Polygon([ring]);                  // create some attributes for the feature             var attributes = { name: "my name", bar: "foo" };                  var feature = new OpenLayers.Feature.Vector(polygon, attributes);             select.addFeatures([feature]);                  map.addLayer(select);      My map can show this polygon perfectly. Here i did `point.transform` because of matching my map's projection system. Now I want to edit this polygon like `'DragFeature', 'SelectFeature', 'Separator', 'DrawHole', 'ModifyFeature' etc` by `OpenLayers`. How can i do that.


title: Postal codes in shapefile overlapping

text: I downloaded some shapefiles from the Australian Bureau of Statistics (ABS). Its basically showing a bunch of suburbs when I view the shapefile through a GIS tool. The GIS tool that I am using at present is the GRASS 6.4.2 tool. When I extract the polygons of each postal out of the shapefile I noticed that some postal codes overlap with one another. I assume this should not be the case, and the correct display is to make sure the overlapping postal codes exclude on another in areas that they overlap. Is there some tool I can use to make sure that no postal codes overlap one another? Thanks


title: MS SQL Server 2012 to Postgresql

text: How to use MS SQL Server 2012 spatial database in postgresql using foreign data wrapper?


title: QGIS: Line to polygon conversion

text: Currently we are working in a geological project..in which all the Contacts, Linear & some other geological features have to be captured. The thing is most of the features have to be Captured as "Line" and then it has to be converted to "Polygon". So that we don't have to repeat the digitization for features like Contact.... 1) Juz wanna know, is it not at all possible in Qgis to Snap a line with the same line ? like that of in AutoCAD, Mapinfo..?? (Image 1) 2) I've captured a polygon as two separate lines...and when i use "Line to Polygon" (Enclose in the case of Mapinfo)....it actually creates two polygons instead of one single entity. Is it a bug ? (Image 2) I am trying to convince some of colleagues (and the management as well) to switch over to QGIS..atleast in few systems...So i am trying to figure out the available functionalities in QGIS as that of MapInfo. So any sort of feedback will be of great help. ![enter image description here](http://i.stack.imgur.com/SVBES.jpg) ![enter image description here](http://i.stack.imgur.com/jTbgz.jpg) Update: Polygonize command does the trick of converting the two separate lines into one single polygon feature...(Image 2).


title: Why do objects disappear when I zoom on a dynamic map service?

text: I have a dynamic web map service that contains some point objects. When I zoom in and out, some of the point object disappear and reappear randomly. The map service is dynamic, no cache has been created for it. Do you have any hint on what is going on?


title: Generate a pyramid of tiles by 1/2 scaling a higher zoom level

text: Given a set of tiles covering a large area at a particular zoom level (These are online on someone's tile server and will need scraping, but let's assume these are on disk if it's easier. With TMS google style filenames) ... **what is the easiest way to generate, by straightforward scaling down, a pyramid of tiles for lower zoom levels?** No need for reprojecting just 1/2 scaling. I could write my own script to do this. Just stitch together four tiles and scale down the resulting image by half, to give you a single tile at the next zoom level. And repeat. It's almost easy enough for me to go ahead an do this, but I'm guessing it's been done before! What are the best existing tools and established approaches for doing this? It looks like I could use gdal2tiles given a single image file. I could create such a file by tile stitching e.g. with BigMap, but is there a tool (or params) which lets me skip that step? Just to pique your interest in the question, let me tell you the fun thing I'm actually thinking of doing: The TIGER Edited Map is a really neat tool for OpenStreetMap contributors in the U.S., letting them see areas where the data has never been edited since the TIGER import (areas where more contributors are needed) but it's only generated by MapQuest from zoom level 8 and above. ![TIGER edited map at the lowest zoom generated zoom level 8](http://i.stack.imgur.com/Yri3o.png) It would be great (and quite easy hopefully) to generate a more zoomed out overview at zooms 7,6,5,4. We'll be scaling the text of place names too which is a shame, but not really a big worry.


title: Publish relationalship data from arcsde

text: I have feature classes and tables having relationship shored in them.(Feature classes has id as which is primary key in other table ). I want to publish the Feature class as a service on arcgis server 10.1. I want to show the value in place of the id's.what is the best way to do it.


title: ArcGIS 10 Field Calculator doesn't notice selection/Attribute Table problem?

text: I just have an annoying problem with the Field Calculator in ArcGIS 10. I selected specific points of a Shapefile I want to calculate, but FC is always calculating all fields. Unfortunately there is no checkbox in ArcGIS 10 anymore to tell FC to only calculate selected fields. I discovered that it seems to be a problem with the Attribute Table since values can only be changed manually while being in the "Show selected records" mode. Otherwise my edits won't be even recognized (even acutal typed in ones). I tried both activated Editor and not activated Editor for FC. Just a few minutes ago everything worked out fine, now all Shapefiles can't be calculated according to the selection anymore. :/ Anyone an idea what went wrong? I'm not aware of having changed any settings. Restart of ArcMap also doesn't do it.


title: Is there a way to use "Select by Attribute" in QGIS using a python command?

text: is there a way to use the function "Select by Attribute" in QGIS using a python command? In my plugin the user should enter a value via a GUI and this value should be used in a function which selects all features which have this attribute. The column name is fixed in the code, the function should only search for the correct value. In my current solution the function connects QGIS to a postgresql database and runs an SQL statement. This creates a table from the result and the table is visualised as shapefile in QGIS. In principal it would be enought to highlight the features and not to create a new shapefile of the selection. Using the "Select by Attribute" function would also skip the unnecessary database connection. Is there a way to use the function "Select by Attribute" in python so that the features are highlighted? Using the function in QGIS all features that doesn´t match the query are temporary blanked-out that would be ok too. Regards from Hamburg,


title: QGIS Desktop 2.2.0 - program does not start

text: I just installed QGIS 2.2 (I download QGIS Standalone InstalleVersion 2.2 (32 bit)).Installation was successful without any errors. Then I try lunch QGIS Desktop 2.2.0 but the program does not start. ### **Update** In postinstall.log I not found any bugs. I also install Microsoft Visual C++ 2008 Redistributable Package (x86) and clear path (Why is QGIS not launching?)


title: Find max and min values from a table based on two fields

text: I have a geodatabase table with the following fields: County_Name, State_Name, Date_Time, Customers Example               Alameda, CA, 8/1/2014 12AM, 6       Alameda, CA, 8/1/2014 1AM, 1       Alameda, CA, 8/1/2014 2AM, 3       ....      Data for all US counties is in the table. I just want to create a new table that contains the   * county, state, max customers for the day (24 hour period), time of the max customers   * county, state, min customers for the day (24 hour period), time of the min customers Many states have the same county names as other states. Do I need to create a cursor to obtain a list of the unique county and state names first? This will give me a list of the county names but I also need the state names. Thank you!               with arcpy.da.SearchCursor(tablesMerged, ["county_nam"]) as cursor:             print sorted({row[0] for rows in cursor})


title: Make a polygon from intersecting lines in QGIS, using Polygonize or similar?

text: In QGIS, I want to make polygons from a set of intersecting lines. Looking at the screenshot here, I want chop the purple line (it's a closed line, not a polygon) where it crosses the green and blue lines. The result hopefully would be a polygon where I have hatched in red. I have quite a few to do. ![Polygonize problem](http://i.stack.imgur.com/lk7YI.jpg) I have tried the QGIS tool previously called Polygonizer (see An Introduction to the Polygonizer Plug-in), but now called **Polygonize**. This is a tool that, given a layer containing a set of crossing lines arranged essentially like a # symbol, should create a polygon from the enclosed space in the middle. (In QGIS 2.01, Polygonize is in the top menu bar: go to Processing -> Commander, then type "Polygonize" on the command line, select "Processing algorithm: Polygonize" from the list that appears, and press Enter.) At the momemt Polygonize doesn't work properly. Is there another way to do what I want to do? For example, wouldn't it be great if the QGIS 'Split Feature' command was able to work like MapInfo's 'Polyline Split', where you select the polygons to split, then select an already-drawn polyline to split by, and voila. But Split Feature seems not to work that way. * * * UPDATE: Detail of problems with running Polygonize. I have 64-bit QGIS 2.01 installed to Windows 7 from the installer package, QGIS-OSGeo4W-2.0.1-3-Setup-x86_64.exe. The routine processed an output from my shapefile, but did not create a polygon from the region enclosed by intersections between the blue, green and purple lines. (Note: in the actual input file, all these lines are on the same layer; the screenshot just colours them differently for illustrative purposes). What I got instead was a simple conversion of the purple outline to a polygon, as though the program completely ignored the blue and green lines. When I node-edited the closed purple line, to open it so that I had a set of open crossing lines like in the # symbol, and then ran Polygonize again, nothing happened. No crash, but no visible polygon in the output file. When I used Nick Hopton's own Laxton.kml data, I got a crash; see screenshot: ![Laxton data crash](http://i.stack.imgur.com/jppmF.jpg)


title: How to find a nearest line to a point

text: I have a table with many points that need to be associated with street segments to calculate an average value. should I do a relationship for all points to a street segment that is closest. I have dealt with several queries but most is for a specific point with coordinates, I do take care for the whole set of points (61000), similar to the "spatial join" for proximity of ArcGIS **Attributes of the streets** id integer NOT NULL DEFAULT nextval ('calles_osm_gid_seq' :: regclass), objectid integer, osm_id numeric, name character varying (48), Inventory character varying (16), type character varying (16), oneway smallint, bridge smallint, maxspeed smallint, shape_leng numeric, maxvel integer, MinSpd smallint, azimuth numeric, geom geometry (MultiLineString, 4326), **Point attributes** "Latitude"numeric (50,10), "Longitude" numeric (50,10), "Azimuth" integer, "Speed" integer, "Date" timestamp without time zone, "Geometry" geometry (Point, 4326), id_calles integer Any idea?


title: Option to auto refresh map every [n] seconds in CartoDB?

text: Is it possible to make a CartoDB map auto-refresh using the latest data every [n] seconds using the web interface? I am using the SQL API to update with new positions and would like to see them reflected on the map automatically. **Disclaimer:** I am aware of the CartoDB.js library, specifically the refreshTime option for createLayer(). I have successfully created an HTML file following the tutorial to implement the auto-refresh layer. Just wondering if there is an easier way to do this via CartoDB website directly.


title: Populating fields in a Matrix format

text: I am trying to develop an accuracy assessment tool using ArcObjects. As an output I would like to show a matrix with the fields such as road ,land,water etc. I just want to know how can I fetch unique values from the raster value attribute table into a matrix format. ![enter image description here](http://i.stack.imgur.com/XdWgN.jpg) Thank You.


title: How to trigger a second drop-down list when selecting a coded value in ArcGIS?

text: I am making a drop down list inside an attribute table of car makes, but want to have a list of models from the respective maker populate when I select a make. Example: I select Ford in my CAR_MAKE field My CAR_MODEL field would populate with models that Ford makes.


title: Make EPANET model with GHydraulics

text: I´m working with water supplies, and modeling the water system and great part of the data in QGIS. I've found GHydraulics can work with EPANET. But I can't get rid of an error: "202 - Illegal numeric value in function call" when I import the .inp file into EPANET, or when I try to run the system with GHydraulics. It seems the only way to work, is change that "NULL" value to "0.000" in the Minorloss column. But I want that EPANET give me the Minor loss value after running the system. Anyone can help me with this?


title: Metadata and GeoJSON?

text: My agency currently maintains and distributes shapefiles with FGDC XML metadata. We have now converted a lot of shapes to GeoJSON but are concerned that if our developers forget where they got the data, then they will not know who to blame when their node apps break. Is there a GeoJSON metadata specification?


title: Line to Polygon via Polygonizer in QGIS

text: My question is in the same vein as this one. I'm attempting to convert precipitation lines (Precipitación Media Anual) to a polygon for Mexico in `QGIS` using the `Polygonizer` plugin. After running the `Polygonizer` using the `New Method`, it returns the polygon but with a table full of NULL values after clicking `Copy table field from line layer`, the same as this problem. The `Old Method` crashes at around 19% completion. Here's a few related questions to this problem: Is clipping the lines to smaller sizes the easiest option?   _extracting each line class, polygonize, and then union_   Though I'm unfamiliar with GRASS, is there a way to easily do this? **EDIT:** I'm going to see if GRASS or PostGIS will do the trick I'm open to any other ways to do this. Thanks again for all the help!


title: Is there workaround for very slow ArcSDE 10.1 data display

text: I'm suffering from very slow viewing data of and ArcSDE database from an Arcgis engine application, the SDE database is in localhost so there's no network issues. but i still don't know the reasons neither how to solve this problem. i'm working on 64 bit machine with 2 CPU's Xeon 3.4 GHz and 2 Gb of RAM. the database contains 20 feature class, but with the max number of features do not exceed 100 000 in some feature classes, if i wait to view the data i should wait 10 minutes. i tried to compress and rebuild indexes in the database but there's no improvements at all. i tried to view data from ArcMap, i have founded the same problem. Using the performance monitor i remarked some bottlenecks in CPU and network sides. **SDEINTERCEPT details:** i have tried **@travis** advice, so i opened mxd referencing data in sde with Arcmap, then i remarked this part take 7 minutes:               [W 10:34:37.710] Command:      QueryWithInfo     [R 10:34:37.710] Long:         1     [R 10:34:37.710] Query Info:          Num Columns:   1         Columns:       "shape"         SQL_Construct: [1]         Tables:        "gebase.sde.point"         WhereClause:   "type_point_id<3"         Query Type:    4         Num Hints:     0         Num Parameter markers: 0         Logfile:       <null>     [W 10:34:37.718] Long:         0     [W 10:34:37.718] Col_Defines:  [1]         Name                                 Type    Width nDec  NULL?   RowID         -------------------------------- ----------- ----- ---- -------- -----         shape                            SE_SHAPE        0   0      NULL               -------------------------------- ----------- ----- ---- -------- -----     [W 10:34:37.718] Long:         71303299     [W 10:34:37.718] Long:         0     [W 10:34:37.718] CoordRef:         XY False Origin:       -37644800,, -28128500,         XY System Units:       10000,         XY Half SysUnit:       0,00005         XY Round:              0,0001         XY Cluster Tolerance:  0,001         Z  Offset:             -100000,000000         Z  Units:              10000,000000         Z  Half SysUnit:       0,000050000         Z  Round:              0,000100000         Z  Cluster Tolerance:  0,001         Measure Offset:        -100000,000000         Measure Units:         10000,000000         Measure Half SysUnit:  0,000050000         Measure Round:         0,000100000         Measure Cluster Tol:   0,001         Coordinate System ID:  0         Coordinate System:     "PROJCS["Nord_Maroc_Degree",GEOGCS["GCS_Merchich_Degree",DATUM["D_Merchich",SPHEROID["Clarke_1880_IGN",6378249.2,293.46602]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",300000.0],PARAMETER["Central_Meridian",-5.4],PARAMETER["Standard_Parallel_1",33.3],PARAMETER["Scale_Factor",0.999625769],PARAMETER["Latitude_Of_Origin",33.3],UNIT["Meter",1.0]]"         Spatial Reference ID:  102191         Precision              High [64]     ========================================     [W 10:34:37.719] Command:      SetSpatialConstraints     [R 10:34:37.719] Long:         1     [R 10:34:37.719] Short:        2     [R 10:34:37.719] Long:         0     [R 10:34:37.720] Filter Array: [1]         Table:        gebase.sde.point         Column:       shape         SearchMethod: SM_ENVP         Truth:        Must Pass         FilterType:   SE_SHAPE_FILTER               FilterShape:               XY False Origin:       -37644800,, -28128500,               XY System Units:       10000,               XY Half SysUnit:       0,00005               XY Round:              0,0001               XY Cluster Tolerance:  0,001               Z  Offset:             -100000,000000               Z  Units:              10000,000000               Z  Half SysUnit:       0,000050000               Z  Round:              0,000100000               Z  Cluster Tolerance:  0,001               Measure Offset:        -100000,000000               Measure Units:         10000,000000               Measure Half SysUnit:  0,000050000               Measure Round:         0,000100000               Measure Cluster Tol:   0,001               Coordinate System ID:  0               Coordinate System:     "PROJCS["Nord_Maroc_Degree",GEOGCS["GCS_Merchich_Degree",DATUM["D_Merchich",SPHEROID["Clarke_1880_IGN",6378249.2,293.46602]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Lambert_Conformal_Conic"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",300000.0],PARAMETER["Central_Meridian",-5.4],PARAMETER["Standard_Parallel_1",33.3],PARAMETER["Scale_Factor",0.999625769],PARAMETER["Latitude_Of_Origin",33.3],UNIT["Meter",1.0]]"               Spatial Reference ID:  102191               Precision              High [64]               Feature Number:        0               Feature Entity Type:   Area                       Number of Points:      5               Feature Envelope:                 MinX:    328133,48150, MaxX:    384094,63650                 MinY:    133834,78230, MaxY:    159869,12210               Polygon Perimeter:        163990,98960               Polygon Area:          1456911724,87047     ---------------------------------------------------------------     Point          X                Y               2D Distance      ---------------------------------------------------------------         1     328133,48150     133834,78230         2     384094,63650     133834,78230        55961,155         3     384094,63650     159869,12210        26034,340         4     328133,48150     159869,12210        55961,155         5     328133,48150     133834,78230        26034,340          [W 10:34:37.721] Long:         0     ========================================     [W 10:34:37.721] Command:      ExecuteSpatialQuery     [R 10:34:37.721] Long:         1     [W 10:34:37.727] Long:         0     ========================================     [W 10:41:17.554] Command:      NextBuffer     [R 10:41:17.554] Long:         1     [W 10:41:17.554] Long:         0     [R 10:41:17.554] Long:         16416     [W 10:41:17.554] Long:         456     [W 10:41:17.554] Short:        -1     [W 10:41:17.554] Long:         0     [W 10:41:17.554] Long:         0     [W 10:41:17.554] Block:         BufferInfo: [25/16416]  Address@0x26fb0000          BufferInHex:    "02008A850100010000000100140000000C0000000100000082..."      **what could make`ExecuteSpatialQuery` so slow to take 7 minutes ?** I'm available for explanations of the problem. Any help please.


title: How to transfer the attributes of features based on their spatial relationship?

text: I'd like to check if a point feature class is placed on a line feature using python in ArcGIS 10.0. I have created a set of point features and placed them directly on a group of line features at predetermined points using the snap tool. I want to iterate through each point feature, checking if the point feature is coincident with any of the line features. If a result is found then i'd like to extract a field value from the line feature and insert into a field in the attribute table of the corresponding point feature that the line feature is coincident with. Basically i am trying to establish a primary key, foreign key relationship between 2 feature classes but i have so many records in the attribute tables that it would be impossible to do this one by one. I just need some pointers to get going with the python script, the part that i am struggling to conceptualize the most is how to check for spatial coincidence between a point and line feature.


title: Sort a feature table by geographic location

text: Here's in interesting challenge: I need to embed a table in a map layout so that the records in the table are sorted according to their geographic position on the ground. For example, in a north-to-top map, the northern-most feature (points in this case) should be first record, and the southern-most the last. The map composition is in ArcGIS, but I'm willing to use gdal/ogr, qgis, etc. for the table sorting if need be. To expand this question beyond my immediate use case and thereby make it more useful to the community, a robust solution would allow choosing other geographic sorts, such as _west to east_ or _inner to outer_. ![illustration](http://i.stack.imgur.com/kWyui.png)


title: How to convert coordinates in a .csv into another CRS in QGIS

text: How can I convert coordinates which are stored in a csv and in a certain format in a different CRS, i. e. I want to convert GK 3 (EPSG:31467) into WGS 84 (EPSG:4326). I am using QGIS and already tried different methods such as saving a shapefile into another with a different CRS but this did not work out! I hope you can help me! Thanks!


title: Dynamic Map Service with Zoom Slider in arcgis by API for javascript

text: I have ArcGISDynamicMapServiceLayer and I want to show Zoom Slider by API 3.2 for javascript


title: Calculate tree cover over certain area from raster data

text: Last year Hansen et al. published Global Forest Change map as set of raster data available in TIFF format. Basically those are 30-meters resolution satellite images with pixel values ranging from 0 (no forest) to 100 (full forest). I would like to programmatically calculate tree cover area over certain country that has its boundaries described by a shapefile. Since I just started with GIS, would you be so kind and advise me where should I begin? What are the available libraries that could help me? I guess my problem is not new at all, but with my limited knowledge I was unable to find proper resources (or recognise them as such). My preference would be C++ or Python, given that the latter has some high-performance libraries. For starter, I have found this post that describes how to handle it in ArcGIS. However, since I want to process lot of shapefiles (500MB) and raster data is huge in size, using such an approach is not an option.


title: How do you construct a definition query to return only those features in the current month without hard coding the date?

text: I have a feature class containing a date field within a 9.3.1 File Geodatabase. There are "duplicate" features contained within this layer, one feature for each month over the past few months. However, the final dataset may contain dates for the last few **years**.               | Feature 1 | '2012-05-01' |     | Feature 1 | '2012-04-13' |     | Feature 1 | '2012-03-23' |     | Feature 1 | '2011-03-23' |     | Feature 2 | '2012-05-12' |     | Feature 2 | '2012-04-14' |     | Feature 2 | '2012-03-30' |     | Feature 2 | '2011-03-30' |     ... and so on      I want to apply a definition query such that the map will only display features for the current month and year and I do not want to update the definition query each month. I have attempted to use a combination of `date`, `CURRENT_DATE`, `EXTRACT`, and `CONCAT` but without much success. Ultimately I think I need a definition query that looks something like this but with the hard-coded dates removed.               DateField >= date '2012-05-01' AND DateField <= date '2012-05-31'      `CURRENT_DATE` returns the current date and can replace the second component to give:               DateField >= date '2012-05-01' AND DateField <= CURRENT_DATE      However I cannot seem to format the first component such that it always starts at the beginning of the current month. I attempted to format the date string via the `CONCAT` but I am unable to form valid SQL and I am not sure what the error is. Ignoring the `CURRENT_DATE` and `EXTRACT` methods for now gives me this invalid SQL:               DateField >= date CONCAT(CONCAT(CONCAT('2012', '-'), CONCAT('05', '-')), '01')      Ultimately the year and month would be replace by the current year and month using `EXTRACT` and `CURRENT_DATE`. However the "simplified" SQL above fails with a generic "An invalid SQL statement was used." error. I know I am doing something wrong but I am not sure what it is. So, how do you construct a definition query to return only those features in the current month without hard coding the date in ArcMap 9.3.1 in a 9.3.1 File Geodatabase?


title: Adding VBA into a Python script generated by ModelBuilder

text: I have created a model that does a calculate field and have used VBA in the code block. But when I export it to Python, it doesn't work. Here is the VBA code:               new_value = [HDATA_N_LAREF_ACTIVITY_TEXT]      if len(new_value) > 100 then         desc = Left(new_value,100)         desc = Left( desc, InStrRev( desc, " ") - 1) & " " & "..."     end if      When i exported it it came out as this....               # Process: Calculate Field...     gp.CalculateField_management(DWWEB_FINAL, "DESCRIPTION", "desc", "VB", "new_value = [HDATA_N_LAREF_ACTIVITY_TEXT]      if len(new_value) > 100 then         desc = Left(new_value,100)         desc = Left( desc, InStrRev( desc, \" \") - 1) & \" \" & \"...\"     end if     ")      **EXTRA INFO:** I have had a look at a previous script that was created (before I started this role), where within the Python script the VBA code is all on one line and contains "\n", where there is a new line within the code, so it should end up like this:               gp.CalculateField_management(myTempWorkspace + os.sep + "DWWEB_Joined", "DESCRIPTION", "desc","VB","new_value = [HDATA_N_LAREF_ACTIVITY_TEXT]\\nIf len(new_value) > 100 then \\ndesc = Left(new_value,100)\\ndesc = Left( desc, InStrRev( desc, " ") - 1) & " " & ""...""\\nend if\\n\\n\\n")      but in PythonWin it gives me the following error:               >>> Unhandled exception while debugging...     Traceback (most recent call last):       File "D:\ScheduledTasks\Scripts\DES_HYMS_Streetworks_v1.py", line 255, in ?         gp.CalculateField_management(myTempWorkspace + os.sep + "DWWEB_Joined", "DESCRIPTION", "desc","VB","new_value = [HDATA_N_LAREF_ACTIVITY_TEXT]\\nIf len(new_value) > 100 then \\ndesc = Left(new_value,100)\\ndesc = Left( desc, InStrRev( desc, " ") - 1) & " " & ""...""\\nend if\\n\\n\\n")     RuntimeError:      (Microsoft VBScript compilation error) Syntax error     Failed to execute (CalculateField).      But that doesn't run, so what do i have to do to get the code block to work? Thanks


title: Move .SHP from .MXD to gdb

text: > **Possible Duplicate:**   >  How to move SHP to gdb with ArcView license? Let's cut it short, I have numerous mxd with layer coming from .SHP and various servers WMS that I need to move to a gdb. What I want is to open the mxd and run a script that select all .SHP layers in the TOC create a gdb, export the .SHP, and create a new MXD with the new path pointing to gdb. Following is the code I wrote, but I can't have it to select only the .SHP, I tried with describe dataType but they all come out as "FeatureLayer"...need help!               # Import system modules      import arcpy, datetime, os, traceback      from arcpy import env           # Load required toolboxes...      arcpy.AddToolbox("C:\\Program Files (x86)\\ArcGIS\\Desktop10.0\\ArcToolbox\\Toolboxes\\Data Management Tools.tbx")               # Get the active map document      import arcpy.mapping      mxd = arcpy.mapping.MapDocument ("CURRENT")           # List broken links      # arcpy.mapping.ListBrokenDataSources(mxd)           # Set environment settings      ws = "C:\\PARK"      arcpy.env.workspace = ws      print("env.workspace completed successfully")      installdir = arcpy.GetInstallInfo("desktop")           #check GDB exist      gdb_nam = "test.gdb"      gdb_full_path = os.path.join(ws,gdb_nam)      if os.path.exists(gdb_full_path):          arcpy.Delete_management(gdb_full_path)      print("GDB checked")           # Execute CreateFileGDB      arcpy.CreateFileGDB_management(ws, gdb_nam)      print("CreateFileGDB completed successfully")      outWorkspace = gdb_full_path           # Iterate           list = []           for df in arcpy.mapping.ListDataFrames (mxd):          for fc in arcpy.mapping.ListLayers (mxd, "", df):             if (fc.datasetName.endswith(".shp")):                         list.append(fc)      for fc in fclist:          arcpy.FeatureClassToGeodatabase_conversion(fc, gdb_full_path)


title: QGIS 2.2 curved labels - 'maximum angle between curved characters' makes label invisible

text: When labeling a curved line in QGIS 2.2, and setting Placement to 'Curved', the behavior of 'maximum angle between curved characters' is not intuitive, and I haven't been able to find documentation on it. The line I'm trying to label is pretty jagged (it's a hiking trail). If I leave the 'maximum angle' settings both at 20 (default), no label is drawn. If I crank the values up to 45, the label is drawn but it is very jagged just like the trail, and illegible. If I crank the values down to 30, the label disappears again. So, it seems like these values are being interpreted like so: "If any generated character would be more than x degrees rotated from the previous character, then do not draw the label." Whereas I was hoping the values would be used as a sort of filter / smoothing algorithm: "Rotate the characters as needed such that each character's rotation is within x degrees of the adjacent characters' rotations." Can anyone provide a more clear interpretation?


title: Probability of iOS/Android device location accuracy

text: I'm working with Android and iOS apps that report location. Both iOS and Android can derive location from a combination of cell tower triangulation, visible wifi access points, and assisted GPS. The location APIs return a lat/long and an "accuracy" number in meters. In the case of Android the API also tells us whether GPS was used, but iOS does not report the source. What I have not been able to figure out from the Android/iOS documentation is how to read the accuracy number in terms of probability. Some GPS devices return the CEP, which means that there's about 50% probability that the device was within that radius. There are other ways of describing accuracy (e.g. 2DRMS) that provide up to 98% probability. Is there any standard for reporting these accuracy numbers in Android and iOS? Or would the probability of the device being within the accuracy circle vary from one reading to the next?