texts: Is it possible to create an ACL (Acces Control List) for OGC SOS (Sensor Observation Service) protocols

texts:
What alternatives exist to create an ACL (Acces Control List) for OGC SOS (Sensor Observation Service) protocol?

My goal is enable only some resource (Sensors, procedures or offerings) at some users.

The only two solutions found are:

•   The 52n Web Enforcement Service (WSS): underdeveloped, it cannot be download.

•   Geoshield: Small community, difficulty to find technical information, and
only offer support to first version s of SOS 1.0.


texts: Adding a GIS feature to existing database entry with QGIS

texts:
I've built a database with postgreSQL with tables, which include geometry columns.
When I add some data to my non-geometry columns, I can see them in QGIS when I connect to my database using postgis. Now, I want to add polygons to the existing entries with the editing tool in QGIS. That means, filling up the geometry columns in QGIS.

How can I do this? I've only heard about adding whole shapefiles to the database but not to add single features to a single column.

An example... I have the following table (municipality):

id smallint NOT NULL,
name varchar(50) NOT NULL,
mun_geom geometry(Polygon, 31468)

I can fill the columns id and name in postgresql when I'm connected to my database (like (1,'municipality1')). After adding municipality as a postgis layer I want to complement the entry with adding a polygon feature.


texts:
I have a query regarding the dissolving of polygon features in ArcGIS 9.3. I only have the bare-bones license and an extremely basic knowledge of VB.

I have a large shapefile with around 4500 polygons and I want to know if there is anyway of dissolving the ones that overlap? I basically want to turn this layer into a shapefile that contains seperate areas, so where one polygon is on its own it will remain but where multiple polygons overlap they dissolve into 1, with each separate area having its own set of attributes. The shapefile changes quite frequently and up until now I have been going through them all and manually dissolving overlapping areas using the editor tool but I'm sure there's a much quicker way of doing it!

Any insight into how this might be achieved?

I've had a go using the dissolve tool and joining the exported attribute table and this works perfectly! I thought the dissolve tool only worked on attributes and not spatial location so that's extremely useful to know. Also the ModelBuilder code is


texts: Error while converting raster to ploygon using stars package

texts:
I am trying to convert raster to polygon using stars package as suggested in this and this. I have used the following code
library(raster)
library(stars)
library(sf)
library(magrittr)

#read raster
r1<-raster("raster_name.asc")

# convert raster to polygon, dissolved neighboring same values
r.to.poly<-st_as_stars(r1) %>%
  st_as_sf(merge = TRUE)

which is giving me the following error

