texts: Modelbuilder: How to use submodel output as input for another tool?

texts:
I have a simple model that adds some new fields to a layer and calculates values for them. I want to then use this updated layer as an input for Clip. Normally I can just connect the output to the Clip tool, but I would like to package the first part as a submodel:

When I add the submodel as a tool, the green output variable doesn't show up. Why?

I tried adding Collect Values to the end of the submodel and then setting the output as a parameter. This makes the output variable show up in the main model, but it cannot be connected to Clip as an input; only a precondition.


texts:
I am desperately looking for solution for one problem. I have one point Shapefile, I need to check if there are any duplicate points nearby (let's say 10 meter).

I am not familiar with ArcObjects, is there any way to do it in Python script.


texts:
I want to add the key property "class: 1"  to my FeatureCollection.

This feature of adding a class / value key is done automatically when you create a FeatureCollection and add a property by using the "Geometry Import" tool in the Earth Engine map area.

var toList_pasto = ee.List([
          pasto_10,
          pasto_11,
          pasto_12,
          pasto_13,
          pasto_15,
          pasto_16,
          pasto_17,
          pasto_20,
          pasto_19,
          pasto_21,
          pasto_18
]);

for (var i = 0; i < 11; i++){
  if (i == 0){
    randomSamples = ee.FeatureCollection.randomPoints(toList_pasto.get(i),500)
  }
  else {
    randomSamples = randomSamples.merge(ee.FeatureCollection.randomPoints(toList_pasto.get(i),500))
  }
}

In my code, I want to do this in the line 28.
Add Property in FeatureCollection


texts: Snapping to sketch' vertices while editing in QGIS?

texts:
I'm trying to digitize buildings in QGIS and encountered a problem:
after digitizing several vertices in a sketch, I want to place my final vertex in accordance with the first one - i.e 'square and finish' (in ArcMap).

Is there a way to snap\refer to a previous sketched vertices in QGIS?

The only solution I found involved creating features and then using its vertices as snapping anchors for precise sketching.


texts: Lat/Long grid array 360x720 for ArcMap raster layer?

texts:
I have two files (global temperature and precipitation), both in a 360x720 grid array (latxlong) in a csv file. I'm trying to add this to ArcMap 10.1 so I can use it in raster format.

I've added the files to tables in ArcMap and then tried to display xy data, but because it is in grid format (row #s are lat, column #s are long) it cannot display these.

How can should I add these files to display, or how can I convert these files to make them easier for ArcMap to digest?


texts: Script for updating certain shapefile records meeting different conditions

texts:
This is my scenario:

List of names in a python list: a[]
A 1000 records shapefile with a column: 'name' (populated)
A second column called 'value'
ArcGIS environment (arcpy)

I want to update the column 'value' (i.e from 0 to 1) for all the shapefile records having a value in the column 'name' matching any of the list.

In terms of efficiency, I don't know which one is the best option:

A) Iterate through the list first; for each value of the list I start running through the shapefile asking for a match and do the update.
Example: for 3 names; 3,000 reading operations on the shapefile.

B) Iterate through the shapefile first; for each record of the shapefile I look for a match on the list by iterating through the list each time.
Example: for 3 names; 1,000 reading operations on the shapefile.

C) Use a dictionary instead, no list. Iterate through the shapefile first, and for each record, ask the dictionary for a value, if any, and do the update.
Example: for 3 names; 1,000 reading operations on the shapefile.


texts:
Please tell me why we use:

max Extent: new Open Layers.Bounds(
        -20037508.34, -20037508.34, 20037508.34, 20037508.34)

when adding Google Maps layer in OpenLayers? i.e. please tell me about this function?
    )


texts: Saving multiple SimpleFeatureCollection in geopackage

texts:
Good day!
Where I can see an example of saving multiple SimpleFeatureCollections (GeoPackage Plugin GeoTools) in geopackage file database?
There are very few examples and training materials on the GeoTools site.


texts: Iterate rows in polygon, use result to select by location

texts:
I'm not overly familiar with iterators but basically I have a polygon with multiple rows. I want to select each row in that polygon feature class and use the selected polygon in a select by location process to highlight the number of points within the polygon.

LatestOutages is my polygon file with about 8 rows in it. April is my points file with about 100 points in it.
I want to use the polygon in each row to find the points it contains and input the count of points in each polygon as an attribute to the original polygon file.

I need to do this every single day and could have 50+ rows in each polygon feature class so it's not feasible to do it manually. Can someone show me the set up in modelbuilder?


texts:
I have been scouring the internet for this solution for some time, as it was easily accomplished in 9.x and I can't seem to find a solution for 10.x.  I would like to know if there is a way to sync up ArcMap and Google Earth Pro view extents, so that if I pan to a location in Arc, it will be reflected in Google Earth.  It would even be useful if I could just click a spot in Arc and those coordinates were panned to in Google Earth.

ArcBruTile has been mentioned to me before, but this no longer allows you to import Google imagery so it is useless for me.

I have also heard of Arc2Earth, but I would prefer an open source solution.

Is there a simple VB or Python solution to get this to work?


texts: Zooming ArcMap to feature using ArcObjects?

texts:
I find a feature by using IFeatureClass.Search then I want to show the feature on the screen.

How can I do that ?

Is there a zoom interface or something else?


texts:
I am trying to import coordinates in QGIS but they only appear as single line in the delimited text file.

What am I doing wrong?


texts: QGIS 2.18 for mac: Processing NameError: global name 'QgsWKBTypes' is not defined

texts:
After installing the latest QGIS version for Mac (2.18.0), geoprocessing tools such as "Difference" and "Symmetrical Difference" are no longer working. Instead, the log window shows the following error message:

  2016-11-14T14:28:43 2   Uncaught error while executing algorithm
              Traceback (most recent call last):
                File "/Applications/QGIS.app/Contents/MacOS/../Resources/python/plugins/processing/core/GeoAlgorithm.py", line 203, in execute
                  self.processAlgorithm(progress)
                File "/Applications/QGIS.app/Contents/MacOS/../Resources/python/plugins/processing/algs/qgis/Difference.py", line 71, in processAlgorithm
                  geomType = QgsWKBTypes.multiType(QGis.fromOldWkbType(layerA.wkbType()))
              NameError: global name 'QgsWKBTypes' is not defined

Does anyone have an idea what the problem might be and how to fix it?


texts:
I have a two different stacks: one for band 4 (RED) and other with band 8 (NIR).
I'm trying to loop the calculation of NDVI in an area of interest using R.

Well, this is the loop that I'm trying to use: First, I'm trying to crop the stacks using a shapefile, then calculate the NDVI of the area of interest and save this to the disk.

for(i in 1){

  b4_crop <- crop(stack_b4[i],AOI_Repro)

  b8_crop <- crop(stack_b8[i],AOI_Repro)

  ndvi <- (b4_crop[i]-b8_crop[i])/(b4_crop[i]-b8_crop[i])

  writeRaster(ndvi,output_name[i])

}