Error in CPL_polygonize(file, mask_name, "GTiff", "Memory", "foo", options,  :
basic_string::_S_construct null not valid

How to solve this error?


texts: Using the Flexviewer 2.4 I want to toggle layers from one service on/off

texts:
I have 2 layers in one service. If the user clicks one on, I want the other one to turn off, and vice versa.

I am using the default flexviewer LayerListWidget.mxml and assume this is the place where I would want to put the code to handle the toggle on/off event.

I have seen these posts, but I am not sure it's the right code. Can someone provide me with the right code to use? Thanks in advance.

esri forum 1

esri forum2


texts: Error appending data to existing PostgreSQL database for OSM with osm2pgsql

texts:
When running osm2psql on an existing database I get an error
osm2pgsql -v -d gis -a -s -G --flat-nodes ./nodes.cache --number-processes 8 ./thailand.osm.pbf
Output is :

Allocating memory for dense node cache
Allocating dense node cache in one big chunk
Allocating memory for sparse node cache
Sharing dense sparse
Node-cache: cache=800MB, maxblocks=12800*65536, allocation method=11
Mid: loading persistent node cache from ./nodes.cache
Mid: pgsql, cache=800
SQL command failed: ERROR:  relation "planet_osm_ways" does not exist
LINE 1: ...REPARE mark_ways_by_node(int8) AS  SELECT id FROM planet_osm...
                                                             ^

Full query: PREPARE mark_ways_by_node(int8) AS  SELECT id FROM planet_osm_ways    WHERE nodes && ARRAY[$1];
PREPARE mark_ways_by_rel(int8) AS  SELECT id FROM planet_osm_ways    WHERE id IN (      SELECT unnest(parts[way_off+1:rel_off])        FROM planet_osm_rels WHERE id = $1    );

node cache: stored: 0(0.00%), storage efficiency: 0.00% (dense blocks: 0, sparse nodes: 0), hit rate: 0.00%
Osm2pgsql failed due to ERROR: Executing SQL

Displaying current existing tables in postgres gives:
gis=# \dt
              List of relations
 Schema |        Name        | Type  | Owner
--------+--------------------+-------+-------
 public | planet_osm_line    | table | osm
 public | planet_osm_point   | table | osm
 public | planet_osm_polygon | table | osm
 public | planet_osm_roads   | table | osm
 public | spatial_ref_sys    | table | osm
(5 rows)

As I understand it, the -s option (slim mode) is supposed to create 3 new tables : https://github.com/openstreetmap/osm2pgsql/blob/master/docs/pgsql.md#database-layout
planet_osm_nodes
planet_osm_ways
planet_osm_rels

It's like osm2psql tries to access those tables before creating them at first.
PS: I also tried without the flat-nodes option
osm2pgsql -v -d gis -a -s -G -C 40000 --number-processes 8 ./thailand.osm.pbf with same result.


texts:
Currently I have to import a number of files with similar names from the same path. Is there a way to store a user variable in the console session to subsequently use it in other commands?

Imagine something like:

g.gisenv set="thePath=/path/to/my/files/"
r.gdal.in input=thePath+rast1.tif output=rast1

I use g.gisenv here only as an illustration. I am looking for something similar for user variables.


texts: Georeferenced TIF files, can TFW files be created from TFWX files? - (ArcGIS 9.3)

texts:
I have georeferenced some image TIF files in ArcGIS 9.3. Update Georeferencing creates a *.TFWX file. Renaming to  *TFW file does not place the image in the correct spatial location for software packages outside ArcGIS.

Is their a tool? converter? or method that will allow me to extract the correct georeferencing information from TFWX to TFW so that my image can be used in other Mapping platforms?


texts: Intersection function returns multiple coordinates

texts:
I am trying to find intersection vertices of two polygons defined below

PG = Polygon([(0.0,0.0), (0.0,4.0), (2.0, 0.0)])
QG = shapely.affinity.rotate(PG, 10.0, origin="centroid")
print(PG.intersection(QG))

It returns a polygon which represents the intersection vertices but I get multiple vertices belonging to polygon PG and QG and not the exact intersection vertices something like this

POLYGON ((0 1.275007557649384, 0 3.233068398870882, 1.176669689726421 1.646660620547158, 1.901423900453083 0.1971521990938349, 0.7833182180345657 0, 0.2248182330207899 0, 0 1.275007557649384))

The graph looks something like this

How to get the exact coordinates of intersection vertices A, B and C as shown above?


texts: Cannot verify WKT polygon for use with SQL Server geometry


texts: Using custom dlls in multiple arcmap applications

texts: I'll do my best to ask my question. I develop a number of COM-based libraries for use within custom arcmap dlls (using ArcGIS 9.3.1 SP2, .NET 2008 C#). These would include a custom arcobjects "helper" library. The issue is how best to deploy and manage these common dlls. The safest way seems to have the setup program create a folder for each application and have it include all of the supporting dlls needed for that application. This has been successful for years but I wonder if this is the best practice for COM-based libraries? On a deployment PC, there would be multiple copies of the custom "helper" library (for example), some with different versions but so far, the same GUID and strong-named. Is it possible (or even advisable) to use a single deployment of common dll? If I can be pointed to an article or white paper or something that talks about this, that would be great too. Thanks.


texts: Using free public account of ArcGIS Online?

texts:
I want to create a free public ArcGIS account to create some story maps.
Afterwards i want to share/publish this storymaps on my website. This website is off a travel agency.

Is it legal to use this self created story maps by a free public account on this website?

Because this story maps gives some images about a city, persons are interesting to visit this city because of the story map, so the travel agency gains some money due this story maps...

And if it's not possible.
Where can i find a license just to create story maps for a commercial way? Not for some other software.

Or is it possible to download the apps of the story maps and upload them on my website. Is it then still illegal?


texts: Transforming or reprojecting Vector to another CRS without using ballpark transformations that result in loss of geometry

texts:
I am having trouble converting CRS of a Vector and getting the error: Used a ballpark transform from EPSG:4326 to EPSG:2230
The Details are below.
An alternative, ballpark-only transform was used when transforming coordinates between EPSG:4326 - WGS 84 and EPSG:2230 - NAD83 / California zone 6 (ftUS). The results may not match those obtained by using the preferred operation:
+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +inv +proj=hgridshift +grids=cshpgn.gsb +step +proj=lcc +lat_0=32.1666666666667 +lon_0=-116.25 +lat_1=33.8833333333333 +lat_2=32.7833333333333 +x_0=2000000.0001016 +y_0=500000.0001016 +ellps=GRS80 +step +proj=unitconvert +xy_in=m +xy_out=us-ft
Possibly an incorrect choice of operation was made for transformations between these reference systems. Check the Project Properties and ensure that the selected transform operations are applicable over the whole extent of the current project.
I have a raster with important data which I do not want to reproject and census vectors which I am trying to attach zonal statistics from the raster. Unfortunately, whenever I clip the census polygons to the stripped and vectorized raster, The resulted clipped layer recieves the CRS of the census data. When I try to convert the census data to the Raster's CRS, I get this ballpark-only transformation error. The same happens when I try to convert the CRS of the census data before clipping.
Maybe there is another way to calculate zonal statistics of this raster safely which I am currently unaware of. I would rather a solution that does not involve transforming the raster, as that is the data which concerns me. My ultimate goal is just to obtain zonal statistics of the different census polygons.


texts:
Maybe question title not correct, i have no idea how to formulate my question.

Database is postgres 9.2, POSTGIS="2.0.2 r10789" GEOS="3.3.6-CAPI-1.7.6" PROJ="Rel. 4.7.1, 23 September 2009" LIBXML="2.7.8"

I have roads map from OpenStreetMap database. Geometry type is MultiLineString. For example, road from city A to city B consists of 27 entries in database (200 km total distance). One entry can be 500 meters another can be 70 kilometers. I want to analyse this road in fallowing scenario:

From city A take 40 km in direction to city B.
Then analyse that path and in case if i need, go, for example, 5 km back or forward.
Take another 40 km, analyse until i reach city B.

How i can go N km from point A  to direction B via that road?
It is possible with SQL / postgis?

What i need is, plan where to place green fuel station. Electrical vehicle can drive average 50 km with full battery. So i need to analyze every N km if there is possible to build fuel station.
I already have data about rivers, electricity grid and another restrictions.

Thanks.


texts: Simplify a polyline/polygon using a threshold on maximum number of vertices in PostGIS?

texts:
The various simplification functions in PostGIS (e.g. ST_Simplify) uses a tolerance parameter for the maximum allowable deviation of the generalized shape from the original. My question is:

Is there an effective way to generalize a geometry so that in the end the number of vertices in the output does not exceed a given number?

(This is with latest PostGIS 2.5 on PostgreSQL 11)


texts: Why are towgs84 definitions missing on Ubuntu 12.04 compared to Windows?

texts:
Why for some of my most used CRS the 'towgs84' part of the definition of the layer spatial reference system is missing, compared to the QGIS for Windows?

EPSG 3004, 23032, 23033 when used with QGIS for Ubuntu are missing the 'towgs84' definition part, that is present in QGIS for Windos. Why this?

I've experimented this with QGIS 1.8 for Win and QGIS 1.8 and 1.9 Master under Ubuntu 12.04


texts: Find common borders of features and get their attributes using fiona and shapely

texts:
I would like to find neighboured features in a shapefile using fiona and shapely.
As shown in this answer
https://gis.stackexchange.com/a/95595/62250
it's easy to get common borders between features.

Now that I have the common border of two features, how do I know which to which two features this border belongs?

How can I read out the attributes of those features?


texts: Error while converting Dataframe to Geodataframe

texts:
I am trying to convert a table to a shapefile. To do that, I am storing that table in a dataframe and then I am trying to convert that dataframe to geodataframe using GeoPandas. But I am getting an error:

  AttributeError: 'DataFrame' object has no attribute 'reshape'

I am using the following code:

import pandas as pd
import geopandas
from shapely.geometry import Point

city_dict=dict()
city_dict={"lat":Lat_list,"long":long_list,"city":city_list,"population":population_list,"area":area_list}
print(city_dict)

df=pd.DataFrame(city_dict)

crs_dict = {'init': 'epsg:4326'}

geometry_list=list()

for index, row in df.iterrows():
    city_name=row['city']
    lat=row['lat']
    long=row['long']
    point=Point(float(long),float(lat))
    print (point)
    geometry_list.append(point)

df['geometry']=geometry_list
gdf = geopandas.GeoDataFrame(df, crs=crs_dict, geometry='geometry')


texts: Converting decimal degrees (longitude & latitude) to UTM WGS84 in R? (Southern hemisphere)

texts:
I'm trying to convert some longitude and latitude coordinates to UTM WGS84 projection. I'm using rgdal, although I can accommodate to other package (in R). I read the data and converted it to a SpatialPoints object:

coordinates(res) <- ~Lat_dec + Lon_dec
proj4string(res) <- CRS('+proj=longlat +datum=WGS84')

my points:

res
SpatialPoints:
   Lon_dec   Lat_dec
35 -78.60972 -9.073333
36 -78.61806 -9.078611
37 -78.60889 -9.093611
38 -78.59167 -9.088889
39 -78.57917 -9.100833
40 -78.56833 -9.112778
41 -78.59278 -9.113333
42 -78.61139 -9.119167
43 -78.57778 -9.122778
44 -78.56889 -9.135833
45 -78.59278 -9.137222
46 -78.60222 -9.160278
47 -78.57472 -9.152778
48 -78.59583 -9.152778
Coordinate Reference System (CRS) arguments: +proj=longlat +datum=WGS84 +ellps=WGS84 +towgs84=0,0,0

The following error is no longer produced since swapping the coordinates to negative values (south america)
Now, when I try to transform the points using spTransform(res, CRS('+proj=utm +zone=17 ellps=WGS84')) I get an error and a warning:

non finite transformation detected:
  Lat_dec   Lon_dec
  9.073333 78.609722       Inf       Inf
Error in spTransform(res, CRS("+proj=utm +zone=17 ellps=WGS84")) :
failure in points 1
 In addition: Warning message:
 In spTransform(res, CRS("+proj=utm +zone=17 ellps=WGS84")) :
   14 projected point(s) not finite

When I try to convert using project(coordinates(res), '+proj=utm +zone=17 ellps=WGS84') I get the projection:

   [,1] [,2]
 [1,]  Inf  Inf
 [2,]  Inf  Inf
 [3,]  Inf  Inf
 [4,]  Inf  Inf
 [5,]  Inf  Inf
 [6,]  Inf  Inf
 [7,]  Inf  Inf
 [8,]  Inf  Inf
 [9,]  Inf  Inf
[10,]  Inf  Inf
[11,]  Inf  Inf
[12,]  Inf  Inf
[13,]  Inf  Inf
[14,]  Inf  Inf
Warning message:
In project(coordinates(res), "+proj=utm +zone=17 ellps=WGS84") :
  14 projected point(s) not finite

Changed according to the suggestions below and now this is produced

> project(coordinates(res), '+proj=utm +zone=17 ellps=WGS84')
          [,1]     [,2]
 [1,] 762744.8 -1003824
 [2,] 761824.4 -1004402
 [3,] 762821.6 -1006069
 [4,] 764719.2 -1005559
 [5,] 766085.1 -1006890
 [6,] 767267.6 -1008219
 [7,] 764579.0 -1008263
 [8,] 762528.0 -1008895
 [9,] 766221.6 -1009319
[10,] 767189.3 -1010770
[11,] 764561.3 -1010906
[12,] 763505.8 -1013450
[13,] 766535.2 -1012641
[14,] 764213.9 -1012625

Which are undeniably wrong. The latitude should be positive and near 899####.


texts: OS X PYTHONPATH for QGIS Standalone Apps?

texts:
What's the correct PYTHONPATH for OS X and QGIS 3.4? I want to make a QGIS standalone app but get the "ModuleNotFoundError: No module named 'qgis'" error. This happens after following the OS X instructions at the end of Setting PythonPath.

OS X 10.11.6
QGIS 3.4.4
Python 3.6.8


texts: How to create a search box and SQL statement for searching an attribute field?

texts:
How can I add a HTML search bar that the user can use to search an attribute field for a polygon layer, and then tie that input into the SQL statement?

So far I am able to hard code the query  of sending a SQL statement and returning a answer using cartodb. My problem is figuring out how to  take the input from the search box and automatically inserting the input into the sql statement.

I am using Cartodb api.

 var sql = new cartodb.SQL({ user: 'jmann111' });
   sql.getBounds("select * from stations where station_nm like ='%" + user_input +"'").done(function(bounds) {
  map.fitBounds(bounds)
  });


texts: Looking for free sdk/lib/framework for UI for openlayers app

texts:
I'm looking for free UI lib/sdk/framework to make openlayers app that I can have the map in one panel , the layer control in other panel and maybe hovering tool bar (instead of putting buttons on the map).
Bottom line , I'm looking to easily and fast make good looking and practical UI wise app.
Thx!


texts: Speed up ST_Intersects with non-overlapping polygons in PostGIS

texts:
I have a large table of points that I want to intersect with a large table of polygons as follows:

SELECT ptid, polyid FROM points pt, polygons poly
WHERE ST_Intersects(pt.geom, poly.geom);

Is there a way to improve performance through telling ST_Intersects that a polygon table is non-overlapping and that I want a 1:1 match? That is, once an intersecting polygon is found, there is no need to check the remaining geometries.

The polygons are irregularly shaped, so the spatial index helps but there would still be performance gains through stopping after the first match.


texts: Selecting Census Block Groups inside Zip code using PostGIS?

texts:
I already have my data imported, problem is my SELECT statements aren't yielding the results I'm looking for. I specifically need all the Block Group multipolygons that are inside a Zip Code multipolygon so that all of the zip code is covered and no Block Group leaves the boundaries of the zip code.

Blue = Zip Code

Red = Block Group

&& -- bounding box

select blockgroups.the_geom
from blockgroups, zips
where zips.zip = '92656' AND zips.the_geom && blockgroups.the_geom;

ST_Contains

select blockgroups.the_geom
from blockgroups, zips
where zips.zip = '92656' AND zips.the_geom && blockgroups.the_geom
    AND ST_Contains(zips.the_geom,blockgroups.the_geom);

ST_Within

select blockgroups.the_geom
from blockgroups, zips
where zips.zip = '92656' AND blockgroups.the_geom && zips.the_geom
    AND ST_Within(blockgroups.the_geom, zips.the_geom);

ST_Intersects

select blockgroups.the_geom
from blockgroups, zips
where zips.zip = '92656' AND blockgroups.the_geom && zips.the_geom
    AND ST_Intersects(blockgroups.the_geom,zips.the_geom);

ST_Within + ST_Centroid

select blockgroups.the_geom
from blockgroups, zips
where zips.zip = '92656' AND blockgroups.the_geom && zips.the_geom
    AND ST_Within(ST_Centroid(blockgroups.the_geom),zips.the_geom);

If block group multipolygon does leave the boundary of the zip code, I would like it to be cut by the zip code boundary, resulting in a fully covered zip code by block groups.

@mapBaker had a good idea but still not exactly what I want. Using the centroid preserves the block group shapes, but still doesn't cover the entire zip boundary. Added screenshots of ST_Intersects and ST_Within + ST_Centroid


texts: Is it possible to have geoevent in its own cluster? On a multinode server config I have only been able to get the first machine to run geoevent.  When I go to /geoevent/manager on a machine that is another cluster I get an error No Service found. There is nothing in the log to indicate a problem and I have confirmed the extension is authorized. Server 10.3.1.  It appears that in order for geoevent to function it is dependent on the first server.  Anyone have a different experience?


texts: Translating DGN geometry to Esri File Geodatabase using FME?

texts:
I am trying to import geometry in dgn file to a point feature class in arcgis file geodatabase. I have a layer in dgn file 'baum' which bascially means trees. I want to store these features in CAD drawing to the corresponding point feature class in fgdb. Moreover there are two kinds of tree. so i have used the joiner filter. that works well.

now since dgn file have multiple geometry in one layer i should use geometry filter. this translates all 4741 features but the inspector doesnot show it. I am new to FME so please guide me.

below are some screenshots which could be helpful to correct me.


texts: Selecting visible features only of active layer in QGIS with Python?

texts:
I need to select features from the layer_1 which are inside a virtual polygon which is covering all features from layer_2.
I think one of the solution could be to zoom all features from layer_2 and select all visible features from the layer_1. Is it possible? Give me please some key words to search or simple example.
Another way to solve the problem might be to create covering polygon from layer_2 and then make a spatial query.
What do you think which way is better?


texts: openlayers change marker icon, size and offset after drawn

texts:
I'm having much trouble changing my (feature)marker icons 'on the fly'. The problem is that I use much different images and also need to change the offset.

So I iterate over every marker and make a new icon object with the latest data:

    if (iconImgUrl.indexOf('img/icons/icon_') != -1) {
        var size = config.numberPlateTail;
        var offset = new OpenLayers.Pixel(0, -size.h);
        var iconImg = new OpenLayers.Icon('/img/icons/marker_' + dataitem.numberplate + '.png', size, offset);
    } else {
        var size = config.iconSize;
        var offset = new OpenLayers.Pixel(-(size.w / 2), -size.h);
        var iconImg = new OpenLayers.Icon('/' + iconImgUrl, size, offset);
    }

Because I also want to change the offset, I can't use

icon.setUrl();
icon.setSize();

I tried to 'kill' the current icon object and change it for a new one and then try to force it to redraw the icon, but somehow the marker doesn't display after that.

In the update loop I have:

        tbPosition.features[i].marker.icon.destroy();
        tbPosition.features[i].marker.icon = iconImg;
        tbPosition.features[i].marker.draw();
        tbPosition.features[i].marker.icon.display(true);

and markers are created like:

 var feature = new OpenLayers.Feature(this.markers, new OpenLayers.LonLat(lat, lng));
 feature.data.icon = iconImg;
 var marker = feature.createMarker();
 this.markers.addMarker(marker);
 this.features.push(feature);

So, how do I change (or update) the complete icon object?


texts: Determine geograpic coordinates from one fixed location as accurately as possible without expensive hardware

texts:
I build a GPS disciplined oscillator and I need to set antenna coordinates in order to be able to operate it as accurately as possible.

What I need is a way to determine the geographic coordinates (in GPS reference frame) of a single fixed location (where the GPS antenna is placed).

This procedure will be done only once so:

no point in buying expensive hardware (although rent is an option).
hiring a professional to perform a single measurement, out of my budget.


texts: Show position on google map/earth, from gps data, using google API

texts: For those that have used google's API for mapping (google maps/earth), I would like to know if it is possible to develop an application to receive NMEA data from a gps receiver, extract position, and show online on a map from google map/earth.


texts: PostGIS: Change raster values depending on values from other raster

texts:
I have two rasters and I want to change all the values from "raster1" to 4, where they are larger than the values from "raster2" and to 0, where they are smaller.

So raster2 has only one value, which is 1.

raster1 has two values: 0,5 and 2

0,5 should change to 0 and 2 should change to 4

I tried with st_reclass and a case/when/else-argument, but then it changed ALL values to 0 or 4... Here's my code:

DROP TABLE IF EXISTS result_table;
CREATE TABLE result_table AS

SELECT
    p.id,
    case
        WHEN (pvc).value > (cvc).value
        THEN st_reclass(p.rast,1, '-999-999:4', '8BUI', NULL)
        ELSE st_reclass(p.rast,1, '-999-999:0', '8BUI', NULL)
    END AS rast
FROM
    raster1 as p,
    raster2 as c,
    (select st_valuecount(dcp.rast) as pvc from raster1 as dcp) as pp,
    (Select st_valuecount(dcubc.rast) as cvc from raster2 as dcubc) as cc;

Ok, I could just reclass the values without looking up the other raster, but I want to do this multiple times with different rasters and values.


texts: Which is the correct version of jetty-servlets.jar for GeoServer 2.6-RC1

texts:
I am trying to determine the correct version of jetty-servlets to install.  I have installed GeoServer 2.6-RC1.

Now I need to install jetty-servlets.jar to enable CORS as mentioned here:

http://www.eclipse.org/jetty/documentation/current/cross-origin-filter.html

It directs you to download the jetty-servlet here:

http://central.maven.org/maven2/org/eclipse/jetty/jetty-servlets/

Which is the correct version to download if I have installed GeoServer 2.6-RC1?


texts:
I'm creating a custom google map that has 125 markers plotted via a cms. When loading the map I get this message:

  Geocode was not successful for the following reason: OVER_QUERY_LIMIT

I'm pretty sure it's the way in which I've geocoded the markers.

How can I avoid these warnings and is there a more efficient way to geocode the results?

UPDATE: This is my attempt at Casey's answer, I'm just getting a blank page at the moment.

It doesn't really matter what the solution is as long as the markers load instantly and it's not breaking any terms & conditions.


texts: Fixing Runtime Error R6034: application has made attempt to load C runtime library incorrectly?

texts:
I just downloaded QGIS 2.0 and every time I open it I get this error message window popping up:

Does anyone know what this means or how I might be able to fix it?


texts: Translating grid to USGS .dem in C# via GDAL

texts:
I am attempting to translate ArcInfo binary grids to USGS DEM format (.dem). I have installed the GDAL .NET bindings thru this build installer. I can get to GDAL in my C# add-in I am working on. However, it seems that I cannot create a USGS DEM:

Gdal.AllRegister();
GDAL.Dataset originalImage = Gdal.Open("C:\\65587895\\hdr.adf", GDAL.Access.GA_ReadOnly);
Driver demDriver = Gdal.GetDriverByName("USGSDEM");

int x = originalImage.RasterXSize;
int y = originalImage.RasterYSize;

Dataset dsDem = demDriver.Create("C:\\Data\\65587895\\foo.dem", x, y, 1, DataType.GDT_Int16, null);

Gives the error:

System.ApplicationException: GDALDriver::Create() ... no create method implemented for this format.

I thought the USGSDEM format was read/write...am I wrong on that? The formats list says that creation of USGSDEM is supported, but a run of demDriver.GetMetadata(null) to get the metadata from the USGSDEM driver results in no return of DCAP_CREATE=YES, only DCAP_CREATECOPY=YES, which makes me cringe, thinking that indeed the GDALDriver::Create() method is not implemented for the USGSDEM format.

Any thoughts or experience with this? Any other thoughts on translating binary grids to DEMs?


texts: Extracting data from increasing, multi-concentric buffers around each focal point in a vector layer

texts:
I have a dataset (vector layer) with 150 focal points, each of them retaining an observation of several ecological variables (attributes). I want to extract data (sum and average of several variables) from increasing multi-concentric rings around each focal points (same radii for all points). For example, I want to start with radius=1 Km around all the points and get a table showing new values calculated over the buffer coverage. Then, I want to increase the radius to 5 Km, 10 Km, 50 Km, 100 Km, to get the relevant datasets.
(Eventually, I will have to perform more complex, separate statistical analyses from these tables).
Would it be possible by using QGIS?
I am new of GIS softwares and I have no idea how to handle this.


texts:
I'm trying to establish watershed outlets as points with two shape files that I have available;
i.The watersheds polygons
ii. The river network

As I said above I'm trying to define the outlets but due to geometry reasons of the river network (which touches the boundaries of the watershed) as a result I take the following pictures.

You can see that the true outlets can be defined but due to the geometry issues they cannot be separated as unique points with 1-1 relationship with the catchments.
Tried the smooth polygon and poly-line toolboxes and seem to be worked quite well.

Another issue is that when I'm trying to select only the catchments for experimentation it selects all the upstream points with the multiple attributes also in the table shared as multiple records. This issue partially solved by the "Multipart to Singlepart" toolbox and now I'm exploring the impacts in the attribute tables or how to solve any double or multi - records still remain


texts: Reset Python 3 Installation - ArcGIS Pro / QGIS

texts:
I am having an issue with both ArcGIS Pro and QGIS - both applications fail to consistently initialise / operate as intended when they do start up.

I have recently been trying to get Python 3 to work in my preferred IDE (PyScripter). After searching through many different Google results I managed to completely decimate my Python installation. I can use ArcMap 10.6 and Python 2.7 applications perfectly. PyScripter still works and I can create Tools as needed, however, whenever there is something requiring Python 3, these applications will not work.

QGIS - I have QGIS 3.4 Madeira installed and it will not open at all - I have uninstalled and re-installed it multiple times. I have also deleted the folders created during the install and tried to clear out all mentions of QGIS in the registry. I am assuming it is a Python error, due to the fact when QGIS is loading and the splash screen is describing the modules being loaded, the failure occurs when the "Starting Python" text appears.

ArcGIS Pro - I have installed Pro 2.4 on my machine. The system will load, however when I try to add data or run any tool at all the application will close with no warning error / notification. It is a straight crash. Again, I have completely uninstalled and re-installed it and even tried a repair. Same result each time.

Is there a way to restore my Python installations as intended for use with QGIS and ArcGIS Pro?

I am running Windows 10 64-bit.


texts: How to build .sid virtual raster catalog

texts:
I want to build raster catalog that would contain many .sid (MrSID) georeferenced rasters. I already successfully built such catalog with tiffs using gdalbuildvrt but when I try with .sid, every raster is its own band.
I presume problem is in gdal understanding MrSID compression, since importing individual images into QGIS works fine.
How can I build catalog for use in QGIS with these images without converting them?


texts: Sqlite insert java.sql.SQLException: [SQLITE_ERROR] SQL error or missing database (no such column: SRID)

texts:
I'm trying to connect to two DBs and then copy tables by inserting rows from one table to another through java using JDBC. I'm using sqlite-jdbc-3.7.2.jar plugin.The setup is in Eclipse Luna. I'm getting below error when I execute the java code. I queried it on SpatialiteGUI it works fine. Delete query is working fine, but insert. Similar to this issue but SRID is configured in my case, it's giving results in spatialite gui (as suggested by @BradHards).

pyspatialite: Connot insert geometry

java.sql.SQLException: [SQLITE_ERROR] SQL error or missing database (no such column: SRID)

    import java.sql.*;

    public class SegregateDB
    {
      public static void main( String args[] )
      {
          //Both DB have same table structure.

          try{
          Class.forName("org.sqlite.JDBC");

          String vanillaDBPath="C:\\all data\\MyBT\\NR dev\\jettyGeoHub\\BTPlantDB_sqlite\\vanilla.sqlite"; // target DB
          String PWAPath="C:\\all data\\MyBT\\NR dev\\jettyGeoHub\\BTPlantDB_sqlite\\BTPlantDB.sqlite"; // Source DB

          Connection connOldDb = DriverManager.getConnection("jdbc:sqlite:"+ PWAPath);
          //add connection to vanilla DB.

          //newDbName = newDbName + "auftraege.db";
          Connection connNewDb = DriverManager.getConnection("jdbc:sqlite:"+ vanillaDBPath);

          connNewDb.prepareStatement("ATTACH DATABASE \"" + PWAPath + "\" AS  pwa").execute();

          connNewDb.prepareStatement("ATTACH DATABASE \"" + vanillaDBPath + "\" AS  van").execute();

          connNewDb.prepareStatement("DELETE FROM van.attachment_ofl WHERE EXCHANGE_1141_CODE IN (SELECT EXCHANGE_1141_CODE FROM pwa.attachment_ofl);").execute();
          connNewDb.prepareStatement("insert into van.attachment_ofl select * from pwa.attachment_ofl;").execute();

          connNewDb.close();
          connOldDb.close();

          System.out.println("Operation done successfully");
          }
          catch(Exception e){
              System.err.println( e.getClass().getName() + ": " + e.getMessage() );
              System.exit(0);

          }
      }
    }


texts: What is the most "logical" route generating site (for Europe by car)?

texts:
What is the most logical route generating site do you think is out there? By logical I mean optimizing the driving time between two points.  (Not always is the fastest way to proceed found along the shortest routes, making use of main-ways and highways when needed.)

I tried Google Maps. It seems to make use of highways a lot. Bing Maps, Mapquest, and Map24 all have different calculation methods but they seem to not use highways as much as Google Maps. I mentioned "for Europe by car" because I would like to take a trip from københavn(denmark) to tekirdağ(turkey).


texts: Finding elevation differences between adjacent pixels in ArcGIS Desktop?

texts:
Is there a way to determine what the difference in elevation is between two adjacent pixels?

I am using an SRTM DEM to map faults.

I am using the vertical error (>16m) as a criterion for the difference in elevation to accurately map these faults.

There must be a more efficient way to do this than by using the i-tool.


texts:
I need to read a multiple netCDF4 files using python 3. The files are in different folder named 2019, 2018 with months and days. And the files have the same variables I use to read and plot it.

I can do that just for one file. How I can read all files and variable IR in all files in all folder?

path='/home/all/2019/03/25/Mmult_2.nc'
nc = netCDF4.Dataset('/home/all/2019/03/25/Mmult_2.nc')
IR=nc.variables['IR'][:]
plt.pcolormesh(IR)
plt.colorbar()
plt.show()


texts: Creating Routes in File Geodatabase gives ERROR 000732?

texts:
UPDATE: I solved this issue by circumventing it - I moved to using the "in_memory" work space which also has improved the speed of my tool. The only change I had to make was to manually calculate the "FRM" field as zero that I created in the rd4Route shape.

I've got a function that I use to determine what side of the street an address is on. Previously I created routes and located features along those routes in a shapefile and dbf table, and I'd like to be able to have the same functionality in a file geodatabase instead. However, once I change the location to the geodatabase I created, the tool will no longer successfully create a route event layer. There are three lines where I changed the location to the gdb, I left the original (pre gdb) code under each one of those lines. I got the following error and warning:

ERROR 000732: Input Route Features: Dataset C:\Users\Tyler\AppData\Local\ESRI\Desktop10.3\AssemblyCache\{7E9712E7-BFF6-420A-B125-F011DB68C687}\AddressingToolbarInstall.gdb\tempRoute does not exist or is not supported
WARNING 000725: Output Event Table: Dataset C:\Users\Tyler\AppData\Local\ESRI\Desktop10.3\AssemblyCache\{7E9712E7-BFF6-420A-B125-F011DB68C687}\AddressingToolbarInstall.gdb\tempTable already exists.
Failed to execute (LocateFeaturesAlongRoutes).

I attempted to heed these messages, but to no avail - overwriteOutput is already set to True and I was not able to create the routes in my various configurations.

#must have proper stru and rd selected first
def parityChecker(rEven):
    #||Copy road to temporary & emptied feature class||
    rd4Route = os.path.join(installFolder, "AddressingToolbarInstall.gdb\\rdForRoute")
    #rd4Route = os.path.join(installFolder, "rdForRoute.shp")

    if arcpy.Exists(rd4Route) and int(arcpy.management.GetCount(rd4Route)[0]) > 0:
        arcpy.management.DeleteFeatures(rd4Route)
    arcpy.management.CopyFeatures(roads.roadChoice, rd4Route)
    arcpy.management.AddField(rd4Route, "FRM", "DOUBLE")
    arcpy.management.AddField(rd4Route, "SHPLEN", "DOUBLE")
    #calc "FRM" field = 0
    arcpy.management.CalculateField(rd4Route, "SHPLEN", "!shape.length@feet!", "PYTHON_9.3")

    #||Make route from rd and locate stru along the rd||
    route = os.path.join(installFolder, "AddressingToolbarInstall.gdb\\tempRoute")
    #route = os.path.join(installFolder, "tempRoute.shp")

    routeDbf = os.path.join(installFolder, "AddressingToolbarInstall.gdb\\tempTable")
    #routeDbf = os.path.join(installFolder, "tempTable.dbf")
    if arcpy.Exists(route) and int(arcpy.management.GetCount(route)[0]) > 0:
        arcpy.management.DeleteFeatures(route)

    arcpy.CreateRoutes_lr(rd4Route, "StreetName", route, "TWO_FIELDS","FRM","SHPLEN","LOWER_LEFT", "","","NO_IGNORE")
    arcpy.LocateFeaturesAlongRoutes_lr(structures.struChoice, route, "StreetName", "5280 FEET", routeDbf, "RID POINT MEAS")


texts: Masking NetCDF data using shapefile (xarray & geopandas)

texts:
I am using the following packages:
import pandas as pd
import numpy as np
import xarray as xr
import geopandas as gpd

I have the following objects storing data:
print(precip_da)

Out[]:
    <xarray.DataArray 'precip' (time: 13665, latitude: 200, longitude: 220)>
    [601260000 values with dtype=float32]
    Coordinates:
      * longitude  (longitude) float32 35.024994 35.074997 35.125 35.175003 ...
      * latitude   (latitude) float32 5.0249977 5.074997 5.125 5.174999 ...
      * time       (time) datetime64[ns] 1981-01-01 1981-01-02 1981-01-03 ...
    Attributes:
        standard_name:       convective precipitation rate
        long_name:           Climate Hazards group InfraRed Precipitation with St...
        units:               mm/day
        time_step:           day
        geostatial_lat_min:  -50.0
        geostatial_lat_max:  50.0
        geostatial_lon_min:  -180.0
        geostatial_lon_max:  180.0

This looks as follows:
precip_da.mean(dim="time").plot()

I have my shapefile as a geopandas.GeoDataFrame which represents a polygon.
awash = gpd.read_file(shp_dir+"/Export_Output.shp")

awash
Out[]:
  OID_         Name      FolderPath  SymbolID  AltMode Base  Clamped Extruded  Snippet PopupInfo Shape_Leng  Shape_Area  geometry
0     0 Awash_Basin Awash_Basin.kml         0        0  0.0       -1        0     None      None  30.180944    9.411263  POLYGON Z ((41.78939511000004 11.5539922500000...

Which looks as follows:
awash.plot()

Plotted one on top of the other they look like this:
ax = awash.plot(alpha=0.2, color='black')
precip_da.mean(dim="time").plot(ax=ax,zorder=-1)

My question is, how do I mask the xarray.DataArray by checking if the lat-lon points lie INSIDE the shapefile stored as a geopandas.GeoDataFrame?
So I want ONLY the precipitation values (mm/day) which fall INSIDE that shapefile.
I want to do something like the following:
masked_precip = precip_da.within(awash)

OR
masked_precip = precip_da.loc[precip_da.isin(awash)]

EDIT
I have thought about using the rasterio.mask module but I don't know what format the input data needs to be. It sounds as if it does exactly the right thing:
"Creates a masked or filled array using input shapes. Pixels are masked or set to nodata outside the input shapes"


texts: How to use navteq information for turn restrictions in pgrouting?

texts:
I'm developing a pgrouting application using navteq information but I don't know  how to use the navteq information to add turn restriction in pgrouting. Even, I don't know where to find this kind of information in the navteq tables. I guess this data would be in condition/Driving Manoeuvres.

Also, I'm tried to figure out how to use the divider information to add some turn restrictions in pgrouting but I guess that must be another source of information in this tables (navteq) that can be more easy and useful for turn restrictions.


texts: ArcGIS Pro ModelBuilder iterate and lookup values/table for parameters?

texts:
I have a module I've written in the ModelBuilder that uses a few parameters.

I need to run this module on several raster files, each time with different parameters.

Is there a way to use the iterator and some kind of lookup table?

If I were using python i would create a dict where the filename is the key, and the parameters are stored as the value.

My whole project has the structure:

list of 10 countries, 10 shared data source
cut all data sources for each country
perform analysis with specific parameters for each country/data source
repeat for each country

so a version 1 would be to put step (3) into a separate lookup table for each country, a version 2 would be to stick all of it into single lookup table for each country/file combination.

I tried googling around, looking on here, looking on the iterator docs. and i couldnt find anything


texts: How do I check if Mapserver is installed or not?

texts:
I have installed MS4W (full) and choose port 8080 because on port 80 i have already installed IIS7. Now installation of MS4W is successful , but how i check ? I put http://localhost:8080/ in my browser, but i could not see the page.

any idea how to fix it ?


texts:
I am trying to load a layer after its creation, by using runadload(), but I am getting the error: AttributeError: module 'processing' has no attribute 'runandload'.

Here's the partial script:

processing.runandload("native:saveselectedfeatures", {
        'INPUT':boundary_layer,
        'OUTPUT':'memory:'})

I am on QGIS3.4 Mac version and the processing version is 2.12.99. I tested the same script on QGIS3.6 to no avail. Is it that runandload() has been replaced in version 3, and if yes, what is the substitute?


texts: QGIS 2.8+: How can layer.selectedFeatures() return an empty list while layer.selectedFeatureCount() returns the correct number of selected features?

texts:
I noticed some changes since qgis 2.8 but can't find any information about it.
Let's say I have a very simple point layer loaded in QGIS, from a spatialite table.
From this layer I select some points and want to count how many points I've got in my selection using a few PyQGIS lines.
Very simple:

layer = qgis.utils.iface.activeLayer()
nbrSelected=layer.selectedFeatureCount()
selection01 = layer.selectedFeatures()

What I've noticed is that if I select more than 999 features, nbrSelected still returns the correct number of points, but

len(selection01)

returns 0... the list is empty.

This wasn't happenning with QGIS 2.6 (I just checked again), but only on 2.8 and 2.10.

I tried on 2 different computers, with the same result.

Is there another way of browsing more than 1000 selected features? I also tried with the processing (processing.features(layer)) but it acts as if my selection was empty as well (i.e. returns the complete content of my layer, not just the selection).


texts: Geowebcache is does not seed from rest and web UI

texts:
I am trying CURL to seed geowebcache:

curl -v -u USERNAME:PASSWORD -XPOST -H "Content-type: text/xml" -d "<seedRequest><name>WORKSPACE:LAYER</name><srs><number>4326</number></srs><zoomStart>1</zoomStart><zoomStop>12</zoomStop><format>image/png</format><type>truncate</type><threadCount>2</threadCount></seedRequest>" "http://127.0.0.1:8090/geoserver/gwc/rest/seed/WORKSPACE:LAYER.xml"

this works like this:

But this command deletind all tiles cached via GWC demo page.

I tried seed type like this.

curl -v -u USERNAME:PASSWORD -XPOST -H "Content-type: text/xml" -d "<seedRequest><name>WORKSPACE:LAYER</name><srs><number>4326</number></srs><zoomStart>1</zoomStart><zoomStop>12</zoomStop><format>image/png</format><type>seed</type><threadCount>2</threadCount></seedRequest>" "http://127.0.0.1:8090/geoserver/gwc/rest/seed/WORKSPACE:LAYER.xml"

But no tile is creating on server. Disk quota is 0MB.

I am trying to create seed task from wen UI but not working.

Demo gwc page is working and creating tiles. And openlayers application is creting tiles.

But I caould not create qutomatically seed and create tiles.


texts: Loading raster in postgis and link it with an existing table

texts:
Relatively new to PostGIS and I am currently exploring the options to make one of my PostgreSQL Tables spatial. Essentially I want to store a raster object in a table that also contains essential metadata. Every raster in the database has to be uniquely linked to the ID´s and information stored in the table.

I was under the impression that I could just write the raster into the same table (similar as with vectors where I could just add geometry columns)? With a query like this I can only write a raster to a new (non-existing) table, thus creating hundreds of tables if my raster files vary in extent, origin and projection (very likely).:

raster2pgsql -s 32739 -I -C -F -M -Y myfile.tif -t 100x100 Map > rasQuery.sql
psql -U test -h localhost -d test -f rasQuery.sql

My existing table looks like this, where I created a raster column.

CREATE TABLE Map(
    id serial PRIMARY KEY,
    second_id INT references AreaOfInterest,
    RasterFile raster,
    RasterType char(250),
    RasterAuthor char(250),
    Acquisition date,
);

What is the standard way to load and link rasters with existing tables? raster2psql fails for me stating that the table map already exists, so I guess I have to specify a column as well? Or did I miss a mandatory command here?

The currently working alternative for me would be to just store the filepath in a text column in the Map Table.

Running PostgreSQL 9.4dev + PostGIS 2. on Debian Linux in a test-environment.

EDIT:
I am already a bit further.
After adding

rast raster,
filename raster,

to my table and the -a flag in front of map in the raster2pgsql command it returns some new errors.
Now it says:

 rt_raster_from_wkb: wkb size (9)  < min size (61)
CONTEXT:  COPY map, row 1, column filename: „myfile.tif“

Any ideas?


texts: Update a table with values from coordinates on GEOMETRY in Oracle

texts:
I have 2 columns in a table that represent the X and Y coordinates. The values in those columns don't match the actual coordinates and I want to update them with the coordinates values that are selected from the GEOMETRY column. I have been trying the following:

update TABLE1
set X = (SELECT t.X FROM TABLE1 Tb, table(SDO_UTIL.GETVERTICES(Tb.GEOMETRY )) t);

but I am getting the following error:

ORA-01427: single-row subquery returns more than one row

Any suggestions?


texts: Cannot run QGIS algorithm with python script without interface

texts:
I'm trying to run the QGIS 'intersection' algorithm from a Python script:
(Working with Ubuntu)

#!/usr/bin/env python
# -*- coding: UTF-8 -*-

import sys
from qgis.core import *
from PyQt4.QtGui import *

app = QApplication(sys.argv, False)
QgsApplication.setPrefixPath("/usr", True)
QgsApplication.initQgis()

sys.path.append('/usr/share/qgis/python/plugins')

from processing.core.Processing import Processing
Processing.initialize()
from processing.tools import *

processing.runalg("qgis:intersection","dbname='/path_to_DB/db1.sqlite' table='table1' (geometry) sql=","dbname='/path_to_DB/db2.sqlite' table='table2' (geometry) sql=","/path_to_output/output.shp")

I get the following error: "QPixmap: Cannot create a QPixmap when no GUI is being used".

I need my script to run without using a graphical interface.

Is there a problem with QApplication? Was it created to run exclusively with True as an argument?
Is the problem in my script?

I've looked at many related questions but couldn't find the solution:

Running PyQGIS script directly (without using interface)?
Standalone applications using QGIS and environment variables
Writing standalone Python scripts using PyQGIS?
Import error for qgis.core when running OSGeo4w shell script
...


texts: Changing coordinates of point (from local projected coordinate system to standard coordinate system)?

texts:
How can I convert the coordinates of a point from a projected CRS such as USER:100001, *Generated CRS (+proj=tmerc +lat_0=0 +lon_0=30 +k=0.9999 +x_0=500000 +y_0=5000000 +ellps=GRS 80 +units=m +no_defs, which we often use in our country back to WGS84 or UTM?

I use QGIS.


texts:
I have a table of points called features with 57k points

A table of small polygons called lsoa with 36k polygons

A table of large polygons called la with 316 polygons covering same area as lsoa

All three tables have a GIST spatial index

This query is relatively quick:-

SELECT count(feature_id)
FROM features
INNER JOIN LSOA ON ST_CONTAINS(lsoa_geom, feature_geom)

EXPLAIN tells me that the query planner is doing a seq_scan down the LSOA table and using the spatial index on LSOA as a filter

This query is REALLY slow

SELECT count(feature_id)
FROM features
INNER JOIN LA ON ST_CONTAINS(la_geom, feature_geom)

EXPLAIN shows a seq_scan down the features table using the LA spatial index as a filter

So both queries are using the indexes, but the some 100 times slower than the first.

I am not sure why the larger geometries make a difference?

My question is should I be using a different operator to ST_Contains for the 2nd query, or taking a different approach?

Here is the explain output for the LA query

Aggregate  (cost=31558.48..31558.49 rows=1 width=8)
  ->  Nested Loop  (cost=0.14..31542.19 rows=6515 width=8)
        ->  Seq Scan on features f  (cost=0.00..9744.33 rows=51433 width=40)
        ->  Index Scan using sidx_local_authority_boundary_geom on
             local_authority_boundary la  (cost=0.14..0.41 rows=1 width=80659)
              Index Cond: (st_transform(wkb_geometry, 4326) ~ f.wkb_geometry)
              Filter: _st_contains(st_transform(wkb_geometry, 4326), f.wkb_geometry)

(Note well the index has been created on a transformed geometry as the types differ between features and the other table)


texts: Allowing user to import any file in OpenLayers 3 map control?

texts:
I have started exploring the OpenLayers 3 library.

I have seen the examples but i am not able to find the way for import shapefile and load it on OpenLayers's map control.

I want give option for importing shapefile and render on the map control. something similar to browse the shapefile from client side and load it.


texts: I am just starting to use Qfield and QGIS. I have built a very nice form in QGIS which has a dial and a slider to input numeric data. When I import the project into QField the slider and dials are missing and I am left with a simple numeric data input field. Is Qfield unable to handle dials and sliders?


texts: Set default input Vector Features in model

texts: I have a Graphical Model with ~10 input Vector Features. Every time i execute it I have to set all 10 features manually. Isnt there a way to set default input values so I dont have to point at the same 10 feature classes each time?


texts: Looking for a tool to smooth edges of raster areas in QGIS

texts:
I am looking for a tool which helps me to smooth primarily edges/outgrowths of raster areas/zones in QGIS/GRASS/SAGA.

I particular, regarding the image below, I would like to reduce the single lines (mostly probabilistic errors derived from modelling) on the edges (dark grey for better visibility), but no/least changes within the bright grey area.

I tried tools like GDAL sieve, SAGA majority filter and several tools of the LecoS Plugin (which is great, btw). Infortunately these tools also change the values within my perimeter(as the bright grey area is not a zone itself). Further, I could creat a binary raster (1 inside the zone and 0 or nodata for the 0-values). I could then smooth it using a nearest neighbour/moving window analysis. Creating a model would work, but:

If possible, I'd prefer "one-step" tool.

As I am a beginner to QGIS (GIS in general), for now I try to avoid using programming language.


texts: Can OpenLayers2 render a completely custom font-face in a text or point symbolizer?

texts:
I am trying to style a feature using a custom font.

Geoserver has an extension allowing external graphics in SLD to be defined by a font.  OpenLayers doesn't appear to support this particular Geoserver SLD extension.  Should OpenLayers.Format.SLD.v1_0_0_GeoServer do this? I did't see anything in that class to indicate it would.

If not, is there some other way to get open layers to load a true type font from an external resource?  I'm thinking something along the lines of CSS3 @font-face which would then make the font available when styles are created in the the many ways OL provides.

As a last resort, I could export all the glyphs in the font to SVG, but I would rather avoid that if possible.

EDIT:

Several OpenLayers examples involve client side feature styling:

Vector Behavior Example
Styled Layer Descriptor (SLD) Example

Geoserver provides an SLD extension that allows the use of TTF marks to style data.  It's not clear to me if OpenLayers allows this or not.

For example, could OpenLayers consume an SLD with a point symbolizer like:

 <PointSymbolizer>
        <Graphic>
          <Mark>
            <WellKnownName>ttf://Webdings#0x0064</WellKnownName>
            <Fill>
              <CssParameter name="fill">
                <ogc:PropertyName>#0000ff</CssParameter>
            </Fill>
            <Stroke>
              <CssParameter name="stroke">#ff00ff</CssParameter>
            </Stroke>
          </Mark>
          <Size> 45 </Size>
          <Rotation> 0 </Rotation>
        </Graphic>
      </PointSymbolizer>

which works fine in Geoserver.
If OpenLayers could do this, it would seem that either the font would have to be on a search path somehow.


texts:
I downloaded .shp files from Diva-Gis (EPSG:4326) representing the map of Germany in order to use them in Mapbox Studio. I did conversion via ogr2ogr like that:

ogr2ogr -f "PostgreSQL" PG:"host=localhost user=michalvantuch dbname=postgis_database" -t_srs EPSG:900913 -nlt PROMOTE_TO_MULTI /Users/michalvantuch/Desktop/skuska\ ogr2ogr/DEU_adm0.shp

I want to have coordinates in geometric system with SRID 900913. But what I've got instead is 900914 in geometry_columns. I want to do something like getting the shortest distance between two cities in (k)m

SELECT ST_DISTANCE(
 ST_GeometryFromText('POINT(980421.735630649 6997024.59849449)'),
 ST_GeometryFromText('POINT(1113063.06112784 7085437.74331884)')
);

but so far it gives me nonsense value.


texts: Editing shapefile in Excel without losing points for ArcMap?

texts:
I have a point shapefile with a lot of data that needs to be cleaned up. I'd much prefer to work with the table in Excel. When I use the "Table to Excel" tool, I can get the data into Excel, but when I use the "Excel to Table" tool to bring it back into ArcMap, I lose the points. The "Shape*" field is gone!

Is there any way to edit shapefile data in Excel without losing the points? Or do I just have to make my changes in ArcMap?


texts: Getting rectangle coordinates created in custom QgsMapTool Class of PyQGIS?

texts:
I am developing a QGIS (QGIS 3.6) dockwidget plugin where the user creates a rectangle (boundingbox) on the canvas and the plugin sends the rectangles coordinates attached to a HTTP request to my FME Server.

There is the main class SmallworldDataExtractorDockWidget and another class RectangleMapTool. In SmallworldDataExtractorDockWidget the general plugin functionalities are defined, in RectangleMapTool I create a custom QgsMapTool for creating the boundingbox in the canvas.

The creation of the boundingbox itself works and the RectangleMapTool can print the rectangle extent.

Now I am struggling in accessing the extent in the main class SmallworldDataExtractorDockWidget, where I want to associate the extent to variables and display the extent coordinates in input fields.

What I have tried:

First try: In class RectangleMaptool:

def canvasReleaseEvent(self, e):
        self.isEmittingPoint = False
        r = self.rectangle()
        if r is not None:
            print("Rectangle:", r.xMinimum(), r.yMinimum(), r.xMaximum(), r.yMaximum())
            SmallworldDataExtractorDockWidget().minx_input.setText(r.xMinimum())

Error: RuntimeError: wrapped C/C++ object of type QLineEdit has been deleted

Second try: In class RectangleMaptool:

def canvasReleaseEvent(self, e):
    self.isEmittingPoint = False
    r = self.rectangle()
    if r is not None:
        print("Rectangle:", r.xMinimum(), r.yMinimum(), r.xMaximum(), r.yMaximum())
        self.result = r

and in class SmallworldDataExtractorDockWidget

def __init__(self, parent=None):
        """Constructor."""
        super(SmallworldDataExtractorDockWidget, self).__init__(parent)
        #some code
        #some code
        #some code
        self.maptool = RectangleMapTool(iface.mapCanvas())
        self.maptool.canvasClicked.connect(self.temp_box)

def temp_box(self, r):
        print(self.maptool.result)

Without any output...


texts: How to include 3D break lines in QGIS raster interpolation

texts:
I wish to add a break line to an interpolation of a set of survey points to simulate an elevated ridge in the survey area.  Using QGIS 2.6 on Windows 7.

I have created a polyline shapefile with a numeric field for the z attribute, and have included this field in the interpolation with type set to break lines (see screenshot), however the interpolation ignores the break line.

What confuses me is that the interpolation works fine with the point elevation which is also an explicit field (i.e. you have to tell the interpolation to use) but not the break line.

Do I need to create a true 3D polyline to use as the break line, and if so can I do this in QGIS?


texts: How to use multiple graphics layers in ArcEngine?

texts:
My organization is working on an ArcEngine application that displays a GPS cursor for the user's current position. We are using custom-made GPS code since ESRI's is buggy in ArcGIS 10. Whenever the GPS cursor's position changes, the entire graphics layer redraws rather than just the cursor. This results in a map whose labels are constantly flashing as the cursor moves. We are pretty sure that the problem is caused by having the GPS cursor displaying on the same graphics layer as the labels and any other graphics, but we haven't had any luck finding a way to use multiple graphics layers.

Is there a way to have multiple graphics layers in ArcEngine 10?


texts: Import data from a csv file to existing table cartodb

texts: I am trying to add data to an existing CartoDB table from a local csv file. Using Import API creates a new table. How can I specify to add data to existing table instead of new table?


texts:
Working in v10.3, I have a .gdb with two layers; a point layer and an annotation layer. The dataset was handed to me a few days ago, and I have been editing and adding points to the point layer daily. But now, the layer doesn't load properly; all data point seem to plot on the map, but the attribute table is only showing 59 of 82 records, I get an error message when I add a definition query ("Error reading OID from table. Reading rows has been stopped. Check that the datasource is valid."). Did I break it?

I tried bringing the layer into a blank map and exporting all the data points to another layer.


texts: Extracting value from one raster to another raster using QGIS

texts:
I have one raster containing information of land cover classification (0 for other land covers, 1 for my specific land cover), the second raster contains info about the LAI and the Chlorophyll Content (CC).

What I want to do is to extract info from my second raster, so the LAI and CC values are assigned to my specific land cover in raster one.

Any idea how to do that in QGIS?


texts: Installing third-party Python Packages to Work With ArcPy and ArcGIS Pro?

texts:
My employer does not grant me permissions to use Python package managers like pip or conda since the websites that host these data are blocked.  In ArcMap 10.x I have been able to install third-party python packages (like simpkml, easygui, pyexiv2,or PIL) by downloading the files, use 7-Zip to crack into the files, and locate the Setup.py file.  Once I locate the Setup.py file I can open a command window in that location, tell Windows to use path=%path%;C:\Python\27\ArcGIS10.5  then Python Setup.py install to install the package. Then I am free to write code that imports arcpy as well as other libraries without fuss.

This trick does not work with the ArcGIS Pro version of Python 3 since the Python.exe file and the ArcPy library are stored in a locked directory with read only permissions.

Using this information I have created a second Python environment to install third-party packages but there is no Python.exe file in this newly created environment so again, my trick fails to install.

I understand that I can use the ArcGIS Pro Python Package Manager to install some packages but the ones I want to install on not in ESRI list of packages.

How do I install third-party packages so that I can use them in the same version of Python that stores ArcPy?


texts:
I have a map automation script that I have been using in ArcMap 10.5 with Python 2.7. I just learned the in's and out's of ArcGIS for Pro and would like to migrate my processing to Pro. It's taking a while to migrate the Python 2.7 code into something that will take in the Python 3 module of Pro, but I think for the most part, I've been able to translate my code.

With the exception of a couple of arcpy functions, so I wanted to see if anyone had any insight into how to do something. In my code, after selecting certain features, I have the code (2.7) use:

df.zoomToSelectedFeatures()

When I try to run this in Pro, it doesn't like it. It appears that "zoomToSelectedFeatures" is no longer supported in Python 3? Does anyone know a workaround to move the map automatically to the selected features in an automation script?


texts:
Does anyone know if it is possible to get Spatialite running on Android? Specifically for either Android 2.1 or 2.2.

I've been browsing the web, and although it seems technically possible, I haven't been able to find any procedures,tutorials,examples...etc to accomplish this.  I'm new to Android development, so the simpler the instructions the better.

Any tips,comments,warnings welcome.


texts: Calculate percentage covered by green space in a city using QGIS

texts:
I want to calculate how much percentage of a city district is covered by public green space. I have a city polygon with 10 different city districts and 10 layers showing public green space in different layers. I have also calculated the area of each park and each city district, but not the sum of the parks within the districts.

Is there an easy way to do this?
It is also worth mentioning that my aim is to make a thematic map after I have gotten the results.


texts: Adding marker with specific functions on OpenLayers?

texts:
I am new with OpenLayers, my problem seemed easy, but I have troubles with that. I am trying to make some markers when the map loads up, I need 3 of them lets  say and also I have some callback from menu to actually disable them, but if needed I would then also like to add them back. I have this functions, but I am not even able to make them before. This function is made to work when you click on some point it will make there waypoint, but even when giving the specific GPS coordinates it will not make it.

    function removeMarker(obj) {
  vectorLayer.getSource().removeFeature(obj.data.marker);
}

function marker(obj) {
  var coord4326 = ol.proj.transform(obj.coordinate, 'EPSG:3857', 'EPSG:4326'),
      template = 'Coordinate is ({x} | {y})',
      iconStyle = new ol.style.Style({
        image: new ol.style.Icon({ scale: .6, src: 'images/pin_drop.png' }),
        text: new ol.style.Text({
          offsetY: 25,
          text: ol.coordinate.format(coord4326, template, 2),
          font: '15px Open Sans,sans-serif',
          fill: new ol.style.Fill({ color: '#111' }),
          stroke: new ol.style.Stroke({ color: '#eee', width: 2 })
        })
      }),
      feature = new ol.Feature({
        type: 'removable',
        geometry: new ol.geom.Point(obj.coordinate)
      });

  feature.setStyle(iconStyle);
  vectorLayer.getSource().addFeature(feature);
}

Solved !
SOLUTION = https://wiki.openstreetmap.org/wiki/Openlayers_POI_layer_example


texts: Get a geometry point along a line from another point with distance using OGC SFSQL

texts:
I am wondering is that any quick OGC SFSQL function (or any other spatial query) which return a geometry point that:

The point is x distance along a line from its A-End ?

ps: I am using postgis 2.x


texts: Determining ridgeline from DEM using ArcGIS Desktop?

texts:
I want to derive ridgelines from DEM using ArcGIS 10.4. I have tried to use the watershed analysis procedure but the result I have obtained looks weird.

How can I get the ridgelines shapefile?


texts: Delete tables from SDE including archive-tables

texts:
I want to delete some tables from my SDE as well as some featureclasses located in a feature-dataset. As some of those tables and featureClasses are enabled for archiving I get both the base-table/FC and its archive in two seperate steps. However I wonder if I cannot get both in one single step?

This is the code I currently use (step 1)

result = arcpy.ListTables(user + ".KS*")       # get the tables beginning with KS
for ds in arcpy.ListDatasets(user + ".KOM_*"): # get the FDS beginning with KOM
    for fc in arcpy.ListFeatureClasses(None, None, ds):
        result.extend([fc])
    result.extend([ds])

Now I want to append all the archive-tables also (step 2):

for ds in result:
    if arcpy.Describe(ds).IsArchived: result.extend([ds])

However this loop never terminates. Obviously everytime we find an archived table we add it to the result and re-iterate the whole loop.

After all I delete all the datasets within my list using

for ds in result:
    arcpy.Delete_management(ds)

Does anyone know how I may add the archive-tables also to my list?


texts:
I am new for handling lidar data. Actually I am  using laspy for read and write laz file. I am using following syntax for writing LAZ file. It is created LAZ file on specified folder path but it took more size comparing with the input LAZ (Ex: input laz 50 mb , Output LAZ 450 mb ).
How do I resolve this?
        output_File="c:\test.LAZ"
        out_file = laspy.file.File(output_File, mode = "w", header=in_file.header)
        out_file.points = point_records
        out_file.close()


texts: gdal2tiles.py problem - creating mini tiles

texts:
I have a similar problem to the issue posted here (gdal2tiles problem).

I have 80 GeoTIFFs (4000x4000) with EPSG:27700 projection embedded and TFW and PRJ files.  These I have built into a virtual raster using gdalbuildvrt which creates a 10x10 tile image that is 40000x40000 pixels.

Using gdal2tiles I can create a set of tiles for specific zoom levels.  In this case I am using the Ordnance Survey VectorMap District and 25K raster tiles and I want zoom levels 7, 8 and 9.  The problem is that zoom levels 8 and 9 work perfectly creating 97969 tiles at zoom level 9 and 24649 tiles at zoom level 8.  Zoom level 7 creates the correct number of tiles but the output images consist of a "mini" thumbnail in the top left corner and the rest of the image is transparent/white.

Why does it work for 8 and 9 and not 7?
Should I resize the image to fit nicely into 256x256 squares?

See the images attached below:


texts: Are Australian Height Datum and GDA94 applicable to Christmas, Lord Howe, and Norfolk islands?

texts:
I've been asked to recommend a mapping coordinate reference frame for use for Australian mapping, which I've said AHD for the vertical component and GDA94 for the the horizontal component.

However, I'm not sure whether they cover all the islands/territories around Australia.

For islands that are not closely adjacent, but are nevertheless administratively part of Australia (e.g Christmas, Lord Howe, and Norfolk islands) what would they use if not the same as Australia?


texts:
I am trying to move a label's position in order to show the blue polygon as pictured below. The label crosses other polygons (the blue polygon) that I must present in the map. The label is part of another polygon that I don't show in the map and only show it label (number 3922).

My goal is to move the label (3922), so the blue line polygon will be shown clearly. How can I do this in ArcGIS?

I know how to edit it by:

convert it to graphics
convert the label to annotation

I am seeking other ways of doing this.


texts:
I am new to GIS and QGIS software.

is there a batch convert function to convert shape files to mif/mid files?

I can do this individually but is time consuming?
I have seen similar functions on here to other formats but i cannot convert them for my needs. ie create both mif + mid files.

Is there a plugin?

I use windows 8. My output folder is C:\Data\Submit

I am looking for something simple like this;
Exporting several files at same time in QGIS?


texts: GeoServer imageIOCache warning won't go away

texts:
We are running GeoServer 2.15 and we keep seeing this warning message on some pages saying "The "Coverage Access" page "ImageIO Cache Memory Threshold" is unset, and can cause a severe performance penalty when seeding tiles. A value of 1024K should suffice for the most common tile sizes."

While there doesn't seem to be a "Coverage Access" page, there is a "Raster Access" page with a setting for "ImageIO cache memory threshold (KB)" but no matter what we set that to and click Submit, the warning refuses to go away. What are we doing wrong here?


texts: How to get pixel values of indvidual pixels falling under a poygon to shapefile attribute table or CSV?

texts:
I want to be able to write pixel values of each pixel falling under a polygon onto a polygon attribute table or a CSV. I have about 1200 polygons and a georefernced GeoTiff file with NDVI values. While I understand there are many tools available to calculate zonal stats and I have tried zonal statistics, LecoS and rasterstats plugin (all QGIS), they all provide only summary statistics (mean, median, min, max, etc.) but not individual pixel values.  So pretty much are of no use here. I also took a look at rasterstats source code but could not find a quick way to modify the zonal output parameters to suit my needs. So I'm wondering if there is a GDAL, QGIS, python based solution out there?

TL;DR: I would like to write pixel values of all the pixels falling under a poylgon onto a CSV or a shapefile attribute table (1200 polygons).


texts: How to deploy a Custom ArcGIS Pro Configuration?

texts:
I have created a Custom ArcGIS Pro Configuration by customizing this sample: https://github.com/Esri/arcgis-pro-sdk-community-samples/tree/master/Framework/ConfigWithMap

This is working as expected on my System.

I now wish to deploy this Configuration to all GIS workstations in my company, and set up ArcGIS Pro to use this as the default configuration.

How Do I do this?


texts: Cannot get transparent tiles when using gdal2tiles on a GeoTIFF

texts:
I have this GeoTIFF generated through UAV mapping. It has 4 bands: red, green, blue and alpha. I've been trying to use gdal2tiles to use this geotiff as a basemap on a Leaflet project.

The thing is I cant get the alpha band to be transparent on Leaflet as it is on QGIS.

This is how it looks on QGIS

And this it how it looks on Leaflet

Here we have the raster info:

Driver: GTiff/GeoTIFF
Files: input.tif
Size is 64957, 74080
Coordinate System is:
GEOGCRS["WGS 84",
    DATUM["World Geodetic System 1984",
        ELLIPSOID["WGS 84",6378137,298.25722356049,
            LENGTHUNIT["metre",1]]],
    PRIMEM["Greenwich",0,
        ANGLEUNIT["degree",0.0174532925199433]],
    CS[ellipsoidal,2],
        AXIS["geodetic latitude (Lat)",north,
            ORDER[1],
            ANGLEUNIT["degree",0.0174532925199433]],
        AXIS["geodetic longitude (Lon)",east,
            ORDER[2],
            ANGLEUNIT["degree",0.0174532925199433]],
    ID["EPSG",4326]]
Data axis to CRS axis mapping: 2,1
Origin = (-51.468682631840061,-21.737483235282060)
Pixel Size = (0.000000603929836,-0.000000603929836)
Metadata:
  AREA_OR_POINT=Area
Image Structure Metadata:
  INTERLEAVE=PIXEL
Corner Coordinates:
Upper Left  ( -51.4686826, -21.7374832) ( 51d28' 7.26"W, 21d44'14.94"S)
Lower Left  ( -51.4686826, -21.7822224) ( 51d28' 7.26"W, 21d46'56.00"S)
Upper Right ( -51.4294532, -21.7374832) ( 51d25'46.03"W, 21d44'14.94"S)
Lower Right ( -51.4294532, -21.7822224) ( 51d25'46.03"W, 21d46'56.00"S)
Center      ( -51.4490679, -21.7598528) ( 51d26'56.64"W, 21d45'35.47"S)
Band 1 Block=64957x1 Type=Byte, ColorInterp=Red
  Minimum=1.000, Maximum=255.000, Mean=171.735, StdDev=87.606
  NoData Value=0
  Metadata:
    STATISTICS_MAXIMUM=255
    STATISTICS_MEAN=171.73513846298
    STATISTICS_MINIMUM=1
    STATISTICS_STDDEV=87.605566410796
    STATISTICS_VALID_PERCENT=99.98
Band 2 Block=64957x1 Type=Byte, ColorInterp=Green
  Minimum=1.000, Maximum=255.000, Mean=169.218, StdDev=88.007
  NoData Value=0
  Metadata:
    STATISTICS_MAXIMUM=255
    STATISTICS_MEAN=169.21831334207
    STATISTICS_MINIMUM=1
    STATISTICS_STDDEV=88.007452394777
    STATISTICS_VALID_PERCENT=99.98
Band 3 Block=64957x1 Type=Byte, ColorInterp=Blue
  Minimum=1.000, Maximum=255.000, Mean=156.433, StdDev=96.602
  NoData Value=0
  Metadata:
    STATISTICS_MAXIMUM=255
    STATISTICS_MEAN=156.43343641947
    STATISTICS_MINIMUM=1
    STATISTICS_STDDEV=96.601623969202
    STATISTICS_VALID_PERCENT=99.91
Band 4 Block=64957x1 Type=Byte, ColorInterp=Alpha
  Minimum=255.000, Maximum=255.000, Mean=255.000, StdDev=0.000
  NoData Value=0
  Metadata:
    STATISTICS_MAXIMUM=255
    STATISTICS_MEAN=255
    STATISTICS_MINIMUM=255
    STATISTICS_STDDEV=0
    STATISTICS_VALID_PERCENT=53.82

I've used the following parameters:

python3 -m gdal2tiles -p mercator -z 15-22 -w all -r average -a 255.0 input.tif output_folder

Do you have any hints on what am I missing?


texts: Flatten / collapse one-to-many table and keep the 'many' attributes separate

texts:
I have a data set that contains intersection data.  Each intersection node has up to 6 links which is identified by IN_LINK and OUT_LINK attributes.  I want to create a new dataset that includes the intersection node value (NODE) and all of its accompanying links as a single record.

[NODE] [LINK_1] [LINK_2] etc...
 5465    45687    9831    etc...

How would I code this in python?


texts: Original raster is rotated after processing in ArcGIS without reprojection

texts:
I have a regular TIF raster with georeferencing stored as .wld and .prj files. The raster itself has horizontal orientation (see pic.1), although after being opened in ArcGIS it becomes rotated due to projection information (see. pic2.).

The problem is that after applying pan-sharpening in ArcGIS (without any reprojection) the output becomes a GeoTIFF with this rotation fixed in raster. So this procedure adds unwanted rotation (see pic 2.) into original raster and I cannot process it further in other software.

The question is: is there any way to output result raster not as GeoTIFF but as regular TIF with .wld and .prj files, like it was before (see pic. 1), to keep an original alignment?

pic 1.

pic 2.


texts: QGIS 3 field calculator- hide name of one field (column/attribute)

texts:
My code:

CASE
WHEN length("Straße/Nr.")>0 THEN ( ( 'Name: '+ "Name" ) +'
'+  ( 'Straße: ' + "Straße/Nr." ) +'
'+ ('Religion: ' + "Religion" ) +'
'+ (  'URL: '+  "URL" ) )
WHEN length("Name")>0 THEN( ( 'Name: '+ "Name" )  +'
'+ ('Religion: ' + "Religion" ) +'
'+ (  'URL: '+  "URL" ) )
WHEN length("Religion")>0 THEN(  ('Religion: ' + "Religion" ) +'
'+ (  'URL: '+  "URL" ) )
WHEN length("URL")>0 THEN( (  'URL: '+  "URL" ))
END

Result:

All is OK, but one problem:
How can I hide "URL: " if there are no content?

I have different results in my popups of qgis2web: Sometimes I have no value for URL or sometimes no value for Religion. All ok. Only the "URL:" is my problem.

Any ideas?


texts: Converting xyz files with spatialite_dem

texts:
I am trying to convert textual xyz coordinates to spatialite with spatialite_dem:
$ spatialite_dem --srid 3346 -ddem all.db -create_dem  all.xyz 2>&1 | head -1
unknown argument: all.xyz

Suggestion from @user30184 doesn't work either:
$ spatialite_dem --srid 3346 -ddem all.sqlite -tdem test -gdem geom -create_dem  -d all.xyz
        - 'VirtualXPath'        [XML Path Language - XPath]
Segmentation fault
$

I compiled spatialite with debug symbols (-g) and found that it assumes all.xyz is a directory. If I replace it with ., it will create an empty-ish result file.
For reference, data looks as follows:
$ head -3 all.xyz
500199.420,6150000.000,60.178
500214.420,6150000.000,60.158
500730.220,6150000.000,59.629

The help and manual pages are not helpful. How can I create a spatialite database from XYZ files using spatialite_dem?
Alternatively, I could do it manually (CREATE TABLE points(<...>), .import all.xyz points, followed by a conversion to a geometry), but looks like spatialite_dem should do it out of the box.
How?


texts: Extracting area of DEM above where 60% of region lies using ArcGIS Desktop?

texts:
I have a DEM of a mountainous region. I'd like to extract the areas of the DEM above which 60% of the total DEM area lies. So, essentially I'd like to extract the areas representing upper portions of the mountains.

I've heard of this referred to as the hypsometric line (H60 line), but haven't been able to locate any documentation on how to achieve it.

My instinct is to somehow calculate the statistics of the DEM to tell me where the 60%-level is and then contour the DEM at this elevation. I can then clip the DEM by this contour and perform my calculations on the output DEM subsets.

How do I determine this 60% level?


texts: I want to clip a shapefile in QGis (las palmas) but I get an error:  global name 'features' is not defined See log for more details; what do I do wrong?


texts:
I am a little bit stack here.

I want to serve a background tif using geoserver and I don't know which is the best way in terms of efficiency. My raster is 1-band GTiff UInt16 with height/terrain values. I don't care about displaying the values, I just only need them for visualization purposes.

Option A) Associate a color-ramp from a text file using gdaldem and serve the image as Type: Byte, 3-band RGB, GTiff and let geoserver display it by using the following sld code:

RasterSymbolizer>
 <ChannelSelection>
  <RedChannel>
  <SourceChannelName>1</SourceChannelName>
  </RedChannel>
  <GreenChannel>
  <SourceChannelName>2</SourceChannelName>
  </GreenChannel>
  <BlueChannel>
  <SourceChannelName>3</SourceChannelName>
  </BlueChannel>
 </ChannelSelection>
</RasterSymbolizer>

Option B) Uploading into geoserver the 1-band, Type: UInt16, original raster and then apply a color-ramp by using a style/SLD code on raster values.

Which is faster? more efficient?


texts: MongoDB Error Code 16755 - Can't extract geo keys for duplicate vertices and edge crossing

texts:
When I try to create an index on geometry db.polygons.createIndex({"geometry":"2dsphere"}), it stops at a certain polygon with the error code 16755. It says it Can't extract geo keys and then either Duplicate vertices: 18 and 20 or Edges 16 and 18 cross.

It's nice that MongoDB points out where the problem is. I then go manually remove these nodes in QGIS and re-try the process, only to find there's another polygon with the same issue.

How can I fix this issue without having to repeat the entire process of fixing polygons > uploading to MongoDB > and then attempting to create the index?

Is there a way I can find out how many polygons have this issue? How many of them are malformed according to MongoDB?

edit: I should note that I'm dealing with 25,000 polygons. Hence it would be nice to have a list of all the malformed polygons that MongoDB rejects.


texts: How to calculate Standard Deviation in Zonal Analysis Using Python

texts:
I am attempting to use the following code to calculate standard deviation:

QgsZonalStatistics (QgsVectorLayer *polygonLayer, QgsRasterLayer *rasterLayer, const QString &attributePrefix="", int rasterBand=1, QgsZonalStatistics::Statistics)

But it is only giving mean and count. How do I get SD?


texts: I have multiple points at the same position which I want to merge

texts: I have multiple points at the same geographical position that represent pick up points for a goods vehicle. There are approximately 8 fields of data for each point as the attribution, eg date, time, type of freight etc. I want to be able to merge all the points together so I have a single point with multiple rows of data so if you click on that point, you see all the incidents of pick up at that point.


texts: Cannot load MapService from ArcGIS Server in Javascript API

texts:
I am trying to put together a very basic sandbox app to load data from a public ArcGIS Server MapService using the Javascript 3.5 API.

However I keep getting the a 400 return status with the error "Output format not supported"

The code is as follows:

<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">

<meta name="viewport" content="initial-scale=1, maximum-scale=1,user-scalable=no">
<title>Simple Image Service</title>
<link rel="stylesheet" href="https://js.arcgis.com/3.25/esri/css/esri.css" />
<style>
  html, body, #map { height: 100%; width: 100%; margin: 0; padding: 0; }
</style>
<script src="https://js.arcgis.com/3.25/"></script>
<script>
  var map;
  require([
    "esri/map", "esri/layers/ArcGISImageServiceLayer",
    "esri/layers/ImageServiceParameters", "dojo/parser", "dojo/domReady!"
  ], function(
    Map, ArcGISImageServiceLayer,
    ImageServiceParameters, parser
  ) {
    parser.parse();

    map = new Map("map", {
      basemap: "topo",
      center: [-79.40, 43.64],
      zoom: 12
    });

    var params = new ImageServiceParameters();
    params.noData = 0;
    var imageServiceLayer = new ArcGISImageServiceLayer("https://clientsServer/arcgis/rest/services/TEST/MyMapService/MapServer", {
      imageServiceParameters: params,
      opacity: 0.75
    });
    map.addLayer(imageServiceLayer);
  });
</script>
</head>
<body>
<div id="map"> </div>
</body>
</html>

Here is a screen shot of the Network tab in the dev tools

I tried using the following but they also didn't display (I'm not sure what they mean, just found then in another post)

https://clientsServer/arcgis/rest/services/TEST/MyMapService/MapServer/export
https://clientsServer/arcgis/rest/services/TEST/MyMapService/MapServer/tile

Most simple sandbox app ever, and already scratching my head....  :o(

Any help greatefully recieved


texts:
I am just starting to experiment with writing python scripts. I have been using QGIS and the Osgeo4w shell for sometime now.

I would like to be able to call Gdal from the python IDE i have installed (spyder).

Does anybody have any suggestions in getting this to work? I have QGIS with OSgeo installed and Spyder on windows 7.


texts: Calculate X & Y projected values from a table into another projection with QGIS

texts:
I have a entities layer in projection A with positionned labels coordinates based on X,Y and Rotation angle in the attribute table :

ETIKT_X, ETIKT_Y, ETIKT_ROTA

Those labels are defined into the geometry displayed, I have positionned manually those labels with QGIS label tools and data defined attributes.

Now, I wish to reproject my layer in projection B but, if I do that, my labels will still be in projection A and therefore will not appear correctly.

My actual manual solution is :

Use "Point from table" tool to create points in my label position in projection A
Project my label point layer from projection A to B
Calculate $x and $y of my projected points into my attribute table
Project my layer from projection A to B
Join my label point layer to my layer and update the label X and Y field with my proj B calculated values.

Is there a already-made tool in QGIS that can do that without doing all this manipulation ?

If not, I think I'll try to make a processing script that will take as argument : "X field", "Y field", "proj A code" and "proj B code", optionnaly X and Y new Proj B field and do the automation of my process. I'll put it into a solution if I manage to do it.


texts: Points of drillhole data to 3D lines in GRASS

texts:
In GRASS 7.0 I have a 3D vector file which are several SPT drill holes, with the NSPT values at each interval.
I was able to export these points to Paraview through "v.out.vtk -cn input = nspt_3D type = point layer = 1 output = nspt_3D2.vtk" and visualize them in 3D, each point with its NSPT value.
How could I do to export in GRASS 7 these points as lines and use the filter tubes in Paraview?


texts: Adding different strings to legend title in QGIS layer composer depending on which layer is active

texts:
My QGIS project includes three layers representing catchment areas for playgrounds. Depending on the age of the children, the catchment areas are either 200 m (catch_area_200m.shp), 400 m (catch_area_400m.shp), or 1000 m (catch_area_1000m.shp).
Within the print composer always just one catchment area is visible. Depending on which of the three layers is active, I want to have this information in the title of the legend.
What I basically need is some sort of conditional clause, checking which layer is activated and then printing a string with the appropriate distance, e.g. '400 Meters', to the title of the legend.
How can this be realised?


texts:
I want to draw a custom polyline using mouse click events in an AddIn.Tool project without esri's build-in interfaces eg. Rubberband, IDisplayFeedback or IShapeConstuct.

I got problems pushing caches into operation Stack while drawing sketch every time mousedown event adds a point to polyline. I cannot use "Ctrl + Z"
to undo the sketch and roll back to previous cache.

Here is the example code, any suggestions are welcome.

    protected override void OnMouseDown(MouseEventArgs args)
    {
        // step 1 : init operationstack
        m_editor.StartOperation();
        m_edSketch.GeometryType = esriGeometryType.esriGeometryPolyline;
        ISketchOperation pso = new SketchOperationClass();
        pso.MenuString_2 = "sketchoperation";
        pso.Start(m_editor);

        if (m_polyLine == null)
        {
            m_polyLine = new PolylineClass();
        }

        // step 2 : add point to m_polyLine
        IMxDocument _mxDocument = ArcMap.Application.Document as IMxDocument;
        IScreenDisplay _screenDisplay = _mxDocument.ActivatedView.ScreenDisplay;
        IPoint _point = _screenDisplay.DisplayTransformation.ToMapPoint(args.X, args.Y);

        IPointCollection _pointCollection = m_polyLine as IPointCollection;
        _pointCollection.AddPoint(_point);

        // step 3 : add m_polyLine to map
        IRgbColor _rgbColor = new RgbColor();
        _rgbColor.Red = 255;
        ISimpleLineSymbol _simpleLineSymbol = new SimpleLineSymbolClass();
        _simpleLineSymbol.Color = _rgbColor as IColor;

        IGraphicsContainer _graphicsContainer
            = (IGraphicsContainer)_mxDocument.ActivatedView.FocusMap;

        ILineElement _lineElement = new LineElementClass();
        _lineElement.Symbol = _simpleLineSymbol;
        IElement _element = (IElement)_lineElement;
        if (!(_element == null))
        {
            _element.Geometry = m_polyLine as IGeometry;
            _graphicsContainer.DeleteAllElements();
            _graphicsContainer.AddElement(_element, 0);
        }

        // step 4 : draw m_polyLine using screenDisplay
        _screenDisplay.StartDrawing(_screenDisplay.hDC, Convert.ToInt16(esriScreenCache.esriNoScreenCache));
        _screenDisplay.SetSymbol(_simpleLineSymbol as ISymbol);
        _screenDisplay.DrawPolyline(m_polyLine);
        _screenDisplay.FinishDrawing();

        // step 5 : reflash screenDisplay
        short _screenCacheID = _mxDocument.ActivatedView.get_ScreenCacheID(
            esriViewDrawPhase.esriViewGraphics, null);
        _screenDisplay.Invalidate(null, true, _screenCacheID);

        // step 6 : push operationstack
        m_edSketch.RefreshSketch();
        //m_edSketch.FinishSketch();
        pso.Finish(m_polyLine.Envelope);
        m_editor.StopOperation("stopoperation");
    }


texts: GIS ArcMap 10.7 Layers have different scale and cant stack together

texts:
I am using Windows 10 system and ArcMap 10.7.
I have three layers, A, B, C. I tend to stack these three layers, the order should be A on B on C. I can put A on C, but I cannot put B on C. I thought this should be a coordinate system problem. However, they are using the same coordinate system. I found a clue about the problem that the A B layers have a different scale with C layer.

I wonder if a different scale cause the problem.
Note:
example of the ABC layers: A could be shops in a city. B could be like a city. C could be like a state.
Could anyone know how to fix this problem.


texts: Error connecting to PostgreSql 9.2 using Autocad Map 2011

texts:
I want to connect Postgresql 9.2 database (installed at localhost , port-5432) from AutoCad Map 2011 (installed in same PC).
I have successfully copied all required dll files (total 13 nos.) from PostGIS bin folder to C:***\AutoCAD Map 3D 2011\FDO\bin & also edited the providers.xml at C:***\AutoCAD Map 3D 2011\FDO\bin with below mentioned snippet before the final

<FeatureProvider>
<Name>OSGeo.PostGIS.3.4</Name>
<DisplayName>Fournisseur OSGeo FDO pour PostGIS </DisplayName>
<Description>Accès en lecture/écriture à une banque de données de type PostGIS.</Description>
<IsManaged>False</IsManaged>
<Version>3.4.0.0</Version>
<FeatureDataObjectsVersion>3.4.0.0</FeatureDataObjectsVersion>
<LibraryPath>PostGISProvider.dll</LibraryPath>
</FeatureProvider>

List of dlls - comerr32.dll, gssapi32.dll, k5sprt32.dll, krb5_32.dll, libeay32.dll, libiconv-2.dll, libintl-8.dll, libpq.dll, msvcr90.dll, ssleay32.dll, PostGISMessage.dll, PostGISProvider.dll, PostGISOverrides.dll

But with all the above mentioned efforts & all connection credentials duly checked the connection is not possible.

Please advice


texts: Entering value greater than Range Domain maximum?

texts:
I created a range domain in a file geodatabase. The type is short integer and ranges from 0 to 200. The domain was assigned to a new column I created. But I could still enter a value greater than 200 to the column of the newed feature (point).

Just unsure what I did wrong.


texts: ArcGIS server Site admin password keeps changing

texts:
I don’t know if I am hacked or what, I am running ArcGIS server 10.3.1 on windows server 2012. My server has  a real domain name that can be accessed form anywhere.

The issue here is that the site admin password keeps changing and all of my service deleted after this change! I reset it but after while (hours) the password changes automatically.

Have any one experienced this issue before?

I changed the password but even it keeps changing after I change the password. I formatted the server and created new site with new usename and password. Every thing went well, till I copied the Users and roles form my backup, then I checked the carefully, there is no suspicious accounts or users, the admin group is empty. But now the password was changed again.


texts: Is it possible to create a dashed underline for labeling in QGIS? I have one capital city which for used underline for the name of this city. and now I need dashed underline to a name of the province, how to create dashed underline for the name of the cities in qgis?


texts:
I have read https://docs.qgis.org/2.18/en/docs/user_manual/working_with_vector/attribute_table.html#creating-one-or-many-to-many-relations and also many to one join in QGIS but I can't seem to be able to do a many to one join in QGIS 3.4.
I have many addresses that I want to connect to land parcels, one land parcel can have several addresses on it, some land parcels also don't have addresses (like farmland for instance).
I went to project/properties and added a relation between these two layers (which have a common identifier (the land parcel ID is already connected to each address in the address attribute table, so I used this same info for the referencing and referenced fields), but then I don't see new fields from the address table be displayed in the parcel table and I have no idea how to have it displayed (QGIS documentation talks about "forms for 1-N relations" but it doesn't seem to refer to the attribute table per se. I actually see the child table (address) appear in form view in the parcel attribute table, but in any case I don't seem to be able to add all the features of the address table, the "add child feature" doesn't seem to be doing that even when selecting all features.
Ideally I would like to have the addresses table joined in the parcel table, with new rows for the same parcel with a different address having been created, and rows of land parcels without address left empty (save the parcel info).


texts: FME using "&" as the first character in a default published parameter?

texts:
I need to use the "&" as the first character in my published parameter (a text parameter). It seems that using & as the first character makes an error in the parameter.

Any workarounds?

FME2015.1


texts:
When I try to label the polygon on my Leaflet map I always get the error:

  t is undefined

I am trying to do it as shown below:

    <title>Page Title</title>
    <link rel="stylesheet" href="https://unpkg.com/leaflet@1.0.0-rc.3/dist/leaflet.css" />

I want to show some text inside the polygon. I've tried to accomplish it using label but unable to do it.


texts: ArcMap change legend label for layers with graduated symbology without changing table of contents

texts:
I want to change the title of a layer in a map legend, and I would ideally like to only change it in the legend without modifying it in the table of contents. If I have my symbology set to "Features - Single Symbol", I have an option of specifying a label appearing next to the symbol in the table of contents, which would change the label without affecting the layer title in the table of contents.
But I don't have a similar option for any of the other symbology options - "Categories", "Quantities", etc. I'm aware I could simply change the layer title in the table of contents and it would modify it in the legend. But I'm using a map document which is accessed by a few different users and lots of different layers with similar titles, and it's important for them to all stay the same to avoid confusion, so when I'm producing lots of different maps I have to frequently change the title and change it back, which is inconvenient.


texts: Generate a random 100x100 m bounding box in any projection in pure Python?

texts:
I'm given:

Extend of WMS Layer
SRS

Now I want to, in standard 2.6 Python (no OGR or C lib dependencies), to generate a 100x100m random bounding box within that extent (assuming it is more than 100x100 itself).

I'm allowed to make the following HTTP requests of the following type (caching the results for reuse):

http://spatialreference.org/ref/epsg/$SRS/proj4

But since I basically don't understand the contents of such files (e.g. proj4 etc), I have no idea whether it's even helpful in my computation.

To repeat what I want:

A random 100x100m bounding box within the layer extend, with coordinates in the SRS

The code could look like this, when calling:

random_bbox = random_bbox(extent=[minx,miny,maxx,maxy], srs='epsg:25832', width_meters=100, height_meters=100)

So, how to do this, given this information, in "pure" python? I'm of course willing to write a heap of code, so just need some fairly precise hints.

Sorry if I missed some details, I'm making pancakes for my kids while writing this :-)


texts: Convert location at seconds to DMS/Decimal

texts:
I have latitude/longitude represented as amount of seconds:

45'11"35 = 45*60*60 + 11*60 + 35 = 9720695

How can I convert back from something like 9720695 to DMS/Decimal?