And this the message I get from it:

  Error in (function (classes, fdef, mtable)  :    unable to find an
  inherited method for function ‘crop’ for signature ‘"matrix"’


texts: Creating point at specific distance along line in ArcMap?

texts: I have a road (line) system and would like to place culverts (point) at specific distance along the road. The Construct Points tool creates multiple points spaced out at the users specified interval, but I would like to create a single point at a specified distance. What's the fastest way to do this?


texts: Excluding certain attributes from being labeled in ArcMap?

texts: I am using ArcMap 10.1, and i am labeling a roadway system but would like to exclude certain road labels from being displayed.


texts:
I'm working on an esri silverlight project, where I have a HUGE amount of points (100k +) I'm plotting these points on a graphics layer, where I have a MouseLeftButtonUp event assigned.

On the individual points, when zoomed in, it works beauitfully, but when clicking on the cluster icon, it does not fire the graphics layer's MouseLeftButtonUp event.

How do i capture this event on the cluster Icon?

Thanks!


texts: Limit numbers after the decimal point in TOC

texts: In ArcMap 10.1, on the field tab there is an option to set the number of decimal places. The labels and attribute table both reflect this but not in the table of contents. Is there a way to have the same thing show up in the table of contents?


texts: Debugging ArcPy script to search, get value, compare to field names and sum field values?

texts:
`I am looking to do the following task:

Look at the values in RegID_6k99 field (numerical field).
Select all records where "RegID_6k99 == 0". In this case 6 records should be selected.
For each of the selected records look at the FLABEL field value (String) for each record (6 different FLABELs).
Look at the field names of the feature class (fieldlist).
If any of the field names are equal to the value (string) of the FLABELs then sum the value (numerical) for each of the fields for that row. In this case for one row 6 fields have the same string as the FLABEL so for this row the six values will be summed into the new field (RegIntFlows) for that row.

In this case 6 rows will have a RegIntFlows field value.

Then increment for "RegID_6k99 == 1" and so on until the maximum RegID_6k99 value. All records should have a RegIntFlows value.

I have written some code but it doesn't run and needs modification.

Attached is screendump of feature class and current script.

import arcpy
fieldlist = arcpy.ListFields("C:/Temp/NIData.gdb/fc_f6000_in99Matx") #create list of fields
fc = "C:/Temp/NIData.gdb/fc_f6000_in99Matx" #reference feature class
result = [row[0] for row in arcpy.da.SearchCursor(fc, ("RegID_6k99"))] #search field
unique = set(result)
lengthDict = {}
for uni in unique:
    where = "\"RegID_6k99\" = '%s'" % (uni)
    lengths = [row[0] for row in arcpy.da.SearchCursor(fc, ("FLABEL"), where)]
    for field in fieldlist:
        if field.name.lower() == lengths: #if field name is equal to FLABEL value
            lengthDict[uni] = sum(lengths)
            for each in lengthDict.keys():
                print "%s: %s" % (each, lengthDict[each])
                else #not sure how to finish

import arcpy
> fieldlist = arcpy.ListFields("C:/Temp/NIData.gdb/fc_f6000_in99Matx")
> fc = "C:/Temp/NIData.gdb/fc_f6000_in99Matx"
> rfield = "RegID_6k99"
> nfield = "FLABEL"
> # create an expression with proper delimiters
> expression = arcpy.AddFieldDelimiters(fc, rfield) + "=2"
> # create a search cursor with list comprehension to return a unique set of values based on sql expression
> values = [row[0] for row in arcpy.da.SearchCursor(fc, (rfield, nfield), where_clause=expression)]
> uniqueValues = set(values)
> list = []
> # check if FLABEL value equals field name
> for field in fieldlist:
    if field.name.lower() == values:
        list.append(field)
        RowRegFlows = sum(list)
        row.UpdateRow(row)

>>> ## Attempt to sum the values of the applicable field values

The code works - does what I want - up until the last three lines. I have attempted to do the last part of task in the last three lines but not confident about them. There is no error message (see attached jpg). If the FLABEL value for row is equal to all of the field names then I want to sum the values into a blank field (TotRegFlows) for each row.
Do I need an update cursor as well? Can anyone advise?
Many thanks


texts:
I am working with PostGIS (in CartoDB). I want to find all rows in the database with an area of over 100 square metres. I've been trying this:

SELECT *,
       ST_AREA(the_geom::geography) AS area
FROM mytable
WHERE ST_AREA(the_geom::geography) > 100

but I get an error:

column cartodb_id must appear in the GROUP BY clause
or be used in an aggregate function

Is it possible to do this directly, or do I need to create an intermediate table?


texts: Override/edit/fix WMS individual tile requests using QGIS

texts:
I've added a WMS layer into QGIS but when it then goes to display the map and display the tiles, the request is different to what it should be. Is it possible within the layer properties to "force" certain values?

Background (but this would be valid on other sources) :

I want to add the layers found here:
https://www.walkhighlands.co.uk/maps/map2_32fw.shtml

Using Firefox "Inspect Element" I can see the tile requests are of the form:

https://walkhighlands.uk/geoserver/gwc/service/wms?KEY=&URL=https://walkhighlands.uk&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&STYLES=&FORMAT=image/png&LAYERS=osgb:50k&SRS=EPSG:27700&BBOX=209000,757000,210000,758000&WIDTH=200&HEIGHT=200

I add a new WMS source into QGIS with:

https://walkhighlands.uk/geoserver/gwc/service/wms?KEY=&URL=https://walkhighlands.uk&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetCapabilities

And it picks out the seven available layers. If I then drag and drop the "25k" layer to the layer panel and look at the log, the requests (and server response) are like so:

2018-02-22T10:53:41 1   Map request failed [error:Error downloading https://walkhighlands.uk/geoserver/gwc/service/wms?KEY=&URL=https://walkhighlands.uk&&SERVICE=WMS&VERSION=1.1.1&REQUEST=GetMap&BBOX=0,0,660000,1230000&SRS=EPSG:27700&WIDTH=120&HEIGHT=120&LAYERS=osgb:25k&STYLES=&FORMAT=image/png&FORMAT_OPTIONS=dpi:96&TRANSPARENT=TRUE - server replied: Bad Request

If I cut and paste this into a browser I get:

400: Requested horizontal resolution: 3300.0 , best match: 2500.0 exceeds 10% threshold. Perhaps the client is configured with an incorrect set of scales (resolutions), or the DPI setting is off compared to the one in GWC ?

So QGIS seems to be sending the wrong parameters (tile sizes should be 200x200, I tried setting this (to 200) in the Layer. Add Layer. Add Layer(s) from a WM(T)S Server but it produces this above.

Is there a way to intervene in the QGIS tile requests?


texts:
I am using ArcMap Basic 10.1 SP1 and I'm connected to a permitting database stored in a SQL Server 2008 R2 database.

I am trying to pull the tabular data over into my ArcGIS Desktop Project so that I can do a join with the permit boundary information based on permit numbers.
One of my fields in the SQL Server database is called "DateIssued" and it is of SQL datatype "date" rather than "datetime".    When I drag over my table from my "Database Connections" area of Catalog, all the fields come over except those marked as "Date" and work fine.   The "Date" items are simply not listed as a field.

I tried to get around this by making some SQL views to try to CAST or CONVERT the SQL data to be a datetime or even a varchar, but then when I drag the view over, it gives me the error message that "Warning - Could not add the specified data object to the map. Invalid SQL syntax"   To be honest, I am not sure that ArcGIS 10.1 even supports using the SQL views as I seem to get that message on any views.

Has anyone run into this problem with the SQL "date" data type?     I thought I might generate some temporary tables to do the date to datetime conversion to see if that might work.   I'll post my findings here as well.


texts:
I'm having a bit of trouble finalizing a project I'm working on. When I upload my map to filezilla, my map layer toggle doesn't show up:

before uploaded:

after uploaded:

Does anyone have any idea why that is happening?

adoran93.bol.ucla.edu/final/167finalAD.html


texts: Using Python Subprocess module to import shapefile into postgres

texts:
I am trying to use your mentioned code..but getting an error.

The code used is mentioned below:

import os import subprocess

cmd = 'shp2pgsql -s 4326 E:\Forest\ForestFire\28052018\VNP14IMGTDL_NRT_Global_24h.shp vnp14imgtdl_nrt_global_24h | psql -h localhost -d scripting -U postgres -P postgres -q'

subprocess.call(cmd, shell=True)

The error it reproduces is while running in Python command line :

'shp2pgsql' is not recognized as an internal or external command, operable program or batch file. 255

What can I do?


texts: Get the coordinates of all points having the same given latitude along a line shapefile

texts:
I have a shapefile representing a shoreline and I need to extract the coordinates of the points at a certain latitude (or longitude).

Is there a tool or plugin that could do that ?

Edit: to be more precise, I need to compute/interpolate the intersections where the lines actually crosses the polyline between 2 nodes not just locate the nearest node.


texts: Importing OpenStreetMap (OSM) data into *.gdb using ArcGIS for Desktop?

texts:
Does anyone know what the fastest way to import OpenStreetMap data into an ArcGIS File Geodatabase (*.gdb) is? I'm using ArcGis 10.2.x and I see two options: OpenStreetMap Loader, which handles a *.bz2 input, or the file loader from the OpenStreetMap Editor toolbox, which handles a *.osm input.

I have to import about 100GB of OSM data into a Geodatabase. The data is all data with the 'highway' tag. Even splitting this up into smaller tiles with osmconvert and running these imports in parallel will take many days using the OpenStreetMap Editor file loader. In case it changes the answer, my computer can handle a lot (64GB RAM, nice processor and HDs etc).


texts: User_Agent argument in Nominatim in GeoPy

texts:
I am trying to understand argument in package geopy and Nominatim geocoder.

from geopy.geocoders import Nominatim
geolocator = Nominatim(user_agent="specify_your_app_name_here")

from their documentation.

What User_Agent is and how should I decide what to fill there?


texts:
I used a tool to draw a polyline following specified point objects. A new feature class was automatically created and the new polyline is a row in that table. This data is stored in my personal disk in my PC.

Then I need to import the polyline into an existing feature class in the GDB. "Append" should work fine but there is a problem with the field names. The existing target table has a field "SHAPE.LEN" and my new feature class consisting of the new polyline has a field "Shape_Length".

The Append doesn't work because of this. I tried to create a new field with the same name in the new table but a dot is not an eligible character in a field name (I don't know how it can be in the name of the existing table).

I tried Append in a replica of this database and it worked fine as for some reason in the replica the field name of the existing table matches the name of my new table.

Any ideas how to figure this out? I am using ArcGIS 10.2.1 with a GDB.


texts:
I am using QGIS 1.8.0 on a Windows Home Premium 7 machine.  I have a single band TIFF that is 187 MB in size.  My vector polygon shapefile represents a regular grid of a 147x112 36kmx36km grid cells.  Both files have the same map projection parameters.  I installed the NextGIS ZonalStats plugin, and tried running it.  I have also tried the embedded zonal stats plugin.  Finally, I have tried the following commands in the Python command window:

rasterfile = qgis.utils.iface.mapCanvas().currentLayer().source()
vectorlayer = qgis.utils.iface.mapCanvas().currentLayer()
zonalstats = qgis.analysis.QgsZonalStatistics(vectorlayer,rasterfile)
zonalstats.calculateStatistics(None)

In each case, the system fails to run to completion.  Instead, I get the "Not Responding" error.

Sometimes Windows will ask me to kill the program.  Other times, I have to kill it in the Task Manager.

Any help with this will be greatly appreciated as I am trying to move away from ArcGIS.


texts: Displaying gSSURGO data from a geodatabase

texts: Can someone walk me through the steps necessary to display data from one of the "outer" tables in the geodatabases available through gSSURGO?  For instance, what joins do I need to perform to get saturated hydraulic conductivity (ksat_r in the chorizons table) to show within ArcMap.


texts: Can we request new OpenLayers WMS image for an extent without moving the map?

texts:
Can we request new OpenLayers WMS image for an extent without moving the map center ?

Reading OpenLayers code, OpenLayers move map center to new extent, and THEN do HTTP request to get the image.

Is it possible to instruct the map to HTTP load certain extent and when 'tileloaded' is fired, THEN load new WMS image?

Edit ----------------------

The problem is I need to "tell the map to zoomToExtent" so it gets a new bound.
OpenLayers Map sets its center and zoom first, and then request new map through HTTP.
The map response will be available in 2 seconds, until that time, map view is blank (if new bound is outside current bound).

if( result.zoom ) {

                       var bounds = result.data.map.mapBounds;
                        var x1 = parseFloat( bounds.x1 );
                        var x2 = parseFloat( bounds.x2 );
                        var y1 = parseFloat( bounds.y1 );
                        var y2 = parseFloat( bounds.y2 );

                        map.zoomToExtent([x1, y1, x2, y2]);
                }

What i think i need is fetchWmsBound() below.

     if( result.zoom ) {
                       var bounds = result.data.map.mapBounds;

                        var x1 = parseFloat( bounds.x1 );
                        var x2 = parseFloat( bounds.x2 );
                        var y1 = parseFloat( bounds.y1 );
                        var y2 = parseFloat( bounds.y2 );

                        function wmsLoaded() {
                             map.redraw(true);
                        }

                        //
                        // @param { <Array.number> } bounds,
                        // @param { Function } callback to exec when wms is fetched
                        // fetchWmsBound might trigger a 'fetched' event also

                        map.wmslayer.fetchWmsBound( [x1, y1, x2, y2], wmsLoaded );

                }

Filed at https://github.com/openlayers/openlayers/issues/573


texts:
I am currently developing a project for which I need to make the preliminary design of the electricity distribution network topology for a population. For this I have the location of the consumers (numbers in red) and the Medium Voltage nodes (numbers in blue) (MT). As shown in the following image:

Using the Network Analyst tools, the possible routes between the different points are generated, within a specified radius, from which the following network is obtained:

The following distribution of the MT nodes to the BT nodes is found with the Closest Facility tool of the Network Analyst:

This solution is an approximation, but it presents some errors, such as the one observed between nodes 85 and 3, because the most logical solution would be the one observed in the following image:

I am looking for this solution to be generated automatically or semi-automatically, but that does not require adding a restriction manually like the one shown in the previous image. The problem stems from the fact that the algorithm used by Closest Facility always looks for the least route from the MT node to the consumption (BT) node, but does not consider that it can be reached from an already connected BT node.

Is there a tool or configuration that allows me to perform the procedure outlined?


texts: Why can't I use processing algorithms in a standalone PyQGIS script?

texts:
I want to create a standalone python script using QGIS python API (PYQGIS) for education.
First I create a model and export that model to python script.

original python script from the export :

##=name
##raster=raster
##stat=output html
outputs_QGISRASTERLAYERSTATISTICS_1=processing.runalg('qgis:rasterlayerstatistics', raster,stat)

Next I read this Using PyQGIS in standalone scripts and I tried to follow this tutorial to create my script.

Final script :

import sys
from qgis.core import QgsApplication
from PyQt4.QtGui import QApplication
app = QApplication([])
QgsApplication.setPrefixPath("/usr", True)
QgsApplication.initQgis()

# Prepare processing framework
sys.path.append('/home/username/.qgis2/python')
from processing.core.Processing import Processing
dem='aster.tif'
slope='slope.tif'
aspect='aspect.tif'
outputs_SAGASLOPEASPECTCURVATURE_1=processing.runalg('saga:slopeaspectcurvature', dem,6,1,1,slope,aspect,None,None,None,None,None,None,None,None,None,None)
Processing.initialize()

# Exit applications
QgsApplication.exitQgis()
QApplication.exit()

If I run this script it works fine without error but I don't take some export like aspect and slope (these can't be found?). Any idea why I can't take exports ?

I use Ubuntu and python 2.7 and QGIS 2.18.1.

i try to this script :

import sys
from qgis.core import QgsApplication
sys.path.append('/usr/share/qgis/python/plugins')
import processing
a=processing.alglist()
print a
processing.alghelp("saga:slopeaspectcurvature")

and i take that print any idea why ?

Algorithm not found

but if i use this module in QGIS work fine.


texts: Cannot read lat lon properties from geojson in leaflet

texts:
I have a point layer in geojson format that I am attempting to display as a leaflet heatmap:

$.getJSON("newmap.geojson", function(data) {

           coords = [];

        L.geoJson(data, {
            pointToLayer: function (feature, latlng) {
                return L.circleMarker(latlng);

            },
             onEachFeature: function (feature, layer) {
                coords.push(feature.geometry.coordinates);
            },
            coordsToLatLng: function (coords) {
            return new L.heatLayer(coords);
            }

        }).addTo(map);
        });

The map appears, but I receive an error in the console that reads : Cannot read property 'lat' of null

I have tried to change coords.push(feature.geometry.coordinates); to coords.push([feature.geometry.coordinates[1],feature.geometry.coordinates[0]]); but this produces the same error.

Is there something I am doing wrong in the reading in the geojson file or is there a known workaround ?

EDIT: the first lines of my geojson file, which is a feature collection, look like this:

{
"type": "FeatureCollection",
"crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } },
"features": [
{ "type": "Feature", "properties": { "st_x": 19.952030181884801, "st_y": 50.055513141929701 }, "geometry": { "type": "Point", "coordinates": [ 19.952030181884801, 50.055513141929701 ] } },
{ "type": "Feature", "properties": { "st_x": 18.672015, "st_y": 50.287181666666697 }, "geometry": { "type": "Point", "coordinates": [ 18.672015, 50.287181666666697 ] } },
{ "type": "Feature", "properties": { "st_x": 18.671918333333299, "st_y": 50.28722 }, "geometry": { "type": "Point", "coordinates": [ 18.671918333333299, 50.28722 ] } },


texts: Could NOT find PythonInterp for QGIS 2.18

texts:
I'm trying to build Qgis on windows, and I'm following the instructions provided by Qgis, but I've had problems with the python interpreter already being in cmake-gui.
I think the following error:

  CMake Error at C:/Program
  Files/CMake/share/cmake-3.7/Modules/FindPackageHandleStandardArgs.cmake:138
  (message): Could NOT find PythonInterp: Found unsuitable version
  "1.4", but required is at least "3" (found
  C:/OSGeo4W64/bin/python3.exe) Call Stack (most recent call first):
  C:/Program
  Files/CMake/share/cmake-3.7/Modules/FindPackageHandleStandardArgs.cmake:376
  (_FPHSA_FAILURE_MESSAGE) C:/Program
  Files/CMake/share/cmake-3.7/Modules/FindPythonInterp.cmake:151
  (FIND_PACKAGE_HANDLE_STANDARD_ARGS) CMakeLists.txt:640 (FIND_PACKAGE)

I have been reading and says that it might have other versions installed,
I have uninstalled all versions of python.
But I still see the same, error,
Verify that my executable was not damaged, it is not.

I'm installing everything on the 64-bit version, on a windows 10 machine,
Visual studio 2015, Qt5, and python 3.6

Any idea how to fix it?


texts: How to give custom color to selected map feature using PointSelection command in MapXtreme SDK

texts:
I am developing a GIS web application in Asp.Net using MapXtreme(V8.0)SDK. I have a requirement of highlighting selected feature with cursor. I am able to do that with below code

<cc1:PointSelectionTool ID="PointSelectionTool1" runat="server" MapControlID="MapControl1" ClientCommand="PointSelectionCommand" Command="PointSelection" />

But, by default it is giving red color to selected features.

Is there is anyway to change this color?


texts: Adding values from list into Attribute with UpdateCursor?

texts:
I have a list of values of buildings total height and want to update the corresponding field in the shapefile.

fclass is my shapefile
totalh is the field which i want to update
totaheight is a list with height values for each building in the shapefile (same order)

This is what I am trying:

i = 0

with arcpy.da.UpdateCursor(fclass,"totalh") as updatecursor:

    for row in updatecursor:

        row[i] = total_height[i]
        updatecursor.UpdateRow(row)
        i = i+1

The error:

Traceback (most recent call last):
  File "C:/wspace2/bheights.py", line 45, in <module>
    updatecursor.UpdateRow(row)
AttributeError: 'da.UpdateCursor' object has no attribute 'UpdateRow'


texts: Access geometry.coordinates of sliced vector grid

texts:
I am trying to represent LineString GeoJSON as vector tile layer using Leaflet.VectorGrid.

But i need to do some interactive by clicking on vector tile layer.
but this vector tile layer has came with only properties, and did't came with geometry. So that i need to access coordinates to show elevation profile on chart.

var tileLayer = L.vectorGrid.slicer(geojson, {
      rendererFactory: L.canvas.tile,
      vectorTileLayerStyles: {
        sliced: {
          color: "red",
          weight: 3,
         opacity: 0
                    }
      },
      maxZoom: 22,
  indexMaxZoom: 5,       // max zoom in the initial tile index
      interactive: true,
      getFeatureId: function(feature) {
          return feature.properties["id"]
      }
    }).addTo(map);


texts: Combining new SoilGrids of finer soil depth intervals, to match soil depth of old SoilGrids data

texts:
I have extracted the mean of some of the new SoilGrid soil properties, for my region of interest from GEE (See here for more details) (the "Latest" vs "Snapshot" data). This data is for 0-15cm, 5-15cm and 15-30cm of the soil depths when compared to the old SoilGrids data which provided only one value for 0-30cm. See here for more information.
How do I combine the rasters of the 3 soil depths, say for sand fraction which is defined as "Proportion of sand particles (> 0.05 mm) in the fine earth fraction in g/kg (mapped units)" (as per the second link above), to get one raster representing the soil fraction in 0-30cm depth?
If I should do a weighted average, what weights do I provide? Is this a decision based on my research question? Or can I do a simple mean of all 3 rasters?
All processing is being done in R.


texts:
I'm having a problem on QGIS 3.16.5,
mostly all sub-menus in Project menu, like Save, Save as, Layout Manager, they are blank and unusable.
Google search of this issue showed only other similar problems for Vector menu, but their solution is only for processing menus.
I'm on a new install of Manjaro KDE 21.0.1 and I've tried different version of Qgis. I've never experienced this kind of problem.


texts: Seeking alternative to Collector for ArcGIS for creating new records in Related Table in ArcGIS Online?

texts:
I'm hosting a Web Mapping Application on ArcGIS Online. The design consists of two parts.

A Feature Layer called Project Description which visualizes the location of every Project in my database
A Related Table called Project Milestone which logs milestone updates to the Projects within a table.

The relationship between the two objects results from a one-to-many Relationship Class (One Project Description can have many Milestones). It is the exact same setup as the Hydrants and Inspections layers in this example demonstrating how to set up the ability to create new records in Related Tables by using Collector for ArcGIS.

However, the client which commissioned this Web Mapping Application cannot use Collector for ArcGIS. They are a federal agency and cannot legally require that all of their employees have smartphones.

Is there a good alternative to Collector  for ArcGIS available which allows for creating new records in a related table within ArcGIS Online?


texts: Can i input two layers in data driven pages

texts:
I have created data driven pages with one shapefile, but now i want to input another shapefile.
Is it possible with data driven pages or another way?

Edit:

I want to intersect with DDP, like this in this pic:


texts: How to get point file in 5km Buffer of route generated in pgRouting?

texts: I am using pgRouting to get shortest route. Now I want to get point that comes in buffer of 5km along router. Point is other shapefile. Route is using road shape so any one give me idea for same.


texts: How to increase Compression Memory for ECW Opacity Builder

texts:
I am attempting to build opacity within an ECW file using ECW_Opacity_Builder.exe from APOLLO Essential Utilities 2014, which has worked flawlessly many times before.

When attempting to build opacity within a 107 GB (1.5 TB uncompressed) 3 band ECW the tool returns an error:

  Could not allocate enough memory Max Compression Memory Cache Limit
  2.0 GB is too low, please set above 2.2 GB

Neither of the two GDAL variables seem to make any difference:

ECW_CACHE_MAXMEM=4294967296
ERM_ECWJP2_CACHE_MAXMEM=4294967296

I have tried the obvious:

Max_Compression_Memory_Cache_Limit=4294967296
MaxCompressionMemoryCacheLimit=4294967296

I have searched the registry for any keys containing ECW and Compression to no avail and even in desperation searched the online documentation for any hints to utilities, registry keys or system variables that could help with no success. The method for increasing the size of the cache is not obvious or well documented...

Does anyone know how to increase the Max Compression Memory Cache Limit for this utility?

Note: the size of the image is not the problem, I've done larger images previously, up to 2.2 TB uncompressed.


texts: Setting circle radiuses from GeoJSON in OpenLayers style and style function

texts:
I'm trying to set the radius of points coming from a GeoJSON in OpenLayers. I was successful integrating the style in the style function like in this question. However, for performance reason, I now put the style outside the function to avoid repeating the style creation for each feature. The problem now is that I don't understand how to set the radius in the style with the value retrieved from the style function. I understood there is a style.setImage() function but I don't find examples how to use it for circles. Any hint on the link I'm missing here?
let style = new Style({
  image: new Circle({
    radius: r * (r / 2),
    fill: new Fill({color: 'rgba(0,0,0,0.4)'}),
    stroke: new Stroke({color: 'rgba(0,0,0,0.4)', width: 0.1})
  }),
  text: new Text({
    font: '12px sans-serif',
    fill: new Fill({color: 'rgba(0,0,0,0.8)'}),
    stroke: new Stroke({color: 'rgba(255,255,255,0.8)', width: 3}),
  })
})

let styleFunction = function(feature, resolution) {
  let r = feature.get('radius')
  r = Math.round(r * 10) / 10
  style.getText().setText(r.toString());
  //style.setImage(???????);
  return style
}


texts: How to get mouseposition (openlayers) in decimal degrees?

texts:
I want to display the mouseposition in Degree Decimal rather than in meters.

See my code:

    <script type="text/javascript">
    var map, ia_wms;
    function init(){
        map = new OpenLayers.Map('map', {zoomDuration: 1,projection: 'EPSG:3857'});
    var esr_all = new OpenLayers.Layer.WMS("ESR_Boundary","http://localhost/cgi-bin/mapserv?map=/var/www/mstest/test_sr.map",{'layers':"ESR_outline",'transparent':true,'format':'image/png'}
           ,{
            isBaseLayer: false,opacity: 100
            }
            );
    var mslayer = new OpenLayers.Layer.WMS( "MapServer Layer",
                                          "http://localhost/cgi-bin/mapserv?map=/var/www/osm-demo/mapserver-utils-svn/osm-google_test.map&",
                                          {'layers': "land0 borders0 places0 land1 borders1 places1 land2 borders2 places2 land3 borders3 places3 land4 landuse4 transport_areas4 waterarea4 borders4 places4 land5 landuse5 transport_areas5 waterarea5 roads5 borders5 places5 land6 landuse6 transport_areas6 waterarea6 waterways6 roads6 borders6 places6 land7 landuse7 transport_areas7 waterarea7 waterways7 roads7 borders7 places7 land8 landuse8 transport_areas8 waterarea8 waterways8 railways8 roads8 borders8 places8 land9 landuse9 transport_areas9 waterarea9 waterways9 railways9 roads9 borders9 places9 land10 landuse10 transport_areas10 waterarea10 waterways10 railways10 roads10 aeroways10 borders10 places10 land11 landuse11 transport_areas11 waterarea11 waterways11 railways11 roads11 aeroways11 borders11 places11 land12 landuse12 transport_areas12 waterarea12 waterways12 railways12 roads12 aeroways12 borders12 places12 land13 landuse13 transport_areas13 waterarea13 waterways13 railways13 roads13 aeroways13 borders13 places13 land14 landuse14 transport_areas14 waterarea14 waterways14 railways14 roads14 aeroways14 borders14 places14 land15 landuse15 transport_areas15 waterarea15 waterways15 railways15 roads15 aeroways15 borders15 places15 land16 landuse16 transport_areas16 waterarea16 waterways16 railways16 roads16 aeroways16 borders16 places16 land17 landuse17 transport_areas17 waterarea17 waterways17 railways17 roads17 aeroways17 borders17 places17 land18 landuse18 transport_areas18 waterarea18 waterways18 railways18 roads18 aeroways18 borders18 places18"}
                                           );
    map.addLayers([esr_all, mslayer]);
    map.addControl(new OpenLayers.Control.MousePosition(
    {
                prefix: 'coordinates: ',
                separator: ' | ',
                //numDigits: 2,
                //emptyString: 'Mouse is not over map.'
            })
                );
    map.addControl(new OpenLayers.Control.LayerSwitcher());
    map.zoomToExtent(new OpenLayers.Bounds(69.00,21.00,70.00,22.00));
    map.setCenter(new OpenLayers.LonLat(69.57,21.55).transform(
    new OpenLayers.Projection('EPSG:4326', 'EPSG:3857'),
    map.getProjectionObject()
    ), 14);
    }
</script>

In mapfile I have given:

WEB
IMAGEPATH '/opt/fgs/tmp/ms_tmp/'
IMAGEURL  '/ms_tmp/'
TEMPLATE  '/var/www/mstest/templatesample.html'
    METADATA
        "wms_enable_request"    "*"
        #"ows_enable_request" "*"
        "wms_srs" "EPSG:4326 EPSG:900913 EPSG:3857 EPSG:2154 EPSG:310642901 EPSG:4171 EPSG:310024802 EPSG:310915814 EPSG:310486805 EPSG:310702807 EPSG:310700806 EPSG:310547809 EPSG:310706808 EPSG:310642810 EPSG:310642801 EPSG:310642812 EPSG:310032811 EPSG:310642813 EPSG:2986"
        "labelcache_map_edge_buffer" "-10"
        "wms_title" "osm"
    END
 END

  DEBUG 1
  CONFIG "MS_ERRORFILE" "stderr"
  CONFIG "PROJ_LIB" "/var/www/osm-demo/mapserver-utils-svn"
   PROJECTION
     "init=epsg:900913"
   END

I tried to change the init=epsg to 4326 , But few layers(osm data from postgres db) ended up not drawing.

How to tackle this?


texts:
Turns out json isn't so good at transporting binary data. But with HTML5, XHR2 is now capable of transferring blobs cleanly. I'm looking to transfer binary geometry (to save bandwidth) and decode it on the client.

To no avail, I've scoured the web for a javascript-based WKB (Well-known Binary) to WKT (Well-known Text) function. Before I re-invent the wheel -- is anyone aware of any open-source solutions?


texts: Showing identify results in dijit/tabcontainer in CMV?

texts:
I want to use dijit/Layout/Tabcontainer to show results in identify.js. It can't show the Tabcontainer correctly.

The result of the infowindow is as the link, it seems there is CSS file conflicts.

I only change the "identify.js" file of the original one. The code of my changed part is as below.

    identifyCallback: function (identifiedlayers, responseArray) {
        var fSet = [];
        array.forEach(responseArray, function (response, i) {
             console.log("valve Chamber");
            var ref = identifiedlayers[i].ref;
            array.forEach(response, function (result) {
                result.feature.geometry.spatialReference = this.map.spatialReference; //temp workaround for ags identify bug. remove when fixed.
                if (result.feature.infoTemplate === undefined) {
                  //***************I change this part start **************//
                  //  var infoTemplate = this.getInfoTemplate(ref, null, result);
                    var infoTemplate=new InfoTemplate();
                    var tc = new TabContainer({ style: "width:300px;height:300px;"

                    }, domConstruct.create("div"));
                    // Display attribute information.
                    var cp1 = new ContentPane({
                        title: "tab1",
                        content: "substation"
                    });                        // Display a dojo pie chart for the male
                    var cp2 = new ContentPane({
                        title: "tab2"
                    });
                    var cp3=new ContentPane({
                        title: "tab3"
                    });
                    tc.addChild(cp1);
                    tc.addChild(cp2);
                    tc.addChild(cp3);
                    infoTemplate.setContent(tc.domNode);

             //***********I change this part End *************//
                    if (infoTemplate) {
                        result.feature.setInfoTemplate(infoTemplate);
                    } else {
                        return;
                    }
                }
                fSet.push(result.feature);
            }, this);
        }, this);
        this.map.infoWindow.setFeatures(fSet);
    },


texts:
I need to add an ID field to a shapefile with 16,171,000 points (yes, a lot of points).

I try with QGIS' field calculator using $id and $rownumbut this is my fifth day waiting for some results.

How can I do this faster?


texts: Preventing GDAL-dissolve from ignoring attribute encoding?

texts:
Given a huge shapefile which needs desolving by one attribute field to reduce redundancy. The GDAL dissolve functionality does that quite swiftly but the output attributes change the encoding so äöü become to unusable ?squares.

What i've tried so far:

Adding a hugeshpfile.cpg that additionaly declares UTF-8: ?squares
Doing the detour via Postgis: same result
The native QGIS dissolve function freezes no matter if shapefile or postgis
Doing it via SQL query in pgadmin results in a different error messages.

While trying around i didn't encounter a possibility to influence the encoding. How can that be achieved or am i missing out on some format constraints?


texts: Is there any magazine (or some other such place) where university students can publish a GIS/Geo related article freely (in English or French)?


texts: UpdateCursor: Invalid input value for setting

texts:
I have a field called "CODE_12" in which the values are strings (3 characters). I have another empty field called "AE" and that I want to fill depending on the value on the "CODE_12" field. For example, when the CODE_12 field is equal to 112 I want the AE field to have a value of 396. I have tried using the UpdateCursor but I'm getting the error "Invalid input value for setting". Any idea of what I´m doing wrong? I attache my code

rows = arcpy.UpdateCursor(RainLandUnion) # This is my feature layer
for row in rows:
         if row.getValue("CODE_12") == "112":
            row.setValue("AE", 396.71)
         elif row.getValue("CODE_12") == "221":
                 row.setValue("AE",435.920)
         elif row.getValue("CODE_12") == "321":
             row.setValue=("AE", 438.2)
         elif row.getValue("CODE_12") == "242":
             row.setValue= ("AE",425.45)
         elif row.getValue("CODE_12") == "243":
             row.setValue= ("AE",425.45)
         elif row.getValue("CODE_12") == "324":
             row.setValue=("AE",441.64)
         elif row.getValue("CODE_12") == "313":
             row.setValue= ("AE",441.64)
         rows.updateRow(row)

The full error message is :

  Message   File Name   Line    Position     Traceback
        C:\Users\Administrator\Desktop\Nuenna\nuenna shapes\model_sample\ae_calc.py 51
      setattr   C:\Program Files (x86)\ArcGIS\Desktop10.3\ArcPy\arcpy\arcobjects_base.py   35
  exceptions.ValueError: Row: Invalid input value for setting


texts: Unable to find 'coordinates' in GeoJSON string error when creating controller API

texts:
I am trying to create an API to insert Geojson data into Postgres/PostGIS and I am getting the below error message when I try to make a post. Is there anything obvious that stands out where I could be going wrong?
Could this be something to do with installing PostGis incorrectly?
{
    "message": "The 'coordinates' in GeoJSON are not an array"
}

geojson POST in Postman
{
    "diveSchoolName": "Raja Ampat Dive Center",
    "diveSchoolLocation": "Raja Ampat, Indonesia",
    "diveRegionID": 5,
    "certificatesID": 1,
    "diveSpotID": 7,
    "diveSchoolGeo": {
      "type": "Feature",
        "geometry": {
            "type": "Point",
            "coordinates": [-0.2333324, 130.5166646]
        }
    }
}

controller API
exports.createDiveSchool = async (req, res) => {

        diveSchool.create({
            diveSchoolName: req.body.diveSchoolName,
            diveSchoolLocation: req.body.diveSchoolLocation,
            diveRegionID: req.body.diveRegionID,
            certificatesID: req.body.certificatesID,
            diveSpotID: req.body.diveSpotID,
            diveSchoolGeo: {type: "Point", coordinates: req.body.diveSchoolGeo},
        })
            .then((diveSchool) => {
                res.status(200).json({
                    statusCode: 200,
                    success: true,
                    message: "Success",
                    diveSchool: diveSchool
                });
            })
                .catch((err) => {
                    res.status(500).send({ message: err.message });
                });
        };

diveSchool model
diveSpotID: {
            type: Sequelize.INTEGER
        },
        diveSchoolGeo: {
            type: Sequelize.GEOMETRY('POINT'),
            allowNull: false
        },
        userID: {
            type: Sequelize.INTEGER,
        }},
        {


texts:
My OpenLayers/MapFish print tool fails approximately half the time when attempting to print WMS with some vectors, and always fails when trying to print WFS layers.

After the OL map first loads I can successfully print the map page to a pdf with base layers and WMS layers. I also have some vector layers in the map for users to dynamically create points, lines, and polygons in. Sometimes I can add features to one or two of the drawing layers and successfully print other times I can draw in one of the layers and it will fail. If I attempt to print the same map more than three times the pdf generation fails. Also, if I try to print any maps with WFS layers the print fails.

When using Google Chrome I get an ERR_EMPTY_RESPONSE page after the print fails, but the console does not show any errors other than the empty response.

In FireFox I get a "The Connection Was Reset" page when the print fails and FireBug doesn't show any anything. Literally nothing. No errors or messages at all.

I am using the following GeoExt code to generate the print;

// The PrintProvider that connects us to the print service
var printProvider = new GeoExt.data.PrintProvider({
    method: "GET", // "POST" recommended for production use
    capabilities: printCapabilities,
    customParams: {
        mapTitle: "This is a map!",
        comment: "This is a comment!",
        defScale: newScale
    }
});

printPage = new GeoExt.data.PrintPage ({
    printProvider: printProvider
});

printPage.fit(mapPanel, true);
printProvider.print(mapPanel, printPage)

I am using GeoServer v2.8.1 with the GeoServer Printing-Plugin v2.8.1, Openlayers v2.12, Ext v3.4, and GeoExt v1.1.

Any suggestions on why the print fails?


texts: Compare Specific Points of Line Features in two Feature Classes using FeatureClassToNumPyArray

texts:
I am looking to compare the first and last point between features in two different feature classes.  The features share a common ID.  My thought was to create two arrays via FeatureClassToNumPyArray.  Then combined them.  There is some magic in FeatureClassToNumPyArray where you can use tokens to pull out different geometry parts, but there isnt a token for first or last point.  Dan Patterson offers some context, but doesnt address pulling out specific points from a line geometry.

You use the  ‘explode to points’ parameter and get the individual points, but only as additional rows and I don’t know if the point order (to determine first and last) is maintained, particularly if I was to pivot the table to it all in one row.

Here is the outline of the final array (or dictionary or list of list etc.) be based on:

[ID,FX1, FY1, FX2, FY2, LX1, LY1, LX2, LY2, DFX, DFY, DLX, DLY]

where F is first point, L is last point, 1&2 are the two feature classes, XY are the coordinates, D is the delta between the two.

The only other way I know to do this is using nested searchcursors and loops to loop through each feature while cracking option the geometry and comparing.


texts: Getting row, col on click of a pixel on a QGIS map

texts:
I want to get the row, col coordinates of a raster I'm viewing in QGIS by clicking on a pixel. I found Displaying row/column of point in raster using QGIS?, which presumably provides hints about how to go about this. However, I am unable to implement it successfully.

I think the appropriate route is to use the QGIS Python console--I don't care where or how the row, col coordinates are displayed as long as I can see it update as I click different pixels. I have been trying a variety of things all day, but haven't made much progress. My plan was to use the above-provided code, but I am having trouble getting QGIS to return the coordinates from a map-clicked pixel.

For example, I tried implementing the code at Getting coordinates by clicking on QGIS Canvas with PyQGIS?, but I am not even sure how to run it. I saved it as a separate py file, imported it in the QGIS console, but I am not sure how to run vector_selectbypoint from within the python console as it is a class.

Does anyone have any tips for how I should be approaching this?


texts: How to write BIGTIFF raster files with rasterio

texts:
A few months ago I had a hard time in finding a way to read BIGTIFF files. In the end I only managed to do so  by creating a new conda environment with the following options:

conda create -n env_name -c conda-forge gdal vs2015_runtime=14

I must admit I have no idea what that instruction does (vs2015_runtime=14???), but it did the job. Now I am simply trying to merge a number of tif tiles into one unique tif raster file. I am using the code below:

...
...

#Merge tiles
mosaic, out_trans = merge(tiles)

#Update metadata
out_meta.update({"driver": "GTiff",
                 "height": mosaic.shape[1],
                 "width": mosaic.shape[2],
                 "nodata": -1,
                 "transform": out_trans,
                 "compress": 'lzw'
                })

#Output path
out_path = '...'

#Build mosaic
with rasterio.open(out_path, "w", **out_meta) as dest:
    dest.write(mosaic)
dest.close()

This code has actually worked fine on other occasions when trying to merge tif tiles, but this time it's giving me the following error messages:

ERROR 1: .\GB_OUTPUT\ALR\GB_COMBINED_ALR.tif, band 1: An error occurred while writing a dirty block from FlushCache
ERROR 1: TIFFAppendToStrip:Maximum TIFF file size exceeded. Use BIGTIFF=YES creation option.
ERROR 1: TIFFAppendToStrip:Maximum TIFF file size exceeded. Use BIGTIFF=YES creation option.
ERROR 1: TIFFAppendToStrip:Maximum TIFF file size exceeded. Use BIGTIFF=YES creation option.
ERROR 1: TIFFAppendToStrip:Maximum TIFF file size exceeded. Use BIGTIFF=YES creation option.

There are 2 errors there. One BIGTIFF related, and another one about some dirty block. Any idea why I can't create BIGTIFF files and how can I overcome the issue? Does the dirty block just mean there's a corrupt tif tile?


texts: OpenLayers + Geoserver: how to dynamically retrieve the "geometryName" of a feature layer in GeoServer

texts:
I am trying to get the list of feature layers on GeoServer and then user can add layers into map at anytime they want. my question is:
when using OpenLayers.Protocol.WFS loading a layer, is "geometryName" required?

since from the response of "WFSGetCapabilities" request to Geoserver, for each featureType, there are only "name, title, srsName, and featureNS". If “geometryName” is required, I have to retrive this from "DescribeFeatureType" request by enumerating the feature's properties . however, these two requests are asynchronous, I am not sure how to load this layer without user's interaction input.

anybody helps? appreciated!!


texts: Legal issues with tracing a map from an image

texts:
Client "A" provided a paper copy map of certain routes.
The owner of the map (map creator) wants to sell the SHP file
Looking at the map, I figure it'll take me an hour tops to digitize the thing

Are there any legal issues with me doing that?

EDIT - ADITIONAL INFO

The map is very similar to a TSP solution. So all i have to do is draw or linear reference the same routes as the map.


texts: Creating multi-country Google Maps API Polygon?

texts:
I'm working on an embedded interactive map using the Google Maps API. I need to show several "regions" that each contain some neighboring countries. For instance one of the regions is the countries of Afghanistan, Bahrain, Egypt, Iran, Iraq, Jordan, Kazakhstan, Kuwait, Kyrgyzstan, Lebanon, Oman, Pakistan, Qatar, Saudi Arabia, Syria, Tajikistan, Turkmenistan, United Arab Emirates, Uzbekistan and Yemen. I need a Google Maps Polygon (https://developers.google.com/maps/documentation/javascript/examples/polygon-simple) that covers that combined area at the national borders.

Is there any way to export the coordinates for a polygon that is made up of the outermost perimeter of a collection of countries? I have just been downloading the individual countries from https://gadm.org/, converting the data to .kml files and trying to manually copy in the right coordinates but it's obviously very tedious.

This is my first Google Maps API project on this scale and I'm in a bit over my head. I've created custom and stylized embedded Google Maps on a city scale before.


texts: Problem with parseWKT : projection mercator-2SP

texts:
1 -CoordinateReferenceSystem crss =

CRS.parseWKT("PROJCS[\"Mercator\",GEOGCS[\"WGS 84\",DATUM[\"WGS_1984\","
            + "SPHEROID[\"WGS 84\",6378137,298.257223563,AUTHORITY[\"EPSG\",\"7030\"]],"
            + "TOWGS84[0,0,0,0,0,0,0],AUTHORITY[\"EPSG\",\"6326\"]],PRIMEM[\"Greenwich\",0,AUTHORITY[\"EPSG\",\"8901\"]],UNIT[\"degree\",0.0174532925199433,AUTHORITY[\"EPSG\",\"9108\"]],AUTHORITY[\"EPSG\",\"4326\"]],"
            + "PROJECTION[\"Mercator_2SP\"],PARAMETER[\"standard_parallel_1\",-33.5],PARAMETER[\"central_meridian\",0],PARAMETER[\"false_easting\",0],PARAMETER[\"false_northing\",0],UNIT[\"Meter\",1]]");

2 - the result is:

PROJCS["unnamed",
  GEOGCS["WGS 84",
    DATUM["WGS_1984",
      SPHEROID["WGS 84", 6378137.0, 298.257223563, AUTHORITY["EPSG","7030"]],
      TOWGS84[0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0],
      AUTHORITY["EPSG","6326"]],
    PRIMEM["Greenwich", 0.0, AUTHORITY["EPSG","8901"]],
    UNIT["degree", 0.017453292519943295],
    AXIS["Longitude", EAST],
    AXIS["Latitude", NORTH],
    AUTHORITY["EPSG","4326"]],
  PROJECTION["Mercator_2SP"],
  PARAMETER["standard_parallel_1", 33.5],
  PARAMETER["latitude_of_origin", 0.0],
  PARAMETER["central_meridian", 0.0],
  PARAMETER["false_easting", 0.0],
  PARAMETER["false_northing", 0.0],
  UNIT["m", 1.0],
  AXIS["x", EAST],
  AXIS["y", NORTH]]

The problem is that the standard_parallel_1 has changed of sign; before negative after positive.
I don't understand. Could you help me?


texts:
I present the following situation.

1 - Draw polygon shape in QGIS 3.4 / geopackage, only with two columns ID and NUM_SETOR, using the google maps image as reference.

2 - Excel table where I combine a series of parameters, making use of formulas, dropdown list and free text. At the end I import this table into the QGIS.

3 - Make a JOIN between graphical feature (1) and table (2), having as a connection the columns NUM_SETOR.

4 - Export to a new shape.

I am trying to end using Excel and its formulas, making use of only the QGIS, for example, of the commands within the properties of the layer, attributes form -> Value Relation, Value Map, Data / time, etc. , creation of virtual fields for the concatenation of other fields, etc.

The problem is that everything is linked to the project and the layers being viewed. If I create a new project and connect to the same geopackage database, I will not have anything that I intend to do.

Is this the best way? Any suggestion? Can I reproduce all excel results in QGIS?
I will try submit an example of the excel table.


texts:
i know to you my question sounds ridicoulus ... but i ask anyway ;-)

i want to populate a field with a new value.

If the field has a value of 1 it should get the new value of 15. If the field is 0 it should stay 0

So i tried ->

if !Field!=1:
  return 15

That didn' work.
I don't know if  Show Codeblock should be activated (and if so what to put in there).

(left part is from the calculate field window and the right part from field calculator windwo)


texts: How does GIS intervene in ports and coastal areas?

texts:
I guess my question is pretty clear and yet broad, but what I was kind of hoping for is some insight on how GIS would be helpful in managing the ports or coastal areas. I can imagine it could serve monitoring the environnement surrounding the port, it could for example use satellite imagery for exploring the bathymetry of the coasts, etc.

So, how does GIS and marine geographical information rhyme ?

P.S : would be great if every poster used her/his answer for one application.


texts: Increasing width of Reader on FME Desktop?

texts:
I have a reader whose attribute names are so long that I can´t read them in the workbench.

Is there anyway to increase the size of the reader element?

With the mouseover the attributes can be read, but I need to scan them visually quickly.


texts: Import only selected features from different layers into print composer?

texts: I want to make a printable map in the print composer that only contains the selected polygons from different layers. Is that possible and if so how do I do it? The marked features on the picture below consists of three different layers, and i want to avoid the other polygons that are not marked. I am using QGIS 2.8.2


texts: Mapping same feature class with map per data field (graduated symbols, customizable break values)?

texts:
I am trying to automate a mapping effort:  I am mapping a (FC) features class ( with multiple data fields representing different results).
I need to visualize each data field  (from the same FC) using similar graduated color symbology (~ 5 classes) with specific brake values  for each data field. Save the layer, save the mxd, export a PDF.

How do I set up a Library for each data field (break values for symbology classes), iterating  through the data fields (field 1, field2, ….field36), updating layer symbology, save layer, save mxd, export PDF. I am using 3 data frames, each maps same FC with an definition query.


texts: Restarting the count of runs in rasterbrick in R

texts:
I got myself a rasterstack with 6300 layers - which represent 70 winterseasons since 1950 till 2019 (70x90 days). Values range from 0.5 to 1.5 and I am looking for amount of runs of at least 5 days with value greater than 1 (for every grid point). So the output is a rasterlayer and value at every grid point gives me the amount of these runs. I am doing so using this function and it works well:
 ff<-function(x){
 y<-x > 1
 n<- ave(y,cumsum(y == 0), FUN = cumsum)
 sum(n >= 5)
 }
 Y<-calc(xxx,ff)

However, there is a problem. I dont want runs that overlap between seasons to be detected. It means, that if a run begins on 88th day of a season and ends on 5th day of the following season, it is still detected as run according to my function, because after layer 28.2., 1.12. follows, but those are distinct seasons. So I wanna somehow restart the calculations on those runs every 90 days. I thought about some indices, maybe something like:
 indices<-rep(1:70,each=90)
 x1<-stackApply(x, indices, fun = ff)

but it doesnt work.


texts: ArcMap: compare overlapping partially transparent rasters using swipe tool?

texts:
I'd like two compare two rasters in ArcMap 10.4. I can do this using the Swipe tool on the Effects toolbar, however, this only allows me to interactively drag the top layer over the bottom one (top and bottom referring to their order in the table of contents). Since my NoData cells are transparent and their location differs between the rasters, the bottom layer 'shines through' the top layer which makes comparison difficult.

I can solve the issue by setting the NoData-value in both rasters to a non-transparent colour that contrasts with the colour scale, but I'd rather keep it transparent.

Another option would be to use different colour scales for each raster to spot where the bottom one shines through, however, I find using the same colour scales better for honest comparison.

When using swipe (or a similar tool) I would like to show the top layer instead of the bottom layer, rather than showing it on top. Does anybody know whether this is a possibility? Is there a way I can select both layers and use 'swipe' to show either of them, but never both?


texts: Selecting features in feature class and updating feature class fields based on Spatial Selection?

texts:
Using ArcPy, is there any way to update the selected records of a feature class' field based on a Selection by Location of another shapefile?

In other words, update a field in a feature class' point based on which polygon it falls into. Of course, this would draw field information from the shapefile that is being used for selection.


texts: I want to show items and labels in the legend only for those features shown on map. I hid some of them with a query definition in layer properties, but they're still visible in the legend. I know that converting the legend to graphic I can manage manually each item, thus delete those I don't want, but I would like to put only the correct items automatically in order to have them disposed in a specific number of columns without needing to move the items one by one. I didn't find any way in legend properties to exclude those items. Any idea?


texts: How to create a custom Tile-Map with its own extent in OpenLayers 3?

texts:
I am a newbie to Openlayers and currently dealing with a problem in setting up a custom tile-map. I have a base tile at zoom = 0 as png which has an extent of 56 by 56 kilometres and a resolution of 218.75 meters. Currently the tile-archive goes down to zoom-level 4.
I used the projection in EPSG:25833 in proj4 and displayed the tiles via ol.source.xyz. I defined extent and resolution. However the map is not displayed at the correct coordinates. On loading it jumps to a higher zoom-level than entered and displays a small part of a tile. When zooming out the defined extent is just a small rectangle in the center of the map and coordinates go up to exorbitant numers around this extent.

I searched in stackexchange an in the OL-Apidoc, but could not find my error.

Here is my current code:

proj4.defs('EPSG:25833', '+proj=utm +zone=33 +ellps=WGS84 +datum=WGS84  +units=m +no_defs');
var projection25833 = ol.proj.get("EPSG:25833");

var tileLayer = new ol.layer.Tile({
    source: new ol.source.XYZ({
        projection: projection25833,
        url: "{z}/{x}/{-y}.png",
        extent: [364900,5791100,420900,5847100],
        tileSize: [256, 256],
        minZoom: 0,
        maxZoom: 4
    })
});

var myView = new ol.View({
    projection: projection25833,
    extent: [364900,5791100,420900,5847100],
    center: [392900, 5819100],
    resolution: 218.75,
    zoom: 0,
    minZoom: 0,
    maxZoom: 4
});

var map = new ol.Map({
    target: "mapDIV",
    layers: [tileLayer],
    view: myView
});


texts: Basic Widgets Operations Dashboard for ArcGIS

texts:
What is needed to create new widgets for Operations Dashboard?

Is there a simple basic instructions?

Have no programming experience.

And how to set a widgets available to a user?


texts: How can I extract a smooth river network with QGIS & GRASS?

texts:
I´m working with Qgis 2.6.1 and GRASS.

I have used the r.watershed module to create a flow accumulation map. With r.mapcalc I have extracted the river network, then i´m using r.thin to thin out to a single pixel width the lines on the binary raster map.

Then I'm using r.to.vect.line to convert  raster to vector lines. Everything looks good however the network doesn't have smooth corners ... please look at the picture, my rivers are blue.

Can I change something in this procedure to diminish this effect?


texts: Reading multiple file geodatabase folders from one workspace using ArcPy?

texts:
my indented code without the try/except is below. Python reports no errors but after the script completes running, DefineProjection_management() doesn't show the correct location/points in a map.

My folder structure and code are below. Can somebody suggest a fix please?

import arcpy
from arcpy import env
import os

# set path where the shapefiles are located
arcpy.env.workspace = "Z:/temp1"
inWorkspace = arcpy.env.workspace
workspaces = arcpy.ListWorkspaces("*", "ALL")

for item in workspaces:
    print item
    env.workspace = item
    fcs = arcpy.ListFeatureClasses()

    for file in fcs:
        print '\t', file

 # set local variables
    for file in fcs:
         inData = file
         coordinateSystem = arcpy.SpatialReference(4283)
         arcpy.DefineProjection_management(inData, coordinateSystem)


texts: Raster calculator and Zonal Statistics as a table do not work on joint combined raster?

texts:
I combined 3 raster files in ArcMap 10.4 and then joined 3 .dbf table to the combined raster and exported the result to a new .tif file.

Now I am trying to run "Raster calculator" and "Zonal Statistics as a table". However none works on the joint fields. The result that I get from these two shows that they have been only applied on the Value and Count Fields.


texts: Automatic forest classification using Sentinel-2 data

texts: I have a task to be tackled of which I am not sure, wheter it is even possible. I need to classify single trees/clusters of trees in a forest automatically using sentinel-2 data. Supervised classification should be extremely trick in my opinion. I have some ground data, so that certain pixels are identified as a specific kind of tree in a point layer. Is there any way to get the automatic classification done? Especially when that scheme should not only work on a single image but on several images of the same area?


texts:
I've a shapefile of roads data. It contains information about terrain of road segments, i.e., hilly, flat, undulating, etc. I want to determine gradient of every road segment. I know this might require corresponding raster data and a lot of image processing. I also understand that I can use GRASS for this kind of analysis. But I've never attempted a task like this before.

For those who have, is GRASS my best bet? And, must I get the corresponding raster data? Is there a way I can do this without having to get my hands dirty with image processing algorithms. In case I must get the corresponding raster data, is there a source I can get reliable raster data that is not more than 4 years old?

Your contribution will be highly appreciated.

UPDATE:
There will be a need to split a road segment that has both ascending and descending gradients. Overlaying the roads vector onto a raster layer is one of the options I think can work. But I don't have the raster data. Any idea where I can get raster data with sufficient accuracy and resolution will be appreciated. Can GRASS accomplish the splitting, and the analysis. I'd prefer open source tools for now as I'm still experimenting.

UPDATE:
The purpose of the analysis is to come up with an algorithm that calculates economic well being of a point on a map, taking into account its accessibility (distance from the road, terrain, among other factors). Also, the algorithm is to also aid in decision making in relief food distribution.

UPDATE:
I've got some material here on terrain analysis. Any advice is still welcome.


texts: Manually editing point coordinates in QGIS

texts:
Is there a tool for shapefiles or a QGIS Plugin available, which will enable me to edit the coords of a point manually ?
("tool" -f1 "Tsunami Gauge"-move x1.abcdef -to x2.ghijkl)

I do have approximate points of which I the later receive highly preceice data and there I would lie to update my so far data, instead of creating new files.


texts:
I am working on a project where displaying data from a WFS from this site, but I am having a lot of trouble figuring out how. I would like to know if this is possible, or if I am wasting my time. Through my research i have come across terms like geoserver og openlayers, and I have grown conserned that i can only access the WFS if it is within one of these (making my WFS useless).

Can anyone clerifye this for me? And if it is possible, can someone show me a simple example?

UPDATE:

The Idea is to make a web page where users can view the data. Since the data is updated daily or weekly it would be nice to connect to the WFS client. My problem, is I don't understand how to make a proper GetFeature URL, and how to handel it when i do.
I just recently discoverd that uploading the data throu a webpage might be a posible solution, and therfore havent had much time to learn how it works. I do however see that this solution might be much better and much more accessible that a qgis plugin, which is what i am making now, and might therfore be worth the time. I have allready spent a week on this, and will spend more time if it is possible. But I don't wan't to spend any more time if it is a dead end.


texts: Measuring/4D relation querying within linestring using PostGIS

texts:
let's assume a Linestring(Z)M holding a timestamp as measure variable with each point. Is there a way to easily query "on the relation of those timestamps between the points". For example to find segments where duration between two timestamps are larger than x minutes.

I am aware of the ST_LocateBetween function, where I could filter an M-geometry for a certain specified range. But that is more an absolute function and I am more looking at relative filters.


texts: Extracting some bands of multiband satellite image as layers using QGIS 3

texts:
I have a multiband(8 bands) satellite image. Now what I want, is to extract 5 bands from that image. By extraction I mean saving those 5 bands into a different layer or Geotiff. I am using QGIS 3 (Madeira) and Ubuntu 16.04.

I am avoiding the use of extra tools and trying to keep to in-built tools in QGIS.


texts: Getting null values using Point sampling tool in QGIS 2.0.1

texts:
I would like to obtain the information of a raster layer at some points. Apparently the Point sampling tool does the job. I have used this tool, and all the raster values extracted at specific points are NULL... Both vector and raster layer are in the same CRS. I use QGIS 2.0.i in Windows 8.1. Any clue ?

By the way, does anybody knows how the raster value is computed by this tool = Is it interpolated ? or is it the closest raster value to the point coordinate ? )


texts: Python's logging module not working with ArcPy

texts:
I have a Python script imported to an Arc toolbox. It uses Python's logging module for message recording.

import logging
import time
import os, sys
import arcpy

logging.basicConfig(filename='log.log', format='%(levelname)s - %(asctime)s: %(message)s', datefmt='%d/%m/%Y %I:%M:%S %p', filemode='w', level=logging.DEBUG)

When run as a standart Python file it created the log file successfully. However, when I ran it from the Toolbox in ArcMap, the log file was not created. It seems logging is not working with ArcPy. Any idea?


texts:
I am using qgis 2.8.9 wien version.
windows 10 home 64-bit operating sysytem.
vector layer: Kml file,Line string
CRS: WGS 84, EPSG:4326, is the base file for which buffer zone is to mark.
for the need of buffer in meters, I saved the file using "save as" option and saved it as "esri shapefile", where i changed the CRS to NAD 83/Maryland, EPSG:26985. In order to get the buffer zone in meters.
After that selected VECTOR-GEOPROCESSING TOOLS-BUFFERS.
In Buffer option in the slot of "BUFFER DISTANCE", I have filled 1 meter. Because i want the buffer zone of 1 meter, which is shown in below figure:

I got the buffer zone in meters but when i cross checked it, it showing the distance of 0.95m. means there is 0.05m error for 1mtr. which is shown in below figure:

For 1mtr it is 0.05m error. For 15000m its is showning much more error.
Since i am doing the project of noise modeling. single meter is also important to me.

My question is why this error is occuring?
what is the solution for this?


texts: What is the fastest (performance-wise) way to serve PostGIS features?

texts:
I'm interested in the fastest way to serve PostGIS features. I can find several WMS improvements and alternatives (MapProxy, TileCache, Mapnik...) but not so many WFS Open Source improvements and alternatives. I'm not interested in tiles, but in polygons over my base layer. Served fast.

Could you please me point in the right direction?

Update:

I forgot to mention that my app shows cadastral information. And cadastral polygons must be selectable (not editable, they are only highlighted when you click on them).

I'm using right now a mix of WMS + Django generating GeoJSON objects when the user clicks on a part of the map, to avoid situations like thousands of polygons at same time in the client (OpenLayers).

I don't know if I'm in the right way (should I avoid potentially hard situations like thousands of pols in the client by rendering them via WMS or any other solution? Should I improve the way the polygons are served?)


texts: Pindrop or crosshair after address search in CartoDB?

texts: The basic search box feature supplied by CartoDB centers the map on the result ... but for a user this may not be intuitive and furthermore, on maps with lots of data (like parcels) it might be unclear exactly where the "center" is. Is there a way to provide some sort of crosshairs, "flash" or pindrop after an address search?  For my project it is crucial that a viewer can search for an address, then navigate to data provided by the visualization connected to that address.


texts:
Can QGIS automatically find the lowest land-point in a country and when you would like to, find the second lowest, third lowest land-point and so on? And on that same coin, a software that could find the highest point, second highest, third highest point etc?

Checked out QGIS and did the tutorial, but it seems to be a program where you build maps.


texts: Calculate area of polygons in square meters when CRS is EPSG:25833

texts:
I have EPSG:28533 coordinates and would like to calculate its area in square meters and then transform these coordinates to EPSG:3857. I have taken the code from here to calculate the area but it does not work with my CRS.

coordinates = [(Decimal('6589205.89443007'), Decimal('-50883.0113025327')), (Decimal('6591049.22486397'), Decimal('-50614.5604573338')), (Decimal('6590704.68228889'), Decimal('-48243.7236024176')), (Decimal('6590361.64106593'), Decimal('-45872.7460103936')), (Decimal('6590020.10109455'), Decimal('-43501.6283233083')), (Decimal('6589680.06227459'), Decimal('-41130.3711828075')), (Decimal('6589341.52450628'), Decimal('-38758.9752301393')), (Decimal('6589004.48769026'), Decimal('-36387.4411061548')), (Decimal('6587160.50702663'), Decimal('-36648.8894118596')), (Decimal('6587497.65096856'), Decimal('-39021.5904317087')), (Decimal('6587836.29636065'), Decimal('-41394.1533574574')), (Decimal('6588176.44330258'), Decimal('-43766.577548558')), (Decimal('6588518.09189442'), Decimal('-46138.8623640661')), (Decimal('6588861.24223663'), Decimal('-48511.0071626391'))]

def get_area(coordinates, polygon_geom):
    geom_area = ops.transform(
        partial(
            pyproj.transform,
            pyproj.Proj('EPSG:4326'),
            pyproj.Proj(
                proj='aea',
                lat_1=polygon_geom.bounds[1],
                lat_2=polygon_geom.bounds[3])),
        polygon_geom)
    return geom_area.area

def transform_coordinates(coordinates):
    coord_tuple = []
    for (x,y) in coordinates:
        inProj  = Proj('EPSG:25833')
        outProj = Proj('EPSG:3857')
        lat, lon = transform(inProj,outProj,x,y)
        coord_tuple.append((lat, lon))
        #print(x,y, " -> ", lat, lon)
    return coord_tuple

I have tried before transforming first to EPSG:4326 so I can calculate the area and then transform the coordinates to EPSG:3857. The problem with it is that it took a few seconds to do transforms per coordinate row and I have 30 0000 rows.

First polygon data:

I have 50% polygon data in EPSG:25832.

I have another 50% polygon data in EPSG:4326.

Second polygon data:

100% polygon data in EPSG:4326.

I need to calculate the intersection area in square meters between first polygon data and second polygon data. I have read that in order to do it, I need to transform EPSG:4326 to EPSG:3857 which uses meters.


texts: SelectLayerByAttribute over an iterable list - arcpy

texts:
I am trying to get arcpy to select features in a shapefile that appear in a list generated from a model output file in a variable called 'died'.

The list looks like this:

died
['acadian022', 'acadian051', 'acadian052', 'acadian121', 'acadian152',
'acadian191', 'chick031', 'chick032', 'chick052', 'chick132', 'creeper032',
'downy032', 'downy042', 'kentucky041', 'ovenbird012', 'ovenbird061',
'pewee011', 'pewee021', 'pewee032', 'pewee051', 'pewee071', 'pewee082',
'pewee101', 'thrush022', 'thrush042', 'thrush152']

I can get arcpy to select one of these points using this:

inFeatures = "nests"
outFeatures = "C:/test.gdb/new_nests"
tempLayer = "nestslyr"
expression = "ID = 'acadian022'"

arcpy.CopyFeatures_management(inFeatures, outFeatures)
arcpy.MakeFeatureLayer_management(outFeatures, tempLayer)
arcpy.SelectLayerByAttribute_management(tempLayer,"ADD_TO_SELECTION",
expression)

But when I change this to a for loop, the loop runs fine and I do not get any errors, but the tool does not select any points.

for x in died:
    expression = "ID = 'x'"
    arcpy.SelectLayerByAttribute_management(tempLayer,"ADD_TO_SELECTION",
    expression)

Does anyone know why this might be the case?


texts: kml/kmz files not loading by google maps anymore

texts:
Until a few months ago this worked: https://maps.google.com/maps?q=http://www.jcea.es/pics/italia2015/italia2015.kmz

It is NOT working anymore.

I know that I can login in Google maps, create a custom map and upload a KML file (if it has less than 2.000 points, my KML files are far bigger). But I don't want to upload a KML file, I want a map I can overlay a KML hosted in my HTTP/HTTPS server.

In fact I rather prefer to use something like OpenStreetMap instead of Google, but I don't know any service I could use.


texts: What is difference between ST_DWithin and ST_Distance for proximity search in PostGIS?

texts:
I have records stored in a table with latitude/longitude coordinates stored in a geometry field.  I want to find all records nearby a user supplied reference point.  Note "nearby" probably means less than 100km (possibly even smaller).

Most examples I see use ST_DWithin. Is there a reason you can't use ST_Distance? What is the difference between using ST_DWithin and ST_Distance to do this?

For example:

SELECT name, ST_AsText(coords)
FROM places
WHERE ST_DWithin(coords, ST_GeomFromText('POINT(-12.5842 24.4944)',4326), 1)

vs

SELECT name, ST_AsText(coords)
FROM places
WHERE ST_Distance(coords, ST_GeomFromText('POINT(-12.5842 24.4944)',4326)) < 1


texts: Finding an EPSG code for a LiDAR file given only its metadata

texts:
I am working with v1.4 .las files from El Paso County, CO, that individually appear without any reference to their projections (none that R sees, anyway).  From the metadata I can see the following information:
<spref>
 <horizsys>
  <planar>
   <gridsys>
    <gridsysn>State Plane Coordinate System 1983</gridsysn>
     <spcs>
      <spcszone>0502</spcszone>
      <lambertc>
       <stdparll>38.450000</stdparll>
       <stdparll>39.750000</stdparll>
       <longcm>-105.500000</longcm>
       <latprjo>37.833333</latprjo>
       <feast>3000000.000316</feast>
       <fnorth>999999.999996</fnorth>
      </lambertc>
    </spcs>
   </gridsys>
  <planci>
   <plance>coordinate pair</plance>
    <coordrep>
     <absres>0.001</absres>
     <ordres>0.001</ordres>
    </coordrep>
    <plandu>survey feet</plandu>
  </planci>
</planar>
 <geodetic>
  <horizdn>D_NAD_1983_2011</horizdn>
   <ellips>Geodetic Reference System 80</ellips>
   <semiaxis>6378137.000000</semiaxis>
   <denflat>298.257222</denflat>
  </geodetic>
 </horizsys>
<vertdef>
 <altsys>
  <altdatum>North American Vertical Datum of 1988 Geoid12B</altdatum>
  <altres>0.001</altres>
  <altunits>feet</altunits>
   <altenc>
   Explicit elevation coordinate included with horizontal coordinates
   <altenc>
  </altsys>
 </vertdef>
</spref>

Nowhere in the metadata is any reference made to an epsg or to esri code
This appears to correspond to blocks of information for at least 5 of 12 "Colorado Central 502" projections I have identified on epsg.io. (2232, 3502, 2877, 6428, and 102654)
lasinfo returns the OGC COORDINATE SYSTEM WKT string, but no EPSG. (I'm not skilled with lastools, but I tried...)
My questions are:

How does one definitively identify the EPSG that goes with the projection content given in LiDAR metadata when the metadata omits the EPSG code?
If the content in the above metadata and that of any EPSG code all match, does it make any difference which EPSG code I chose?  If so, what additional parameters matter?
Is there a site that receives the detail above as input and returns the EPSG code, not the other way around? "http://prj2epsg.org/search" appears to be dead.


texts: How to get JAI + JBoss 7.1.1 + Geoserver 2.3.0 to work?

texts:
I'm trying to use JBoss 7.1.1 instead Tomcat.

My configuration:

Ubuntu 12.04 64bit
Oracle JDK 1.7 (env varibles are set correctly)
JAI and JAI ImageIO installed by following help document: http://docs.geoserver.org/latest/en/user/production/java.html (this manual works with Tomcat)
Geoserver 2.3.0 (war file)
Jboss 7.1.1 (out-the-box)

Problem: After following the documents, both JAI and JAI ImageIO are not show as true in "server state" panel (Has Geoserver not found them?).

I did the same steps like in Tomcat, but I'm a total noob with Jboss. I think that JBoss does not search in CLASSPATH for JAI extension, and it need to include JAI like a JBoss "module", but I couldnot find any information about that.

Any ideas?

UPDATE: I have included the jar files, from the JAI installation file, in the WAR file, inside the path "/WEB-INF/lib", and now shown this in the panel:

UPDATE 2: I put the .so (from JAI packages) in "/usr/lib", no luck. My co-worker is compiling Geoserver, in Eclipse, to see if we see happening in Jboss while loading the JAI. We hope to find a solution (I will share it here).

UPDATE 3: It's a problem in Jboss configuration. We will write down the solution as soon as possible.


texts: I often am unable to delete files due to a lock or need to reset the data frame coordinate system.  Very often starting a new session of Arc will allow certain geoprocessing or data management tasks to run effectively.  What solutions exist to reset the local memory usage in ArcMap 10 other than closing and starting a new session? For the Python programmers out there, is there a way to add code to scripts that clears local memory before or after running geoprocessing tasks?


texts:
I have successfully got my cql_filter button to respond correctly in terms of filtering a WMS contour dataset served from PostGIS and GeoServer.

However, my next goal is to complete a cql_filter which filters data within a set distance of the defined object. In my case, I am trying to select all Electrical Pylons within a distance of a defined electrical pylon. Therefore, the Pylon would need to be defined by the user and also the search distance.

I understand that I should be using the 'DWITHIN' query and have again previously completed this in OpenLayers 3 but can't get my code to respond in Leaflet.

My java-script code is:

    //Pylon Search Button
    function updatePylons() {
    var pylonfilter = 'DWITHIN(geom,
      collectGeometries(queryCollection(
        \'Inyaninga_243-198:proposed_pylons_3857\',\'geom\',\'id = \'\'' + document.getElementById('Pylon').value + '\'\' \')), '
        + document.getElementById('distance').value + ', meters)' ;
    return pylons.setParams({CQL_FILTER: pylonfilter});
    };

This will be passed to an input form with two fields:

    <form>
    Pylons:<br>
          <input type="text" id="Pylon">
          <input type="number" id="distance">
          <input type="button" value="Filter" onclick="updatePylons()">
    </form>

I have adapted my code as best I can, I'm sure its a minor issue.


texts: TIGER Geocoder not matching intersections without ZIP

texts:
I'm using the TIGER geocoder (2013 data, PostGIS 2.1, Postgres 9.3) to geocode intersections in New York City, but I'm finding that if I omit the zip code, I almost never get a match. So, for example...

ny_tiger=# SELECT pprint_addy(addy), st_astext(geomout), rating FROM
  geocode_intersection('Broadway', 'Houston St', 'NY', 'New York', '10012');
       pprint_addy            |          st_astext          | rating
----------------------------------+-----------------------------+--------
 607 Broadway, New York, NY 10012 | POINT(-73.996772 40.725432) |      0
 604 Broadway, New York, NY 10012 | POINT(-73.996772 40.725432) |      0
 609 Broadway, New York, NY 10012 | POINT(-73.996772 40.725432) |      0
 606 Broadway, New York, NY 10012 | POINT(-73.996772 40.725432) |      0
(4 rows)

but...

ny_tiger=# SELECT pprint_addy(addy), st_astext(geomout), rating FROM
  geocode_intersection('Broadway', 'Houston St', 'NY', 'New York');
 pprint_addy | st_astext | rating
-------------+-----------+--------
(0 rows)

Is there a good way to get these addresses to resolve without the zip code?


texts: Reshape ILineElement with ISelectionTracker in graphics container

texts:
End goal:
Allow user to move points on a ILineElement using the selection handles from ISelectionTracker.

Issue:
Using my code below I am able to get the handles to appear on the line element, but it appears to be using an EnvelopeTracker and not a LineTracker. Also I am unable to drag the displayed handles to reshape the line.

Code:

public void TrackSelection()
{
    IGraphicsContainerSelect graphicsContainer = (IGraphicsContainerSelect)GetGraphicsContainer();
    ILineElement outline = GetLine();
    // Selecting the element adds the tracker handles.
    graphicsContainer.SelectElement((IElement)outline);

    RefreshView();
}

private ILineElement GetLine()
{
    //For simplicity only 1 line is created so just grab it.
    ILineElement line = null;
    IGraphicsContainer graphicsContainer = GetGraphicsContainer();
    if (graphicsContainer != null)
    {
        graphicsContainer.Reset();
        IElement element = graphicsContainer.Next();
        while (element != null)
        {
            if (element is ILineElement)
            {
                line = (ILineElement)element;
            }

            element = graphicsContainer.Next();
        }
    }

    return line;
}

public void RandomLineElementCreator()
{
    // Random line creator. Replacing.
    IGraphicsContainer graphicsContainer = GetGraphicsContainer();
    if (graphicsContainer != null)
    {
        graphicsContainer.DeleteAllElements();

        IColor color = EsriConversionUtility.ConvertToRgbColor(Colors.Red);
        ISimpleLineSymbol simpleLineSymbol = new SimpleLineSymbolClass();
        simpleLineSymbol.Color = color;
        simpleLineSymbol.Width = 3;

        IPointCollection path = new PathClass();
        var line = new PolylineClass();
        Random rnd = new Random();
        for (int i = 0; i < 4; i++)
        {
            int randomX = rnd.Next(1, 8);
            int randomY = rnd.Next(1, 16);
            var point = new Point();
            point.X = -12831100.742200622 - (randomX * 1000);
            point.Y = 7674669.7012844728 - (randomY * 1000);
            path.AddPoint(point);
        }
        line.IPointCollection4_AddPointCollection(path);

        IGeometry geometry = line;

        ILineElement lineElement = new LineElementClass();
        lineElement.Symbol = simpleLineSymbol;
        IElement elementToAdd = lineElement as IElement;
        elementToAdd.Geometry = geometry;
        graphicsContainer.AddElement(elementToAdd, 0);

        RefreshView();
    }
}

private IGraphicsContainer GetGraphicsContainer()
{
    ICompositeGraphicsLayer compositeGraphicsLayer = (ICompositeGraphicsLayer)(MapController.Map.BasicGraphicsLayer);
    try
    {
        _graphicsLayer = compositeGraphicsLayer.FindLayer(EditContourGraphicsLayerName);
    }
    catch
    {
        _graphicsLayer = compositeGraphicsLayer.AddLayer(EditContourGraphicsLayerName, null);
    }

    return _graphicsLayer as IGraphicsContainer;
}

private void RefreshView()
{
    MapController.PartialRefreshMap();
    if (ActiveMap.Instance.IsInitialized)
    {
        ActiveMap.Instance.Map.IsDirty = true;
    }
}

What I have:

What I want:


texts: Python convert lines string to polygon if closed

texts:
I have a series of contour linestrings some are closed and some are not. The linestring values are between -1 and 1. I am trying to create polygons from the linestrings if they close and keep the value. I have asked this question similar question before and haven't been able to find a solution. because the polylines are contours, there will be donut polygons. The code below will generate the correct polygons, but cannot get the 'ExtraData' value into the newly created polygons.

polylines = fiona.open(input_file)
geom = [x['geometry'] for x in polylines]
coords = [x['coordinates']for x in geom[:-1]]

# {{'ExtraData': 'float'}} should be carried over from the polyline

schema =  {'geometry': 'Polygon','properties': {'id': 'int'}}
with fiona.open(output_file, 'w', 'ESRI Shapefile', schema) as c:
    for poly_id,polygon in enumerate(polygonize(coords)):
        c.write({
            'geometry': mapping(polygon),
            'properties': {'id': poly_id},
        })

there is no extradata ouput in the coords/polygon. now only coordinates like

POLYGON ((3102900.92 23355541.16, 3102900.900615673 23355541.220965....)

but the extradata is like

0.12


texts: Importing a temperature raster layer to QGIS project

texts: I am trying to add raster layers to depict minimum monthly winter temperatures for two counties in Ireland.  I tried importing as tiff., ADF., HDR., and bil. files.  I managed to add them in any of above formats but the results meant nothing!  How can I classify the layers so that they are colour coded when depicted and include a legend in degrees celsius?


texts: QGIS fails to generate requested number of random points

texts:
Does anyone have any ideas what might be blocking this process? The layer has thousands of polygons totalling hundreds of thousands of square metres, but when asked to locate 140 random points even with zero minimum spacing, QGIS claims "Could not generate requested number of random points. Maximum number of attempts exceeded." My last run has 83 points.

Working on land use data for British Columbia, Canada with QGIS 3.2.0-Bonn.

I do now have 2 runs with ~140 total, but I'd like to be able to create one set with a minimum spacing.


texts: QGIS Composer Legend Filter by Map Content Not Showing Item

texts: I'm trying to filter a composer using the Filter by Map Content Button. It works for the most part. There is a line layer that doesn't fit completely in the map window that gets filtered out, I'm guessing because the whole layer isn't present. Is there a way to over ride a single layer so it shows up even while using this button to filter the rest?


texts:
Having a hard time to get a raster from a polygon

ST_AsRaster(ST_Buffer(ST_GeomFromText('POLYGON((-30 40, -20 30, -25 20, -23 10, -30 40))', 4326), 50),ARRAY['8BUI'],ARRAY[118]);

This line is giving me an error : No function matches the given name and argument types. You might need to add explicit type casts.


texts: Using OpenLayers 5.3 in TypeScript without Node.js

texts:
I would like to use the latest version of OpenLayers (5.3) in small project. The requirements are:

no Node.js - I will be running thing on the site hosted on IIS, simple HTML files
scripts need to be written in TypeScript
List item
ES5

I've read a lot of different discussions and I'm a bit confused. It this even possible? The new OpenLayers has ol npm package, there are (at least two) types definitions for OpenLayers but I can't get it to work in the browser.

First, it complaining about import statements which are not recognized. The other issues are that even if I will include full ol.js I can't get typings to work in TypeScript.

Does anyone have some successful examples?

Fo example bellow the ol namespace is not recognized:

/// <reference path="ol.js"/>
/// <reference path="../Typings/ol/Map.d.ts"/>

// no imports as they are not working without Node.js

class MainMap {

    createMap() {
        var map = new ol.Map({
            target: 'map',
            layers: [
                new ol.layer.Tile({
                    source: new ol.source.OSM()
                })
            ],
            view: new ol.View({
                center: ol.proj.fromLonLat([37.41, 8.82]),
                zoom: 4
            })
        });
    }
}

let map = new MainMap();
map.createMap();

Anyone is successful with using OpenLayers typings in TypeScript without using Node.js?


texts:
Can anyone tell me how to accomplish this?

I want a Python script to run on opening the MXD which would pull an excel worksheet into a GDB and refresh the map.

I only want this to happen in this specific MXD.


texts: Node.js transformation from NAD83 to WGS84

texts:
I've used the excellent npm shapefile library to import Canadian electoral districts into MongoDB. Here's a sample file: http://ftp2.cits.rncan.gc.ca/pub/geott/electoral/2011/fed308.2011.zip

Is anyone familiar with a node.js tool that would allow me to do this? I'm familiar with Django and the GIS tools provided by Geodjango, but am new to GIS development in the Node.js ecosystem.

Thanks in advance!


texts: Steps to dipslay aerial photos as tiles using tilemill

texts:
I am new to tilemill and trying to find out steps to display aerial photos as tiles in tilemill.

The aerial photos are saved as geotiff files and I tried to create a new layer using them as the datasource.
Howerver, I have no luck that the geotiff images and the layer settings are displayed as shown below.

The questions I want as are follows:

Would it be possible to show aerial phots as tiles in tilemill?
If possible, what would be the basic flow or steps to achieve the goal?

I followed the basic guids available on the internet such as below already.
http://tilemill-project.github.io/tilemill/docs/guides/reprojecting-geotiff/


texts: Nothing is highlighted using print service

texts:
I have an Esri map with print service enabled. I would like to print a map based on objectid of a feature layer. The following is my Web_Map_as_JSON.

{
    "mapOptions": {
        "showAttribution": true,
        "extent": {
            "xmin": 829017.362240001,
            "ymin": 828550.995070001,
            "xmax": 828609.077310001,
            "ymax": 829053.843320001,
            "spatialReference": {
                "wkid": 102140,
                "latestWkid": 2326
            }
        },
        "spatialReference": {
            "wkid": 102140,
            "latestWkid": 2326
        },
        "scale": 10000
    },
    "operationalLayers": [{
            "id": "LIFIPSBasemap",
            "title": "LIFIPSBasemap",
            "opacity": 1,
            "minScale": 0,
            "maxScale": 0,
            "url": "https://win-enkuf1vq572/arcgis/rest/services/DEV/FSD_LIFIPS_Basemap_v02/MapServer"
        }, {
            "layerType": "ArcGISFeatureLayer",
            "url": "https://win-enkuf1vq572/arcgis/rest/services/DEV/Search/MapServer",
            "visibility": true,
            "opacity": 1,
            "mode": 1,
            "visibleLayers": [0],
            "selectionObjectIds": [2037156],
            "selectionSymbol": {
                "type": "esriSFS",
                "style": "esriSFSSolid",
                "color": [0, 0, 0, 255],
                "outline": {
                    "type": "esriSLS",
                    "style": "esriSLSSolid",
                    "color": [0, 0, 0, 255],
                    "width": 1000
                }
            }
        }
    ],
    "exportOptions": {
        "outputSize": [800, 1100],
        "dpi": 200
    },
    "layoutOptions": {
        "titleText": "ABC, Portrait PDF",
        "scaleBarOptions": {
            "metricUnit": "esriKilometers",
            "metricLabel": "km",
            "nonMetricUnit": "esriMiles",
            "nonMetricLabel": "mi"
        },
        "legendOptions": {
            "operationalLayers": []
        }
    }
}

However, the "selectionObjectIds" and "selectionSymbol" doesn't take effect, i.e. my target shape doesn't fill in black. What's wrong with my JSON?