texts: Extracting country specific data from planet openstreetmap big file

texts: I am trying to obtain few old osm dataset of few specific countries/regions to see subsequent changes till now. I am using planet osm files which I think is the only source of old osm archieves. But after extraction planet osm file it's taking aroung 350GB enormous space. Although there is Osmfilter to extract specific tags, but I want to extract specific countries and regions instead. I have already tried QGIS, Linus-Terminal and PostgreSQL in order to do something further but this huge file is rather killing them. Any help regarding how to proceed?


texts: Why won't my points (that I created by intersection) intersect with the geometry they've been created from?

texts:
I created a set of points by intersecting a linestring layer with the boundary of a multipolygon layer like this:

CREATE TABLE freiraumkataster_grenze AS
SELECT
gid,
ST_CollectionHomogenize(ST_Collect(ST_Boundary(geom))) AS geom
FROM
(SELECT
    gid,
    (ST_Dump(geom)).geom As geom
FROM freiraumkataster fk
) As foo
GROUP BY gid;

And

CREATE TABLE zugaenge AS
SELECT
w.gid as wgid,
ST_Intersection(w.geom, fkg.geom) as geom
FROM
wegenetz w
LEFT JOIN freiraumkataster_grenze fkg
ON ST_Intersects(w.geom, fkg.geom);

Now I try to split the linestrings of wegenetz at the location of the points of zugaenge. Since they are created on locations where the two layer intersect, this seems to be an easy task.

I read about ST_Split and learned that it has (had?) problems with multigeometries, so I used the (old?) wrapper from here: Split lines into non-overlapping subsets based on points With the magic:

result := input_geom;
-- Loop on all the points in the blade
FOR simple_blade IN SELECT (ST_Dump(ST_CollectionExtract(blade, 1))).geom
LOOP
    -- keep splitting the previous result
    result := ST_CollectionExtract(ST_Split(result, simple_blade), 2);
END LOOP;
RETURN result;

In my (limited) understanding of this, ST_Split(result, simple_blade) should work and should produce a geometrycollection containing at least two line strings in the case any intersection is found. But it won't do that. The result stays the same single-piece linestring I put into it.

I convert the multipoint layer to singlepoint:

CREATE TABLE zugaenge_single AS
SELECT
wgid,
ST_GeometryN(geom, generate_series(1, ST_NumGeometries(geom))) AS geom
FROM zugaenge;

And group them, so there is one multipoint geometry for each linestring.

CREATE TABLE zugaenge_pro_weg AS
SELECT wgid, ST_Union(geom) as geom
FROM zugaenge_single GROUP BY wgid;

And then I run the geometries (line string and multipoint) through the wrapper.

CREATE TABLE wegenetz_splitted AS
SELECT
split_line_multipoint(w.geom, z.geom) as geom,
w.gid as wgid
FROM
wegenetz w
LEFT JOIN
zugaenge_pro_weg z
ON w.gid=z.wgid;

This results in the same geometry as I find in wegenetz, the layer I put into it.

Why is it that way? Why isn't any intersection found? Or do I use any function totally wrong? I even tried to use ST_Split() right away instead of the wrapper, since it should be able to do this task since 2.2, but the result stays the same.

I also tried to enhance the wrapper by using

result := ST_CollectionExtract(ST_Split(result, ST_ClosestPoint(result, simple_blade), 2);

in case there is a precision problem present. But no change despite a longer run time.

What is it, I can't see?


texts:
I am interested in running some linear regression models on landslides in Nepal, and I need to have a landcover file that I can use to prescribe values with in a raster. The only file I have seen is the ICIMOD.org file that does not appear to have an attribute table or any values attached to it whatsoever for some reason. The file is incomplete and useless as far as I can tell...it's just a bunch of cells with colors prescribed to them and that is it. If anyone knows of a location where I might find landcover data for Nepal...and specifically in the Gorkha/Rasuwa districts...please let me know.

I am not the most computer literate person in the world...so please be detailed in any advice.


texts: Monthly weather averages using NCEP/NCAR Reanalysis data

texts:
I need to build a table that has monthly precipitation and temperature means for basically every country I can (from 2001-2014) using the NCEP/NCAR Reanalysis Monthly Means Dataset.

I have been able to load the temperature and precipitation monthly means data into both ArcGIS and R, along with a shapefile for the country borders from thematicmapping.org, but I have been completely unable to extract data for each month with either method.

In ArcGIS I have both datasets loaded and I can use the slider to see different months, as well as use the Zonal Statistics as Table tool, but I can't figure out how to get that to output every month. In R I have been able to load the files in but not get much deeper.

The NCEP/NCAR data is netcdf4 and can be found at: http://www.esrl.noaa.gov/psd/data/gridded/data.ncep.reanalysis.derived.surface.html (air.mon.mean.nc and pr_wtr.eatm.mon.mean.nc).

The shapefile can be found at: http://thematicmapping.org/downloads/world_borders.php


texts: GRASS 7.3 r.fill.dir Does Not Create Output Raster

texts:
I am running GRASS 7.3 on Mac OS X El Capitan (2.9GHz, 8GB RAM).  I have had to disable SIP in order to run it, but it works. I am hoping to perform some hydrological analyses on a few DEMs. My DEMs are 5ft resolution county-scale rasters totaling a few GB apiece but I have performed lots of large-raster operations (outside of GRASS) on this machine with no issues.

When I run r.fill.dir, everything goes smoothly at first; the input raster loads quickly and within the first 5 minutes or so the first two sets of downward/upward passes have completed. Downward pass 3 takes several hours(~5.5 - 6.5) before the command apparently finishes successfully. However, when I look for the output rasters, they do not exist.

I have tried this multiple times, including with a reprojected version of the raster. Same result each time. I always make sure to set the region to match my raster before running the command.


texts: Leaflet: Smooth lines between points without control points?

texts:
Goal

I want to connect points using a polycurve or curved lines in Leaflet in a scalable way. If possible, without defining control points.

Approach

I'm using the Leaflet.curve plugin which offers quadratic and cubic bezier curves. I took a screenshot and created a jsfiddle (https://jsfiddle.net/p1zx5k73/28/) of only a limited set of connected points. The js code is further below.

Problem

My approach is not scalable with the Leaflet-curve plugin since I need to create a control point for all inter-points connections each.

lng = Point_One[0] + 0.5 + ((Point_Two[0] - Point_One[0]) / 2)
lat = Point_One[1] + 0.5 + ((Point_Two[1] - Point_One[1]) / 2)
...

I can automate getting the mid-point between two points and its direction (+/-), but I don't know how to automate offsetting the control point. The length between points varies. In practice, I have hardcoded the size of the offset. If you look closely, you can see that the curves are not equally distributed between points which would also be nice.

Questions

Are there any good frameworks to draw smooth lines between points in
Leaflet?

I have read about Raphael, but it no longer seems to be available(?).

Is there a way to optimize the way I use the Leaflet-curve plugin?

I assume I could have bigger/smaller offsets dependent on inter-points distance.

Are there any QGIS plugins to create splines/smooth lines between points (in a dataset) and export these as a geojson layer?

I have no experience with, but read about the Spline and CadTools Plugins.

var Mapnik = L.tileLayer('http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
    maxZoom: 19,
    attribution: '&copy; OpenStreetMap'
});

var mymap = L.map('mapid', {
    layers: [Mapnik]
}).setView([49.165804, 39.517246], 4);

var Warsaw = [52.233333, 21.016667];
var Brest = [52.133333, 23.666667];
var Moscow = [55.75, 37.616667];
var Yekaterinburg = [56.833333, 60.583333];

var curved_line = L.curve(['M', Warsaw,
    'Q', [Warsaw[0] + 0.5 + ((Brest[0] - Warsaw[0]) / 2), Warsaw[1] + 0.5 + ((Brest[1] - Warsaw[1]) / 2)],
    Brest,
    [Brest[0] - 3.5 + ((Moscow[0] - Brest[0]) / 2), Brest[1] - 3.5 + ((Moscow[1] - Brest[1]) / 2)],
    Moscow,
    [Moscow[0] + 3.5 + ((Yekaterinburg[0] - Moscow[0]) / 2), Moscow[1] + 3.5 + ((Yekaterinburg[1] - Moscow[1]) / 2)],
    Yekaterinburg,
      ], {
  fillColor: 'green',
  weight: 4,
  opacity: 1,
  color: 'green',
  fillOpacity: 1,
  lineCap: 'round'
});

var straight_line = L.curve(['M', Warsaw,
'L', Brest, Moscow, Yekaterinburg, {
    fillColor: 'blue',
    weight: 2,
    opacity: 0.5,
    color: 'blue',
    fillOpacity: 0.5,
    lineCap: 'round'
}]);

mymap.addLayer(straight_line);
mymap.addLayer(curved_line);


texts: What's the deal with "degradation" and lastools?

texts:
I've read a few cautions online and heard a few from colleagues.  If you don't purchase a license for lastools, the non-open-source functions will somehow degrade your data or results?  Is this true?  Degrade what?  How much?  Is this true of the initial free trial copy?

I had not previously been able to discover any details at http://www.cs.unc.edu/~isenburg/lastools/LICENSE.txt.


texts: Inputting DEM min value into ModelBuilder?

texts:
I am building a model in ArcGIS 10.5 and I need to input the min value of a DEM as one of the variables.

How can I do this?


texts: How can I plot points with proportional circles, but also by colour from another attribute?

texts:
I have point data of population density that I have plotted to show density with proportional circle symbols. This is straightforward with many ways of achieving this in different software and packages. But I would also like to use colours to show not only density by proportional symbol but also have the proportional symbols coloured to represent different values from another map layer, a raster map.

So for example, I want the largest symbol size to be coloured red, orange or yellow depending on the value of the spatially corresponding raster cell. So each symbol size will have different colours depending on the raster.

Is there an existing R function that does this (I cannot find one)? Or is there a way of clipping the (coloured) raster map by a point map that is displayed with proportional circles?


texts: Where to choose a shapefile for appending?

texts:
I want to append several shapefiles in QGIS. The ftools 0.6.1 add-on is installed.

But under Vektor>Datenmanagement-Werkzeuge>Shapedateien zu einer zusammenführen (=append shapefiles) is only the possiblility to choose the Eingabedatei (input file) and the Ausgabedatei (output file) but not a further Datei (file) for the append itself?
(Even though there are  several shapefiles in the same folder)

//Furthermore the icon "In neue Projektion exportieren" (export to new projection) is also not appearing under the: Vektor>Datenmanagement-Werkzeuge? Do I need a further add-on?//

Has anyone an idea why I can't choose a shapefile for the appending?

Thanks in advance!
phil


texts: How to increment the data frame time by one day in ArcMap 10?

texts:
I often use ArcMap 10 to display dynamic text using the dataFrame time.

<dyn type="dataFrame" name="Layout" property="time" emptyStr="[off]"/>

The above might display something like

2011/08/16

However what I really want to be able to do is add 1 day to the dataFrame time and display it.  This way I can display a date range

2011/08/16 - 2011/08/17

Thanks


texts:
I actually did this a few weeks ago but I can't remember how.

I want to create points on the perimeter of a set of polygons at a specific distance interval. I am using ArcMap.

I could do Polygon Vertices to Points, but that would only give me points on the vertices, which I don't necessarily want. What I want is a regular set of points on the perimeter of the polygons.

This is my base polygons:

And this is what I would like to get (the points at regular intervals):

Any ideas?


texts: An application for measuring river length?

texts:
I'm aware of the coastline paradox and its application to rivers in that the measured length of a river depends on the resolution of the measurement.
Is there an application that calculates the centre of a river (a line equidistant from either bank at all points), then adds points along the line according to the resolution specified (for instance, every metre, 10 metres, 100 metres, etc.), then joins the dots and takes an overall measurement?


texts: gtk.css:2:33: Failed to import in Grass GIS

texts:
When first I run GRASS GIS 7.6.0, there is an error message :

(gis_set.py:4772): Gtk-WARNING **: 16:05:43.648: Theme parsing error:
gtk.css:2:33: Failed to import: Error opening file
/home/mega/.config/gtk-3.0/whisker-tweak.css: No such file or directory

I ignore the message. I start GRASS GIS. I import raster and vector. I add raster as RGB.

Image is displayed in map display window. Then I choose Imagery > classify image > Interactive input for supervised classification. Then GRASS GIS supervised classification tool appear.
But, no image in training area display and preview display. Then I import training area from vector map.

Suddenly, all window GRASS GIS quit except GRASS GIS terminal window.

So, how to solve this problem? I run in MX Linux 19.


texts: What is a term to describe a latitude OR longitude value but not both together?

texts: I have a location of north 45 degrees, west 90 degrees. This is the coordinate of the point. What is each component of this coordinate called? I'm looking for a generic term to describe either component but not both together (that's the coordinate).


texts:
I have a polygon-layer with the boundaries of a field and a point-layer with several points inside the polygon.
I want to divide the polygon into as many polygons  as points ( 1 polygon with 3 points -> 3 polygons with almost same size).
And if that works - is it possible to do it with a multi-polygon-layer?


texts: ArcGIS Web AppBuilder View Query Results in AttributeTable

texts: I'm building a couple of custom widgets for use on a Web AppBuilder app that do some queries against feature layers. I get back a feature set, which I can convert to a local feature layer. What I'd like to be able to do is display that feature layer in the Attribute Table, so that I don't have to build a separate table to display query results. Unfortunately, it looks like using the addNewLayerTab call of the AttributeTable widget tries to query the feature layer with a where clause of "1=1". This causes an error, because queries on local feature layers cannot contain a where clause. Does anybody know of a way to hook this up properly?


texts: Implementing python code in Whitebox spatial analysis tool

texts:
1.I want to implement this python code

wd = pluginHost.getWorkingDirectory(C:\xampp\htdocs\learn\doit)
flowPointer = wd + "d8flowpointer.dep"
outputFile = wd + "manjflowaccscript.dep"
outputType = "specific catchment area (sca)"
logTransformOutput = "false" args = [flowPointer, outputFile,
outputType,      logTransformOutput]
pluginHost.runPlugin("FlowAccumD8", args, False)

  How to pass my  working directory to whitebox scripting tool?When i try above code

    It's giving this error message
    SyntaxError: no viable alternative at input ':' in  at line number 1 at column number 37


texts: Is there an alternative to prj2epsg.org?

texts:
In the past, we used prj2espg.org to find the srid/espg code from .prj file of shapefiles in order to import them in PostgreSQL.
Unfortunately, the website seems to be down since November 2019 (probably because Boundless was acquired by planet.com).
Does anyone have an alternative solution?
I tried using GDAL or looking directly into spatial_ref_sys from PostGIS.
I can retrieve some information about the projection like the proj4 description, but if I look into  spatial_ref_sys, I could retrieve multiple results for a search...


texts: Seeking QGIS solution to make aerial imagery ArcSDE compatible?

texts: Would like to avoid having to use 3d Analyst and use free raster tools in QGIS or elsewhere to make aerial rasters ArcSDE compatible. This 18 page work flow is what I am trying to use.


texts: how do you create an editable combobox addin for ArciGIS using Eclipse

texts:
Arc have a walkthrough to take you through this.  Looks like I'm still crawling.  The walkthrough can be found here:

http://help.arcgis.com/en/sdk/10.0/java_ao_adf/conceptualhelp/engine/index.html#//0001000002sr000000

Everything in the walkthrough works fine but if I make the box editable each keystroke is entered as a new option.  So "blah" typed into the combo box would create the following options within the combobox:

b
bl
bla
blah

I'm sure onEnter() method needs to tie in with the onEditChange() method.  But trying to incorporate this just adds blank options.

Any help appreciated.


texts: Maintaining same number of digits in Excel file when converting to table in ArcGIS for Desktop?

texts:
I have two fields containing lat and long values which are precise up to 8 digits. When I use the excel to table tool, Arc removes the last two digits in both fields leaving me with lat and long fields with only 6 digits.

How do I convert to a table in ArcGIS 10.2 and maintain the same number of decimal places as in my original excel file?


texts: Enlarge a Polygon without changing its shape or position

texts:
I have a single polygon shapefile (EPSG: 3044) which I want to enlarge using QGIS 2.18.16. I tried to use  the vector affine transformation plugin, but whenever I try to change the size of the polygon, the whole layer changes its position and shape. Is there a tool in QGIS where I can do this task or is it possible with the affine transformation plugin and I just cannot find the right values?

What I have:
Some csv points and a country-border. The points do not have the correct positional accuracy. Therefore I want to enlarge the country-border so that all points fit into the poylgon.

What I get when I change the X and Y scale from 1,0 to 2,0:


texts: How does Google Earth Engine handle scale?

texts:
I read the scaling documentation for Google Earth Engine, but I didn't understand, so I need to make an example.
I have two collections: one at 4 km resolution (MODIS) and one at 10 meters resolution (Sentinel). I want compare two bands, say the NDVI.
My point is I don't want to compare a 10 meters pixel with a 4 km pixel, but I want to have enough pixels from Sentinel to cover the same area of MODIS and maybe use a ee.Reducer.Mean() to get a single value.
Does this code do what I want?
point=ee.geometry.Point(11.05,37.58)

var chart_sentinel=ui.Chart.image.series({
    imageCollection: sentinel_ndvi,
    region: ee.Feature(point).geometry(),
    reducer:ee.Reducer.mean(),
    scale:4000
    });

print(chart_sentinel)
var chart=ui.Chart.image.series({
    imageCollection: modis_ndvi,
    region: ee.Feature(point).geometry(),
    reducer:ee.Reducer.mean(),
    scale:1
    });

Am I actually comparing approximately the same area?


texts: Vectors in layer not displaying but can select all and are shown in Attribute Table

texts:
I am working in 3.4.13 and having issues with vectors in a layer doesn't display.

I can select all and are shown in the Attribute Table but are not visible

I am very new to GIS.


texts:
I was wondering how F4 added the eiffel tower model on top of the OSMBuilding?

I want to add 3D buildings for my city.

http://demo.f4map.com/#lat=48.8591098&lon=2.2945308&zoom=18&camera.theta=50


texts: How to create a raster map in QGIS that includes the distance to the nearest road multiplied by another variable included in a vector file?

texts:
I am using QGIS (v. 3.4). I have a vector file (.shp) with the main roads of my city including the average traffic load of each segment. I would like to create a map with the inverse distance to the nearest road multiplied by the traffic load of the road. I know how to create a map with the inverse distances to the nearest road and another with the traffic loads (this one only contains information in the pixels of the roads), but not a combination of both.

How can I do this?


texts:
I am new to QGIS but used to ArcGIS.  I am working my way through the tutorial and have downloaded a map from earth explorer - following all the instructions.  The map is in the left hand panel and the co-ordinates are visible. A thumbnail is showing in properties.

I have tried zoom to image but no map appears.

I cannot continue with the tutorial until I get the map!


texts: Mapfile SYMBOLSCALEDENOM and SIZEUNITS (miles) 200: Keep SIZEUNITS while circles change size based on zoom

texts:
I've been trying to understand how to keep the SIZEUNITS at 200 while the circles appropriately adjust based on zoom level.

Thought I had this working properly but turns out I did not.

You can see here that the circles start out quite small at the default zoom level when you load the OpenLayers map. As you zoom in, the circles aren't changing size. They should be as SIZEUNITS is set to 200. Of course, since you are zooming in, it seems like the circles are getting bigger on your screen, but they really are not.

When you get pretty zoomed in, what should happen is that the circles should be quite large (as we want to keep the radius of 100miles...set SIZEUNITS to 200 as this is the diameter). However, that is not the case as you can see here.

Is it necessary to use SYMBOLSCALEDENOM with SIZEUNITS to acheive what I want: keeping the 200mile diameter whilst the circles are changing size based on zoom? If so/if not, how do I go about this?

Link to mapfile layer here.


texts: Setting one layer item visibility by another

texts:
Within QGIS, you can obviously categorise by a field. This gives you the ability to select individual categories visibility (e.g. a name or similar.)
Is there a way that I can cascade this selection to another layer, with an identical set of categories?

I've tried joining and using 'is_layer_visible' and 'is_selected' but this is not working (as presumably that is giving you layer level, not item level filtering.)

I have come up with a temporary solution currently, which is to filter the SQL query for each layer, split the shape files and layers, and put into groups. But this is slow and a big buggy.


texts: Using QGIS heatmap point style in QGIS server

texts: Can the QGIS heatmap point style be rendered by QGIS Server?


texts: OpenLayersPlugin doesn't not load anything

texts:
I have some issues with the OpenLayers Plugin. I have already installed the plugin, though when i choose to add for example the google hybrid layer or anything else it doesn't do anything, just that it tries to load something.What should i do?
thanks.


texts:
Can one row in an attribute table be linked to many separate polygons?
I did a series of selects, buffer, intersects on some shapefiles and my resulting table has for one row many polygons.  Can this be correct or do I have some further operations to do?

I am doing a site selection assignment so I used the criteria given and did selects, buffers (eg certain distance from roads and rivers) etc and my final attribute table has x number of rows. When I select a row, that one row identifies four polygons on the map. I am asking if I should stop here or should I separate out the polygons into their own identifying row.


texts: I just saw this wonderful app posted on Twitter and I would like to learn how to create a panel like the one below. Note the background is a little translucent and the gray area is contained inside of a black frame. Does anybody have a sample code for me to look at? Thank you!


texts: Software support for GML 3.3 Linear Referencing?

texts:
Are you aware of any software supporting import/export of Linear Referencing data in GML version 3.3 format?

Apparently no software application, proprietary or FOSS, currently supports it explicitly.  I've read elsewhere that "GML 3.3 is itself a GML 3.2.1 application schema".  So maybe software applications that support version 3.2.1 already implicitly support GML 3.3.  Yet that does not necessarily mean the correct bindings for LRS reading/writing have actually been implemented.  Please let me know otherwise.


texts:
I have a bitmap that contains a polygon NDVI and nodata space.
How do I get the average value of the polygon only, and not the entire raster.


texts: How to convert Grid North & Grid East into latitude and longitude?

texts:
We have grid north and grid east data that we have received for address information. How can this be converted into latitude and longitude? I am not sure what format this grid_east and grid_north data is in, but it seems to uniquily identify a record. The numbers are integers. (large)

Here are some examples: (They are in Upstate New York)

6 HERON WAY NORTH 14450 GRID EAST: 803160 GRID NORTH: 1122110

16 CROSSWINDS CIR 14450 GRID EAST: 819252 GRID NORTH: 1123388


texts: Is there a way to distinguish data precision in KML?

texts:
Here's my problem (and I was inspired to ask this from this question)...

I create a KML file recording where upcoming training courses will be for the next year. The cities might be Atlanta, Calgary, Toronto, Dallas, etc

So I can automate the process, I read the list from a file, use a geocoding service to get the coordinates of "Atlanta" and insert a placemark at that point. Now a user can open the KML and see there is training in Atlanta.

However, what if that user zooms right into Google Earth, uses the placemark to identify a particular building, and assumes the training will take place there!

I can't give the exact building location, because it won't be booked till closer the date. But how do I tell my user that the placemark is only meant to signify position to the city-level, and not right down to a particular building?

Should I fiddle about with zoom level displays, use a polygon instead of a point, or is there a good KML method to solve the issue?


texts: Corners of GeoTiff's not lining up after doing gdalwarp EPSG:3006 -> EPSG:4326

texts:
I have some GeoTiff's that are in EPSG:3006 (SWEREF99 TM) atm, and I'm trying to convert them to EPSG:4326 (WGS84) because some other software needs it in this projection.

But after doing the gdalwarp the corners of my tiff's doesn't seem to add up anymore. Is there anything i can do to prevent this from happening?

Some examples (from gdalinfo); the upper right corner of one tile should be in the same position as the upper left corner on the next tile.

The corners in EPSG:3006:

Upper Right (  400000.000, 6200000.000) ( 13d23'57.18"E, 55d56' 5.91"N)
Upper Left  (  400000.000, 6200000.000) ( 13d23'57.18"E, 55d56' 5.91"N)

And the same corners ins EPSG:4326 after gdalwarp:

Upper Right (  13.4282324,  55.9349761) ( 13d25'41.64"E, 55d56' 5.91"N)
Upper Left  (  13.3992179,  55.9453750) ( 13d23'57.18"E, 55d56'43.35"N)

Now they don't line up anymore.

I'm using QGIS, which is using gdalwarp to do this. The commandline for the operation:

gdalwarp -overwrite -s_srs EPSG:3006 -t_srs EPSG:4326 -of GTiff C:/data/example.tif C:/data/example_warped.tif


texts: I am looking for a way to use ArcGIS WMTS map service in C# (Actually it is a unity platform and most probably it be used on unity webgl). But I didn't find it yet. There are JavaScript API avilable, is there any practical way available to use it with C#? with some free available WTMS services.


texts: Looking for a Tool to Calculate Distance Between Points (Between Layers)

texts:
I am a college student using ArcEditor 10.0 for a semester project measuring distance to hospitals from census tract centroids. This is my first time using ArcGIS, and I have no formal training. So this question may be very simple, but is it possible to calculate distance between two different types of points between two layers? In one layer I have a shapefile for census tracts and I've calculated the centroids. In the other layer I have geocoded hospital addresses. I would like to calculate distance from each census tract centroid to the nearest hospital. Is there a tool in Arc Toolbox that will do this/could you give a brief overview of the tool?

Thank you!


texts: How to view Navionics bathymetry Web API in QGIS?

texts:
I am looking to view a Navionics bathymetry map in QGIS. The maps can viewed in a browser on the Navionics website here: https://webapp.navionics.com/?lang=en#boating@6&key=%7B%7DoiGbyvcN

Is it possible to import this as a layer into QGIS? Similar to how the openlayers plugin imports background data. I've tried navigating the 'QGIS Web Connector' with little success. The Navionics Web API is based on OpenLayers 3.0 so I suspect this should be possible.


texts: Transferring Z values into vertices in ArcGIS Desktop?

texts:
I am rookie about vertical issues. I have 2 parallel line feaure classes, one of them has Z values in vertices and I want to transfer these z values to the another line's vertices. It is ok that I can add new vertices to closest place of new line that i want to write/transfer Z values into vertices.

Is there any way to transfer these all Z values into another line vertices?


texts: Querying related table and displaying results in CMV Attributes Table?

texts:
I'm trying to use the new Attributes and Search widget for CMV with a relationship query without success - I keep getting a growler message saying 'Search error; Sorry an error occurred and your search could not be completed'. I've been using Fiddler to try and monitor what is happening. I can see that the query URL is generated and it all looks fine except that it is missing the 'objectIds=' string. In the Search Widget configuration I have added the following:

        layers: [
        {
            name: 'Multimedia links',
            expression: '', // additional where expression applied to all queries
            idProperty: 'GIS_ID',
            queryParameters: {
                type: 'relationship', // spatial, relationship, table or database
                layerID: 'adReports', // from operational layers
                sublayerID: 0,
                relationshipID: 0,
                objectIds: [1,2,3],
                outFields: ['*']
            },

The relationshipID value is picked up in the resulting query URL, but objectsIds isn't.

Can anyone help with this?


texts: How to split a shapely polygon with two linestrings and get the middle polygon

texts:
So I have a shapely Polygon and two LineStrings. Both Linestrings always intersects the polygon. I want to get the polygon in the middle as seen in the example below. The region shaded in red is the polygon I want to get:

Anyone know how this can be done in shapely or some other Python library?


texts: 'ST_SEGMENTIZE' function in PostGIS gives single output

texts:
I try to split a line into 2m segments but somehow the function ST_SEGMENTIZE returns the whole line assigning just one id.

An example:

CREATE TABLE line(name char(10), geom geometry);

INSERT INTO line VALUES('line','SRID=32637;LINESTRING(1 1, 1 3, 2 3, 3 3, 3 2, 4 2, 5 3)');

SELECT ROW_NUMBER() OVER() AS id, ST_AsText(ST_SEGMENTIZE(geom, 2)) AS geom FROM line;

Output:

id  geom
1   LINESTRING(1 1,1 3,2 3,3 3,3 2,4 2,5 3)

How can I achieve to get 2m segments from my line-input using PostGIS 2.5.1?


texts: Not able to display KML file - OpenLayers

texts:
I tried to load my KML file from one of the OpenLayers examples

import Map from 'ol/Map.js';
import View from 'ol/View.js';
import KML from 'ol/format/KML.js';
import {Tile as TileLayer, Vector as VectorLayer} from 'ol/layer.js';
import BingMaps from 'ol/source/BingMaps.js';
import VectorSource from 'ol/source/Vector.js';

var raster = new TileLayer({
  source: new BingMaps({
    imagerySet: 'Aerial',
    key: 'my-own key'
  })
});

var vector = new VectorLayer({
  source: new VectorSource({
    url: '250K_GSI_DRM_Angul_Geology.kml',
    format: new KML({
        extractStyles: true
    })
  })
});

var map = new Map({
    layers: [vector, raster],
    target: document.getElementById('map'),
    view: new View({
        center: [85.1510, 20.84440],
        projection: 'EPSG:4326',
      zoom: 6
    })
  });

I can able to load the Bing maps but I can't see the KML file (file is in the same folder-path is right), even while debugging in Chrome I can't see the file in Sources tab(chrome developer tools).

I don't understand where I am doing the mistake, I'm struggling two days to find out this error, am I missing any basics of OpenLayers?


texts: How to identify image footprints of an aerial photograph

texts: I need a tool that will take aerial images with Lat, Long, and Alt in their EXIF data and produce foot prints of the images.  We need to verify that the images cover the photographed area with proper overlap.


texts: Leaflet JS calling animatedMarker.stop() from event listener

texts:
I'm using the animated marker plug-in for Leaflet JS and would like to stop the marker from animating when it reaches a certain lat lon position.

Currently I'm using Leaflet's 'move' event listener to detect when the marker reaches the specified lat lon. This part is working as I can console.log a message when the desired position is reached, however the stop method is not actually stopping the marker from animating.

a live demo to my code can be found here

My code is as follows:

        <meta charset="utf-8">
        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
        <meta name="viewport" content="width=device-width">
        <link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet-0.7.2/leaflet.css" />


texts:
I have a python script that is suppose to merge geodatabases.  I have about 10 geodatabses, some of which have feature classes that are not in the others, everything else has the same schema.  When I run the script, I get the following error:

Traceback (most recent call last):
  File "C:\Users\kahn8050\Desktop\PythonScripts\mergegeodatabases.py", line 29, in <module>
    lyrs = list_layers(gdb)
  File "C:\Users\kahn8050\Desktop\PythonScripts\mergegeodatabases.py", line 18, in list_layers
    for ds in arcpy.ListDatasets():
TypeError: 'NoneType' object is not iterable

I'm not exactly how to change the script so that it ignores NoneType and just merges the files that are the same.  I have attached the script below:

import arcpy
import os
import time

START = time.time()

#### SET THESE VARIABLES BEFORE USING ####
model_path = (r"C:\Users\kahn8050\Desktop\PythonScripts\TEST\NFHL_04_20161108.gdb") # path to target geodatabase - schema should match that of input geodatabase(s)
paths_to_load = r'["C:\\Users\\kahn8050\\Desktop\\PythonScripts\\TEST\NFHL_06_20161110.gdb"]' # list of (str) paths to input geodatabase(s)

def list_layers(gdb):
    """
        Creates a list of feature classes in current workspace with full paths
        (including path to parent geodatabase). Returns list of layers.
    """
    print("\nGenerating layer list...")
    lyrs = []
    for ds in arcpy.ListDatasets():
        for fc in arcpy.ListFeatureClasses(feature_dataset = ds):
            fullpath = os.path.join(gdb, ds, fc)
            lyrs.append(fullpath)
    return lyrs

if __name__ == "__main__":
    for gdb in paths_to_load:
        arcpy.env.workspace = gdb

        print("***Beginning processing for {0}***".format(gdb))
        lyrs = list_layers(gdb)

        for lyr in lyrs:
            fc = os.path.basename(lyr)
            ds = os.path.basename(os.path.dirname(lyr))
                # if no dataset (i.e., fc is in root of geodatabase) then
                # ds = empty string
            target = os.path.join(model_path, ds, fc)
                # if ds = '' then join correctly ignores

            try:
            # append lyr to model_path/<ds>/<fc>
                arcpy.Append_management(lyr, target)
                print("Appended: {0}".format(target))
                with open ("appended_layers.txt", "a") as txt:
                    txt.write("{0}\n".format(lyr))
            except arcpy.ExecuteError as e:
                if "000732" in e:
                    pass
                    # target does not contain this feature class name
                    # TODO copy entire source layer to target?
                else:
                    # log failed attempts to append (e.g., non-matching schemas)
                    with open ("append_errors.txt", "a") as txt:
                        txt.write("***Failed to append {0}\n\t{1}\n".format(lyr, e))
                print(e)
                pass

    END = time.time()
    print("***Processing complete: time elapsed = {0} seconds***".format(END-START))


texts:
How can I rotate a map to -28.5 in ArcGIS Pro?
Right clicking the Layout allows you to rotate like this:

Right clicking on the actual map lets you rotate like this, but is very restrictive and does not let you type a value....


texts: Changing default settings for Arrow Item in print layout of QGIS 3.10

texts:
I am using the print layout of QGIS 3.10 to make maps and some reports. I frequently use the Arrow Layout Item.

I need to change the default values for the Arrow Stroke Color, Arrow Stroke Width, Arrow Stroke Color and Arrow Fill Color. In my layout otherwise, I have to do this every time for all the arrow items across multiple projects.Since Arrows are very specific, copying and pasting it again also is not very helpful.

Is there a way to change these default values like we can change the default value of the font?


texts: Determining the best month for discriminating between different vegetation types?

texts:
I ordered and downloaded several (Surface Reflectance) Landsat 5-8 images from USGS Earth Explorer with the purpose of choosing a few of them to calculate some Vegetation Indices for each (NDVI, SAVI, EVI) and compare the evolution of the vegetation cover from the 1980s to the present.

I need to select the same month for each year I'm going to consider, but I'm not sure which is the best month to ensure the maximum separability between each vegetation type (I need to discriminate between grassland, closed forest, open forest/shrubs and bare soil in a mountainous environment in the Italian Alps).

Among the Landsat images I downloaded, I have a series of images from the same year (5 images for 2005, all falling within the vegetative season), which I want to use to determine the best month for classification.

Does it make sense to perform a semi-automatic classification on each 2005 image separately, and then compare these classifications to a high-res reference image of the same period to see which month gives the most accurate result?

Or is it better if I calculate NDVI for each image first, and perform the classification based on that?

My worry is that, since I will calculate other indices, not just ndvi, basing my choice of month only on NDVI might not be appropriate.

In addition, do you have different suggestions about how to do this?


texts: Problem opening a shapefile in another application

texts:
I helped a colleague converting waypoints from a GPX file to a shapefile. My colleague has only ArcMap. I gave him the shapefile and when he opened it in ArcMap, it did not show anything in the attribute table.

I installed QGIS in his machine, we tried with a couple of different GPX files and we have the same problem. The resulting shapefile does not show anything in the attribute table in ArcMap, but we are able to see all the data in QGIS.

Any Ideas?


texts: Multiply cell values during r.mapcalc in GRASS

texts:
I'm doing some sieve mapping in GRASS. I have several map layers containing various values representing site suitability ranks.

I need to use r.mapcalc to add these maps together for example map1 + map2 + map3. However, I need to take into account the weightings of each map layer so during the mapcalc I need the values in each map layer to be multiplied by their respective weight. Is there any way to do this?

In the same way you would do something like if(isnull(map1), 0, 1) + if(isnull(map2), 0, 1).


texts:
Does the sql prefix - DISTINCT work well on SDE tables?

http://resources.arcgis.com/en/help/main/10.1/index.html#//018w00000011000000

Syntax:

SearchCursor (in_table, field_names, {where_clause}, {spatial_reference}, {explode_to_points}, {sql_clause})

An SQL prefix clause is positioned in the first position and will be inserted between the SELECT keyword and the SELECT COLUMN LIST. The SQL prefix clause is most commonly used for clauses such as DISTINCT or ALL.

My following example is resulting in all rows, not distinct rows.

rs = arcpy.da.SearchCursor(sTableName, (sSelectField1, sSelectField2), sSqlExp, None, None, ("DISTINCT", sSqlPostfix))

What else could I do to get truly distinct records only?
I store the values in a list and is there a function to get unique values in a list?

Example [1,2,2,3,3,3,5,6,7] to [1,2,3,5,6,7]. Also set(xyz) won't work because I'm using a list, whereas set(xyz) works on tuples.


texts: PostGIS ST_Length returns 0 for geographies with high number of decimals

texts:
I'm having a weird issue when computing the distance between two geographies using ST_Length (PostgreSQL 10.4, PostGIS 2.4.4). Basically if the number of decimals is above six, ST_Length returns 0 in some cases.

Using ST_Length as it is shown in the documentation:

# SELECT ST_Distance(gg1, gg2) As spheroid_dist, ST_Distance(gg1, gg2, false) As sphere_dist
    FROM (SELECT
        ST_GeogFromText('SRID=4326;LINESTRING(-122.4367398 37.7370600, -122.4376093 37.7371769)') As gg1,
        ST_GeogFromText('SRID=4326;LINESTRING(-122.4367539 37.7371343, -122.4375453 37.7372407)') As gg2
    ) As foo ;
 spheroid_dist | sphere_dist
---------------+-------------
             0 |           0

# -- Remove 7th decimal
# SELECT ST_Distance(gg1, gg2) As spheroid_dist, ST_Distance(gg1, gg2, false) As sphere_dist
    FROM (SELECT
        ST_GeogFromText('SRID=4326;LINESTRING(-122.436739 37.737060, -122.437609 37.737176)') As gg1,
        ST_GeogFromText('SRID=4326;LINESTRING(-122.436753 37.737134, -122.437545 37.737240)') As gg2
    ) As foo  ;
 spheroid_dist | sphere_dist
---------------+-------------
     7.8956756 |  7.90923387

What's weird is that the issue doesn't occur every time:

# SELECT ST_Distance(gg1, gg2) As spheroid_dist, ST_Distance(gg1, gg2, false) As sphere_dist
    FROM (SELECT
        ST_GeogFromText('SRID=4326;LINESTRING(-122.4363981 37.7371789,-122.4366807 37.7370670)') As gg1,
        ST_GeogFromText('SRID=4326;LINESTRING(-122.4363905 37.7372617,-122.4366961 37.7371407)') As gg2
    ) As foo ;
 spheroid_dist | sphere_dist
---------------+-------------
     7.9257293 |  7.93355247

What could be the reason for this? Feels like it's a float/double issue but I don't see why the problem would only occur in some cases.


texts: Detecting invalid WKT in text column in SQL Server

texts:
I've got a whole load of WKT data in a SQL Server table, of which I'm trying to detect the validity.

I'm currently doing a query like this:

UPDATE f SET
    f."CurrentGeomValid" = geometry::STGeomFromText(f."GEOM_CURRENT",29900).STIsValid()
FROM "Feature" f
WHERE f."CurrentGeomValid" IS NULL;

(Basically updating a column with the geometry validity).  I'm hitting an issue when the WKT is completely invalid, for example:

POLYGON ((0 0, 10 10, 0 0) (100 100, 200 100, 200 200, 100 200, 100 100))

The initial loop of this polygon doesn't have enough points and gets me a message like so:

Msg 6522, Level 16, State 1, Line 1
A .NET Framework error occurred during execution of user-defined routine or aggregate "geometry":
System.FormatException: 24305: The Polygon input is not valid because the ring does not have enough distinct points. Each ring of a polygon must contain at least three distinct points.
System.FormatException:
   at Microsoft.SqlServer.Types.Validator.Execute(Transition transition)
   at Microsoft.SqlServer.Types.ForwardingGeoDataSink.EndFigure()
   at Microsoft.SqlServer.Types.OpenGisWktReader.ParseLineStringText()
   at Microsoft.SqlServer.Types.OpenGisWktReader.ParsePolygonText()
   at Microsoft.SqlServer.Types.OpenGisWktReader.ParseMultiPolygonText()
   at Microsoft.SqlServer.Types.OpenGisWktReader.ParseTaggedText(OpenGisType type)
   at Microsoft.SqlServer.Types.OpenGisWktReader.Read(OpenGisType type, Int32 srid)
   at Microsoft.SqlServer.Types.SqlGeometry.GeometryFromText(OpenGisType type, SqlChars text, Int32 srid)

The issue seems to be that the STGeomFromText function is failing to read the invalid geometry so that the STIsValid function can tell me that it's invalid!

I can certainly write some .NET code with an exception handler and process my dataset row by row.

Is there a way of doing this in a single query?


texts:
I consider myself a GIS expert, and I have successfully completed many GIS projects for clients. I am proficient in spatial analysis, ArcGIS, QGIS, and quite good in Python as well. However, I am only proficient in desktop GIS solutions (i.e. making PDF, image, KML solutions). Sometimes, I run into clients who would prefer a more attractive solution to show to their investors, rather than just a PDF map. That tears me down because I don't know the web mapping technologies.

My last client asked me to find the best locations in a city where he could build stores for his business. So, we're dealing with GIS suitability analysis here. Normally, the work would require finding GIS layers (e.g. population distribution, income distribution, park locations, etc.) and combine those layers to produce a final hotspot map that would reveal the best locations. I could make an image/pdf/kml map for this, but the client would prefer a web map instead which would consist of a base map (e.g. Google Maps), and the transparent final hotspot map on top of it. The ideal solution would also include some sort of option/area on the webpage where the user could define the weights coefficients of the criteria layers and have the hotspot map created once the weights are entered. For instance, if the user thinks that the park layer is very significant then they could enter 0.8 (at a 0 to 1 scale), 0.6 for the income layer etc. Defining the weights could be in the form of a slider bar. I understand that this solution would need the algorithm to work on the background every time the user sets weights, and I know how to do that in Python.

I am also aware that Javascript would be a tool for this solution. However, I would prefer to do the entire webpage in Python only. So here come the questions: Is it possible to do all that using Python as the scripting language? What would you suggest me to learn for implementing an online solution like the one I just described concerning a GIS suitability algorithm?


texts: Strange circles have appeared on QGIS map?

texts:
Why are circles appearing on my map? It started after using QGIS dev build 2.9 and now appears even on 2.8.1.

Also I've noticed that the usual list of CRS does not appear while using the dev build. Only custom CRSes appears. What gives?

The circles are not selectable or identifiable.

Circles seem to stay the same shape at different zoom labels.


texts: ArcGIS Pro Sort based on more then one field?

texts:
I want to sort attribute table based on more then one column.

Is there a way to do that?


texts:
i want to change the resolution of elevation data for several countries and them merge those in one rasterlayer. I use getData function from raster package. I tried this one:

library(raster)
library(dplyr)
library(purrr)

eu = c("Italy","Spain")

eu_alt = eu %>%
        map(~ {.x = getData("alt", country = .x)}) %>%   # Get elevation
        map(~ aggregate(.x, fact=5, fun=mean)) %>%       # Change the resolution
        map(~ as.data.frame(.x, xy=TRUE))  %>%           # Convert to df
        map(~ na.omit(.x)) %>%                           # Omit NA
        reduce(full_join, by=c("x","y"))                 # Merge df

eu_alt = rasterFromXYZ(eu_alt)

But it does not work right; converting to dataframe does not seem to be the right approach.
What i want is to get something like that:

class       : RasterBrick
dimensions  : 1417, 79993, 113350081, 2  (nrow, ncol, ncell, nlayers)
resolution  : 0.0003472222, 0.008333333  (x, y)
extent      : -9.296007, 18.47934, 35.29167, 47.1  (xmin, xmax, ymin, ymax)
coord. ref. : NA
data source : in memory
names       : ITA_msk_alt, ESP_msk_alt
min values  :       -5.72,       -4.00
max values  :    3972.077,    2919.840

i mean a rasterlayer with changed resolution where nlayers stand for country-specific data. What would be the easiest way to do it?


texts: File size inflation normal with gdalwarp?

texts:
After using gdalwarp to project and align-to-grid (via -tap) a number of rasters I noticed that the output rasters were significantly larger than the original rasters. A fairly thorough web search turned up this Trac issue:

Frank Warmerdam explained the reason:
"On careful review, the difference in the file in question is because gdal_translate uses the TIFFWriteScanline() interface to write the output file from within GTiffDataset::CreateCopy?(), and this only writes as much of the final 'strip' of the file as is required to complete image area. But gdalwarp goes through the blockio interface which writes the complete final strip, even the portion that falls off the end of the file."

This Trac issue is ~7 years old, however, and I know some changes to the GDAL utilities, including gdalwarp have been made since. I'd like to know if the above reasoning still holds and if the file size inflation I'm seeing is "normal." The word "normal" here might be taken to mean unsurprising or expected but, more importantly: is there anything that can be done to mitigate the effects i.e. reduce the output raster file size? Below is a table of the file size inflation I'm experiencing.
Input File Size (bytes)     Output File Size (bytes)    Inflation
1437380431                  1698334217                   18%
1428001178                  1698334433                   19%
  41683165                   137036637                  228%

The input TIFF files were created in ArcGIS and thus have external Worldfiles, XML and DBF files but these do not make up the difference in file size. Here is a sample gdalwarp call as I've used it in all of these cases; the actual execution was handled by a Python subprocess (subprocess.Popen):
$ gdalwarp -tap -tr 30 30 -t_srs "+proj=aea +lat_1=20 +lat_2=60 +lat_0=40 +lon_0=-96 +x_0=0 +y_0=0 +ellps=GRS80 +datum=NAD83 +units=m +no_defs" -co "COMPRESS=LZW" input_file.tif output_file.tif

I understand that in rare cases compression makes a larger file, but the effect is the same without the LZW compression. The ratios in the table are with LZW compression.


texts: What QGIS plugins do you consider to be essential?

texts: What QGIS plugins do you consider to be essential - vector, raster, geoprocessing plugins?


texts:
I am learning QGIS.

I'm working with the 'Natural_Earth_quick_start' data set from the tutorials. The WGS84 projection gives me the view I want. However, this looks like a sheet of paper, and on the right hand side the ocean ends just after Suva, Funafuti, and further to the right I see only white space. Of course, if I move all the way to the left of the map, I see the continuation of the ocean (and places like Nukualofa, Apia). Since all these places are of interest to me, I would like to center my map so it wrap around somewhere else (say middle of the continental US), so that I can see these four places in a single view (Suva, Funafuti, Nukualofa, Apia).

How I can do this while remaining in the WGS84 projection?


texts: Using raster image fill and simple fill together in QGIS symbol selector

texts:
In ArcMap I have USGS BMP files for geological lithology patterns to fill a polygon. When I choose Picture fill symbol and add one of this BMP files then as a second fill layer I choose simple fill symbol from symbol selector together. It changes my BMP file's background color which color as I pick from simple fill symbol layer.

Select BMP file for the Picture fill symbol:

Symbol selector combines both Picture fill symbol layer and simple fill layer with simple fill color as raster background.

But in QGIS (3.2.0 Bonn) I cannot do this use raster image fill and simple fill together to change raster background color. I also try this with PNG file types as a raster image fill. However I couldn't succeed it with SVG files, because whenever I convert image to SVG, symbol selector displays just blank as a SVG fill.

Anybody can help me?


texts: Is there an easy way to style KML files on a graduated colour scale based on field values when uploading to a Google Map?

texts: I am creating a Google Map which includes one polygon layer of census output areas and one point layer. Because the polygon layer is so large and there are limitations on the number and size of layers you can upload to a Google Map (10 layers max of no more than 2000 features and max 5MB), I am having to split the data into twenty individual KML files and create two separate maps with 10 files each. When I add the KML files to my Google Map, I would like to easily be able to categorise the polygons into a graduated colour scheme, with red for low values and green for high values. However there is no option to do this easily (like in QGIS or ArcGIS) as in screenshot below. The range option is not available for some reason, even though the columns I want to use are in number format. Is there some kind of workaround or am I doing something wrong?


texts: Error publishing PostGIS Layer to Geoserver using Python gsconfig

texts:
I can't seem to publish a geoserver layer from our postgis database.
When running a basic script it trips on this line:
ft = cat.publish_featuretype(name=tableP, store=ds, native_crs='EPSG:{}'.format(tableEpsg),
                            srs='EPSG:{}'.format(tableEpsg), jdbc_virtual_table=None, native_bbox=None)

I get an error below.
Store: <geoserver.store.DataStore object at 0x000001FA23C7EE08>
Traceback (most recent call last):
  File "C:\GIS\Tools\06. QGIS\Geoserver\gs Test (2).py", line 132, in <module>
    ft = cat.publish_featuretype(name=tableP, store=ds, native_crs='EPSG:{}'.format(tableEpsg), srs='EPSG:{}'.format(tableEpsg), jdbc_virtual_table=None, native_bbox=None)  #
  File "C:\PythonEnvironments\Python37x64\lib\site-packages\geoserver\catalog.py", line 716, in publish_featuretype
    headers=headers, params=params)
UnboundLocalError: local variable 'params' referenced before assignment

I don't see 'params' as a parameter of the 'cat.publish_featuretype' method but to be honest I'm struggling to find detailed documentation. So why does that come up, or what is the real error?
I read on a github page it could be related to the bbox, so I added that the value below as the 'native_bbox':
{'minx': 671198.619943575, 'maxx': 676473.914171803, 'miny': 2732715.24096015, 'maxy': 2736892.48917506, 'crs': 'EPSG:32638'}
But perhaps that was just a suggestion. I don't really know what the syntax of the 'native_bbox' should be. I also tried minx,maxx,miny,maxy,crs - same result.
All the examples online don't require you to put in the native_bbox.  Perhaps there is another parameter I need to specify in 'cat.publish_featuretype':
It's worth mentioning that I can successfully create a data store using the code, so it does connect ok and authenticate.
Here is the base code:
from geoserver.catalog import Catalog

geoservP = 'GeoserverURL/geoserver/rest/'
username='username' # changed
password='password' # changed

wspaceP = "ProjectName"
storeP = "StoreName"

databaseP = "databaseName"
dbTypeP = "postgres"
hostP = "our.sql.server"
userP = "dbuser"
passP = "dbpass"

schemaP = "o7_environment"
tableP = "parkpoly_omr_dsgn"
tableEpsg = 32638

# Create Catalog Object
cat = Catalog(geoservP, username, password)
print("Catalog: {}".format(cat))

# Create New Datastore Object
ds = cat.create_datastore(storeP,wspaceP)
ds.connection_parameters.update(host=hostP, port='5432', database=databaseP, user=userP, passwd=passP, dbtype='postgis', schema=schemaP)
cat.save(ds)
print("Saved new Store: {}".format(storeP))

# if already created just open the existing one as a store object
##ds = cat.get_store(storeP)
##print("Store: {}".format(ds))

ft = cat.publish_featuretype(name=tableP, store=ds, native_crs='EPSG:{}'.format(tableEpsg), srs='EPSG:{}'.format(tableEpsg), jdbc_virtual_table=None, native_bbox=None)
cat.save(ft)
print("Published Table: {}".format(tableP))


texts:
I am looking for a kind of Content Management System (CMS) for WebMaps, which already provide components such as a map area, sidebar (description and information), menu, etc.

A list of possible frameworks would be great, just to get an overview of possibilities provided.


texts: OpenLayers 3 draw polygon to select features

texts:
Update

I have now got this working and this plunk shows a working example.

I have a set of points on a vector layer and I am allowing the user to draw a polygon on another layer of the map. I want to select all the points inside the polygon.

I have got this to work, but only temporarily. When the user finished the polygon, the points are selected but then immediately unselected again. I cannot figure out why.

I have made the function by referencing an example: DragBox

When I replace my polygon with a dragbox, the selections persist. But when I use interaction.Draw to make a polygon, the selection does not persist.

The javascript code is below, and here is a plunker of the feature.

var map;

//Add map layer
var baseLayer = new ol.layer.Tile({
    source : new ol.source.OSM()
});

//Add view
var view = new ol.View({
    //projection is about how we represent a global thing on a flat thing.
    projection : 'EPSG:900913',
    center : ol.proj.fromLonLat([-2.5,51.1]),
    zoom:4,
});

//Add layer of point features
var pointsLayer = new ol.layer.Vector({
    title: 'random points',
    source : new ol.source.Vector({
        url : './assets/Points.json',
        format : new ol.format.GeoJSON()
    })
});

//initialise map (called at the end)
function init(){
    map = new ol.Map({
        target : 'map',
        //the type of rendered we want to use.
        renderer : 'canvas',
        view : view
    });
    map.addLayer(baseLayer);
    map.addLayer(pointsLayer);
}

init();

//////////// ADD SELECTION

//add ol.collection to hold all selected features
var select = new ol.interaction.Select();
map.addInteraction(select);
var selectedFeatures = select.getFeatures();

//////////// ADD DRAWING

// Add drawing vector source
var drawingSource = new ol.source.Vector();

//Add drawing layer
var drawingLayer = new ol.layer.Vector({
    source: drawingSource
});
map.addLayer(drawingLayer);

//declare interactions globally so we can attach listeners to them later.
var draw;
var modify;

// Drawing interaction
draw = new ol.interaction.Draw({
    source : drawingSource,
    type : 'Polygon',
    //only draw when Ctrl is pressed.
    condition : ol.events.condition.platformModifierKeyOnly
});
map.addInteraction(draw);

draw.on('drawend', function(e) {

    // features that intersect the box are added to the collection of
    // selected features, and their names are displayed in the "info"
    // div
    var extent = e.feature.getGeometry().getExtent();
    pointsLayer.getSource().forEachFeatureIntersectingExtent(extent, function(feature) {
        selectedFeatures.push(feature);
    });
});

//////////// SUPPORTING FUNCTIONS

//turn the cursor into a pointer if it's over an image.
map.on('pointermove',function(evt){
    if(evt.dragging){
        return;
    }
    var pixel = map.getEventPixel(evt.originalEvent);
    //called with pixel, callback. Detects layers that have a colour value
    //at a pixel.
    var hit = map.forEachFeatureAtPixel(pixel,function(feature){
        return true;
    });
    map.getTargetElement().style.cursor = hit? 'pointer' : '';
});


texts: Adding a description to the attribute table in ArcGIS Pro

texts:
My question is just editing the pop-up within the attribute table to give a description. So when one opens the attribute table and hovers over the field column names, a pop-up will show giving details such as Type, Default, Read-Only, Nullable, and Indexed.
I was wondering if editing this is possible, so I can add or give a description within this attribute table pop-up?


texts: Interpolate points to lines every odd and even number

texts:
We are working in Oracle Database 11g. There is a table with sdo_geomerty column(representing a line) which contains the following :

RSID,       LT,      LF,      GEOM
584908,     30,      34,      [MDSYS.SDO_GEOMETRY]
1312994,     1,      9,       [MDSYS.SDO_GEOMETRY]

In the column of geom is the MDSYS.SDO_ORDINATE_ARRAY there are more than 2 points with known coordinates, so we can say that is a curve too.
For the 2 records above, we want to compute the coordinates for the points placing at the even and odd intervals correspondingly.

To be clear, for the first record we want the point coordinates in 30,32,34.
For the second record we want the point coordinates in 1,3,5,7,9.
The start and end of each line is known as we can extract the first and last pair of coordinates from geometry column.
I am looking for a program logic (I am working on these languages C#, Python, pL SQL) that combines the Pythagorean theorem and the relations between Polar and Rectangular Coordinates to find the coordinates at even intervals when the edges of the line are even and odd numbers correspondingly.
These numbers are street road numbers and the lines depict the road network.

Visit http://math.ucsd.edu/~wgarner/math4c/textbook/chapter9/polar_coordinates.htm

I have good knowledge on plsql.


texts: How to derive stream order from vector network

texts:
I have a recently-updated extract from NHD High Resolution (updated in last 6 months) which means it hasn't been cranked through NHDPlus, and won't for many years to come, and thus has no Stream Order (Strahler) attribute.

Running it through Arc Hydro (burn streams) and then through SA Stream Order tool doesn't work: That generates a new stream network! Converting the NHD to a raster and combining it with FDR, another miserable fail.

A few tools (RivEX, NVS Vector Stream Tools) "Claim" they have the ability to determine stream order from a vector network, but I have yet to see that work, and their tools are made for "Lab" (perfect) environments.

I'm able to generate FromNODE ToNODE on this network, is there some easy-button in Arc Toolbox that can pull this off? REALLY need to have Stream Order on this dataset covering 700,000 acres, will take the interns a long time......


texts: QGIS - what is the core database system?

texts:
What is the core database system used by QGIS?

When you launch an existing project that has multiple .shp files (with associated .dbf tables), is the core db system used to convert that data to its own internal format as the project loads?

How about joining a simple CSV; does the core database have that import functionality, or does a Python script run independent of the core database, perform a conversion on the fly, then the core database takes the data from that script?

Once you have a project fully loaded, including a .shp file plus a .dbf, plus another CSV joined, are all the data in one common database system, so performance should be crisp and brisk? Or, does the system read in only the data needed to render the scale and scrolling you are at on the canvas, and continually re read that external CSV join as you zoom and pan around?

Suspect PostgreSQL at the core, or SQLite at the core? (So, any bug issues with those db systems will show through to QGIS?)

Are there any notes on import/export to the core database used, particularly any "rough spots" (CSV joins for instance, appears to trip many new users up.) Are those QGIS issues or the underlying db issue?

I see PosgreSQL is really Ingress (which lacked SQL), with nicely compliant SQL finally added (evolving to Post Ingress), with some object features added (including possibly spacial objects like point, line and poly)?

If PostgreSQL lies at the heart of QGIS, I'd expect performance "rotating" / manipulating relational data to be outstanding? (Ingress on pure relational data in its original form was outstanding as I recall... Do the "add ons" later on come at a cost of the core relational performance?


texts: Getting list of applications where "xyz" ArcGIS service is used?

texts:
Suppose i have xyz service, and which applications(web map, web app builder, arcgis online) uses this  service.

xyz=http://aaa.bbbbb.com/arcgis/rest/services/Utilities/PrintingTools/GPServer/Export%20Web%20Map%20Task

How do I get list of application name or id uses xyz service using ArcGIS API for Python?

I tried in online, didn't find enough information.


texts: Symbols disappear when exporting map in Arcgis

texts:
I'm trying to export map using ArcGIS.
Here's how the map looks in the layout view in Arc, and that is how i would like to keep it :

And this is how the map looks after exporting it as JPEG:

Can some one advise me please why the symbols are faded on the Baringo map and totally disappeared on the Kitui map, also why the colors, legend, and the map in general is faded?

I have tried PDF, JPEG, and PNG all give this same result. Also the symbols of the fieldwork sites on the Kitui map is not showing at all when exporting to any format !!


texts: Freelancers, how do you handle deliveries to remote clients?

texts:
Freelancers and small business owners, how do you handle product delivery and support to your remote clients? Example: I have a client who knows enough about ArcMap to add a shapefile, turn layers on and off, print a map, etc. - GIS isn't their thing, they uses it to make maps and manage digital data storage. When I have a deliverable, I spend alot time on the phone troubleshooting the deployment. Sure I can use GoToMeeting, get onto the remote box, and install everything, but its $50 a month, man! I'm also thinking of setting up a FTP site, which will be easy enough and will help with delivery of the product. But are there good options to GoToMeeting that anyone here can provide feedback on?

EDIT: Lots of good stuff being shared here, but please keep in mind I need something incredibly simple for my client to install and work with, before they can hand control over to me.


texts: Generating pattern in each of set of polygons using sp (r)?

texts:
I have an object of class SpatialPolygonsDataFrame, and for each polygon in the dataframe I have a number of points I would like to generate in that polygon (e.g. I have 130 polygons, and I have a column of 130 integers ranging from 0-10).

Is there a way with sp (or with spatstat, sf, etc.) to generate a random pattern in each polygon using the integer number associated with that polygon?


texts: Make certain countries visible on Carto map

texts:
I want to show only APAC countries on the carto map. I re-wrote my SQL query (see below) and clicked 'create a dataset from query'. Although the countries specified were coded in colors, those outside of APAC are still visible on the map.

How do I make non-APAC countries non-visible?

SELECT * FROM apac WHERE country IN ('Australia', 'Brunei', 'Cambodia', 'China', 'Laos', 'Singapore', 'Malaysia', 'Bangladesh', 'India', 'Pakistan', 'Sri Lanka', 'Philippines', 'New Zealand', 'Indonesia', 'South Korea', 'Taiwan', 'Hong Kong', 'Japan', 'North Korea', 'Pupua New Guinea', 'East Timor', 'Vietnam', 'Myanmar', 'Thailand')


texts: Area Calculation doesn't work after reprojecting the Vector

texts:
I'm trying to change the projection of resolve ecoregions data to EPSG:32648.
Unfortunately, when I changed the projection,  the command line for calculating the area doesn't work.
Here is my code :
//** Center on the Region of Interest
Map.centerObject (roi,10);

//** Import Ecoregion
var ecoRegions_raw = ee.FeatureCollection("RESOLVE/ECOREGIONS/2017")
                .filterBounds(roi)

var filtered = ee.Filter (ee.Filter.noNull())

print ('--Dataset properties--',ecoRegions_raw);

//** Reproject dataset into EPSG:32648
var projection = 'EPSG:32648';

//** Apply Reprojection and transformation
var transformer = function(a_feature) {
  var transformed_feature = a_feature.transform(projection, 0.001);
  return transformed_feature;
};

var ecoRegions = ecoRegions_raw.map(transformer);

print(ecoRegions);

//** Set up color
var colorUpdates = [
                  {ECO_ID: 204, COLOR: '#B3493B'},
                  {ECO_ID: 245, COLOR: '#267400'},
                  {ECO_ID: 259, COLOR: '#004600'},
                  {ECO_ID: 286, COLOR: '#82F178'},
                  {ECO_ID: 316, COLOR: '#E600AA'},
                  {ECO_ID: 453, COLOR: '#5AA500'},
                  {ECO_ID: 317, COLOR: '#FDA87F'},
                  {ECO_ID: 763, COLOR: '#A93800'},
                  ];

//** loop over all other features and create a new style property for styling
//** later on
var ecoRegions = ecoRegions.map(function(f) {
  var color = f.get('COLOR');
  return f.set({style: {color: color, width: 0}});
});

//** make styled features for the regions we need to update colors for,
//** then strip them from the main asset and merge in the new feature
for (var i=0; i < colorUpdates.length; i++) {
  colorUpdates[i].layer = ecoRegions
      .filterMetadata('ECO_ID','equals',colorUpdates[i].ECO_ID)
      .map(function(f) {
        return f.set({style: {color: colorUpdates[i].COLOR, width: 0}});
      });

  ecoRegions = ecoRegions
      .filterMetadata('ECO_ID','not_equals',colorUpdates[i].ECO_ID)
      .merge(colorUpdates[i].layer);
}

//** Use style property to color shapes
var imageRGB = ecoRegions.style({styleProperty: 'style'});

//** Visualize the Ecoregion dataset
Map.addLayer(imageRGB, {}, 'RESOLVE/ECOREGIONS/2017');

//** Calculating area for each feature using function
var withArea = ecoRegions.map(function(f) {
  var clipped = f.geometry().intersection(roi)
  return f
    .set('Feature_Area_ha', f.area().divide(10000))
    .set('ROI_Area_ha', clipped.area().divide(10000))
})
print ('--Resolve Ecoregion 2017 by AOI--',withArea)

//** Extract ECO_NAME and set as property
//** within for each Feature collection
var Collection = withArea.map(function(feature) {
    var feature_id = feature.id();
    var eco_name = feature_id;
    return feature.set('id',eco_name);
});//end of map function

print(Collection)

//** Create List
//** The list of keys cannot contain duplicates so this is using
var biome_names = ee.List(Collection.aggregate_array('BIOME_NAME'));
var area = ee.List(Collection.aggregate_array('ROI_Area_ha'));
var out_dict = ee.Dictionary.fromLists(biome_names,area);
print('--Area (Ha) by Biome Name--', out_dict);

Do you know why area calculation doesn't work after reprojecting the vector?


texts: Why is the altitude information of the geotag from a drone/uav/uas/rpas (Phantom 3) so innaccurate?

texts: I have a Phantom 3 4k and on examination of the geotag information the altitude reading is often inaccurate by 10-15 metres. Why is this? Is it because the drone only has a GPS rather than a DGPS unit?


texts: Recommended Books on Arcpy/Python and GIS

texts: Does anyone have recommendations on books/workbooks that I can read that goes beyond a beginner's level for Arcpy/Python with GIS?  I've written several scripts, some simple, some complex, but I want to learn how to be more efficient, and how to look at my code and improve upon it. I learn best interactive workbooks, so I'm looking for a learning medium like that.


texts: QGIS web client mobile/tablet viewer tutorial?

texts:
I have been looking at OL3-mobile-viewer as an option to make my maps more accessible. Unfortunately I cannot figure out what I need to change to hook it up with my existing QGIS server and qgis-web-client setup.

Can anybody give some guidance or direct me to a tutorial?


texts: How do you format the legend in Geoserver when using GetLegendGraphic?

texts:
I'm new to the world of GIS and geoserver so sorry if I'm asking an obvious or simple question.

I'm using GetLegendGraphic to create a legend for a raster layer on the server, as it stands it looks like this:

http://norsewind.eu:8080/geoserver/wms?REQUEST=GetLegendGraphic&FORMAT=image/png&WIDTH=20&HEIGHT=20&SCALE=160000000&LAYER=norse:norse_map_1

I'd like to know how to format the numbers to a specific number of decimal points.  Also I don't need the '=x' part, can that be removed?

Thanks


texts: ArcGIS Autoincrement field for file geodatabase using domains

texts:
I have read this thread "Autoincrement field when New Feature added" which suggests a python script to autoincrement a field.

Can anyone say if there is anyway to do this using domains or any other simpler way in a file geodatabase? I have to edit streets and would like to define a field which simply counts upwards.

For ArcGIS users that are not well versed in Python, scripts are pretty daunting, and having to run a tool every time an editing session is finished is also pretty inefficient.  It surely can´t be toooo difficult to have a new sequence-like data type in ArcGIS, can it?


texts: Self-intersecting geometry errors when splitting polygons

texts: I'm having issues digitising in QGIS 2.18.20 on my mac. My normal strategy for digitising a habitat survey area is to create a (shapefile) polygon for my survey boundary, and split the shape repeatedly.  But at present no matter how simple the shape I can't seem to split it more than once due to self-intersecting geometry errors.  What am I doing wrong?


texts: QGIS - Issue with No Data Value Pixel is changing only in header of ascii

texts:
I have changed the No Data of a raster Forest.asc into No data = 0 using Raster -> Conversion -> Translate option in QGIS. So, when I  add the output raster layer  Forest_1.asc in QGIS and check for the minimum pixel value, it is showing that Minimum = 1 and Maximum = 3. But, when I open this Forest_1.asc in TextPad and read the values, I can see that it is written that No Data Value = 0. But, I am not able to find any zero as pixel value in the ascii file. I can find only 1 and 3 as pixel value in ascii file.

How can I solve this issue ?


texts: Clipping section of polyline based on given distance from source point feature along that polyline using ArcMap?

texts:
I am working in ArcMap 10.5.1 and have a polyline feature class (streams) and a point feature class of fish sightings plotted along the streams.  I am trying to add a degree of observational uncertainty to these fish sighting locations by converting them to polylines based on potential error in location along the streams.

How may I do this?

The distance must be measured along the stream line and not the straight line distance from the source points.


texts: Generic comparison for kriging in geoR and ArcGIS

texts: I am going to do a project based on kriging. The targeted area would be as big as United States and my grid would be 10km*10km. I am wondering the differences of efficiencies for the methods implemented in geoR package and ArcGIS. Have anyone done any research on the performance yet. I would prefer geoR if it works well.


texts: Displaying raised error messages to user in ArcGIS Geoprocessing Results window?

texts:
Can print statements raised from a custom exception be displayed in the Geoprocessing Results window?

I modified a script that I found that takes two inputs from a user, finds the associated feature, then zooms to the feature.  The tool works fine.  I am trying to make it more user-friendly by automatically formatting the inputs to have the correct amount of characters.  I added a messagebox that tells the user if they have too many characters in the input box, but I used easygui to create that (a Python library for GUIs). Instead, I would like to use the gp results window to display the message.  I thought that I formatted the raise and except statements correctly but the tool runs and I get a completed result and not my error message.  I tried the arcpy help from esri and did not get the results I was looking for.

class BadInputError(Exception):
    pass

# Import arcpy module
import arcpy, sys, string
from arcpy import env

try:
    def checkInput(inp):
        mNCount = len(inp)
        trigger = 0
        while trigger == 0:
            if  mNCount == 4:
                trigger = 1
            elif mNCount > 4:
                inp = ''
                trigger = -1
                raise BadInputError
            elif mNCount == 3:
                inp = '0' + inp
                trigger = 1
            elif mNCount == 2:
                inp = '00' + inp
                trigger = 1
            elif mNCount == 1:
                inp = '000' + inp
                trigger = 1
        return inp

    # Script arguments
    MapNumber = arcpy.GetParameterAsText(0)
    MapNumber = checkInput(MapNumber)
    ParcelNumber = arcpy.GetParameterAsText(1)
    ParcelNumber = checkInput(ParcelNumber)

    Expression = (""" "MAP" = '%s' AND "PARCEL" = '%s'""") %(MapNumber,ParcelNumber)

    # Local variables:
    GISData_GISDATA_CAD_PARCEL2009_WHOLE = "Database Connections\\GISUser.sde\\GISData.GISDATA.CAD_PARCEL2009_WHOLE"
    Output_Layer_Name = Expression
    Output_Layer = "ParcelSelection"

    # Process: Select Layer By Attribute
    arcpy.SelectLayerByAttribute_management("2009 Parcel Points", "NEW_SELECTION", Expression)

    # Zoom to Selected Features
    mxd = arcpy.mapping.MapDocument('CURRENT')
    df = arcpy.mapping.ListDataFrames(mxd, "Layers") [0]
    df.zoomToSelectedFeatures()
    df.scale = 8000
    arcpy.RefreshActiveView()

except BadInputError:
    print "Too many characters.  Run again"

except Exception, e:
    # If an error occurred, print line number and error message
    import traceback, sys
    tb = sys.exc_info()[2]
    print "Line %i" % tb.tb_lineno
    print e.message


texts:
I can't find out why either maxPixels and either bestEffort works to reduce and image collection like this below. I always get too many pixels.

// Load and filter the Sentinel-2 image collection.
var collection = ee.ImageCollection('COPERNICUS/S2_SR').select('B4', 'B8')
    .filterDate('2019-05-01', '2019-09-30');

var geom = ee.Geometry.Point(-122.08384, 37.42503).buffer(50000);

// Create and print the chart.
//print(ui.Chart.image.series(collection, geom, ee.Reducer.mean(), 20 ));
//print(ui.Chart.image.series(collection, geom, ee.Reducer.median(), 50 ));
//print(ui.Chart.image.series(collection, geom, ee.Reducer.min(), 50));

var mean = ee.ImageCollection('COPERNICUS/S2_SR').select('B4', 'B8')
  .mean()
  .reduceRegion({
    reducer: 'mean',
    geometry: ee.Geometry.Point([-122.27, 37.87]).buffer(1000),
    scale: 1,
    bestEffort: true,
    maxPixels: 1e9
});

print(mean);

print(ui.Chart.image.series(collection, geom, ee.Reducer.mean(), 20 ));

Do you have any ideas?


texts: Creating planar rectangle about points of interest in Google Earth Engine?

texts:
If I have a list of points of interest in Google Earth Engine, e.g.

var pointList = [
  ee.Feature(ee.Geometry.Point(-73.96, 40.781)),
  ee.Feature(ee.Geometry.Point(6.4806, 50.8012))
];

var pointCollection = ee.FeatureCollection(features);

how can I draw a quadratic, planar region of interest around them, e.g. of size 100 x 100 km²? I have used ee.Geometry.buffer() in the past, but this function operates in geodesic geometry and doesn't lead to accurate results.

EDIT: To further specify - I am looking for a quadratic rectangle of 100 × 100 km2 in a local planar coordinate system, i.e. UTM. The problem with the buffer function is also that any rectangles are only quadratic in WGS84, but become rectangular when moving away from the equator.


texts: Is it possible to add photo-realistic clouds in ArcGlobe animations?

texts:
This question asked about the best software to produce professional fly-through animations, and included a link to a nice video of the Grand Canyon.

That video includes photo-realistic clouds in the sky. Is it possible to add clouds like this in ArcGlobe?


texts: Getting tile cache creation status on ArcGIS Server

texts:
I am creating a server side tile cache on ArcGIS Server 10.6.1 using
ManageMapServerCacheTiles_server with the wait option as the Python/ArcPy example suggests. Unfortunately this process takes 10+hrs.
I am interested in getting the tile cache status during the creation. Is the status.gdb file updated automatically during the rendering process and can I read it during the ongoing thread or is it locked?
Or is it better to send a request to the server side with proper credentials using the approach described in the article "View cache completion status"?


texts: How to make a polygon from contour lines extracted from a raster QGIS 3.6?

texts:
I'm trying polygonize the elevation level 200 m of Europe map from raster GeoTIFF (The raster is projected in EPSG:3120).
At first I tried with Raster > Extraction > Contour, but the lines are interrupted in many parts so using lines to polygon didn't convert it well, joining the line at interrupted path.
Then I tried with Vector geometry > Polygonize which in some cases created the polygons but in the major part of the map couldn't create polygons.
After that I thought to try it directly from raster using at the process toolbox from GDAL > Raster conversion > Polygonize (Raster to vector), this took about 24 hours and didn't finish the process so I canceled.

I'm stuck at this point. The other elevation levels (500m, 1000m, etc) looks fine. Maybe they have less data than 200m.
Can someone tell me whats wrong or a solution for this ?


texts: Moving parameters position in toolbox and combining parameters into one row

texts:
I've been working with ArcGis for a while now and was wondering if there was a way to change positions of parameters inside the toolbox for the user. The only time I have seen this done in arc toolbox is with the Raster clip tool with the Rectangle parameter where the 4 parameters are aligned in a circle in the toolbox.

I don't know if what I want is possible since I haven't seen anyone else do it.


texts: Dissolving points with multiple attributes in ArcGIS Desktop?

texts:
I have a series of GPS points with one ID (Track 1, Track 2, Track 3...) but they also have different fields like elevation.

I want to dissolve these GPS points using the ID, retain only 1 point per ID, and select the point with highest values, in this case, the elevation.

This can be done in ArcGIS 10.3 using Productive Planning Tool but I only have ArcGIS 10.1.


texts: Merge only lines that they are touches on QGIS 3.2.3 and create a shapefile output with the result

texts:
I have a project with five lines, every element have a different ID. This is view below:

I want to merge only lines that there are touching. According with this conditions the lines they should become two. After this i want to export all into shapefile format. The result is view here:


texts: Change Order of Features in Popup with ESRI ArcGIS Javascript API

texts:
I am using version 3.12 of the ESRI ArcGIS Javascript API and have noticed that the order of the features that show up in my info window popup does not correspond to the order layers those features are in. I want to be able to specify that all of the features from the same layer appear next to each other as I toggle though the selected features.

For example, say I have a map with two feature layers in the following order: 1. tax_parcels and 2. county_border. If I click on a spot within county_border where tax_parcels has overlapping features, I would expect my info window popup to show info for parcel1. When I click the next arrow I expect to see info for parcel2 and info for the county when I click next again. In my actual map in some cases I am seeing parcel1 followed by county followed by parcel2.

I found this thread: https://geonet.esri.com/thread/169793 but it did not provide any solutions. Does anyone know of a way to do this?


texts: Python Toolbox with Many AddField() Calls Runs Slower With Attribute Window Open

texts:
I recently finished developing a Python toolbox tool that ends up calling the arcpy.AddField_management() function about 25 times or so. I first developed it as a standalone script to get it working before I connected it up to my Python toolbox. When I started testing the tool with the exact same data I found that the run time went up from ~20 seconds in standalone to ~80 seconds when run from a Python toolbox inside an ArcGIS Pro map, a 4x increase. After playing around some more I found that it was definitely the AddField tool slowing it down, and then I noticed that if I close the attribute table in the Pro map the run time goes down to ~50 seconds.
So what I think is happening is that the Pro map is busy revalidating locks and updating the GUI, etc. unnecessarily mid-script. I also notice that when the add field tools are called the "Add" and "Calculate" field buttons start alternating being grayed out, like it is cycling through locks and UI updates or something.

Is there any way to prevent this from happening?
Can I somehow pause all that validation or whatever it is for the duration of my script?
If not, is there a more efficient method to add fields?
These short runtimes may not seem like a big deal but I now realize that I have many tools that have a LOT of calls to AddField and this is likely something that happens throughout my toolbox. I would like to make sure my code is as clean and efficient as practical.
All the feature classes that have the add field function called on are in_memory layers, and are copied to new feature classes for the output layers.


texts: How can I share my own spatial data on an online map?

texts:
Note: I am very new in this field!

Can I find an open source map that enables me to display an overlay of my own layers?

I need to add some text and rectangles for a certain area, but my modification must be on the tile level (500 mt height as example)?

I have a big work area; I need to make a new layer that determines every engineer’s works area, to be shown for my customer.
I need to provide him an interactive map, that when he zoom in the area, he will find the details when he reach 500 meter height, I need to r3epeat this method for more than one area in UAE country, and this is the reason why I need it to be an interactive map.

Example:

This is UAE country map:

This is Abu Dhabu emirates map:

This is area map:

I need to put an overlay on them (from the source data of the rectangles and text, which I included in the question), And I need to show them in web tool or any easiest way.


texts:
I'd like to know if there is a way to obtain statistical significance and p-value for correlation coefficients calculated for different raster in grass with the command r.covar

All that I obtain is the correlation matrix, but no information on statistical significance of these values.


texts: Strange behaviour of MODIS 17A3 NPP values when converting from .hdf (downloaded files) to .vrt to .tif in QGIS

texts:
I was hoping someone could help explain a behaviour that I noticed while working with downloaded MODIS 17A3 .hdf files from here:  ftp://ftp.ntsg.umt.edu/pub/MODIS/NTSG_Products/MOD17/MOD17A3/

The readme.txt file from the link above suggests a scale factor needs to be applied to the digital values of the NPP datasets to generate the biophysical variable. However, when I load a given .hdf file into QGIS 2.10.1 on Mac OSX Yosemite 10.10.5 the raster numbers appear to have the scale factor applied already (on the same order of magnitude as the User Guide's NPP values once the scale factor is applied: http://www.ntsg.umt.edu/sites/ntsg.umt.edu/files/modis/MOD17UsersGuide.pdf, Biophysical_pixel = scale_factor * digital_value = 0.0001 * 421 = 0.0421 kg C m-2.).

If I convert a single .hdf file to .tif, the 'scale-factored' number is conserved in the generated .tif file.

If I convert a single .hdf file to a virtual raster (.vrt) in QGIS, the 'scale-factored' number is no longer conserved and I am on the 'digital_value' order of magnitude again. I ask this because I want to combine several of these original .hdf files.

I tested in ArcMap 10 and it opens the .hdf on the 'digital_value' order of magnitude.

Does someone know why this might happen?


texts:
I've been struggling trying to figure this out for awhile now, and I think there's a simple solution I'm just not seeing.
The Idea:
I've got a feature layer (city limits), and I've got a point (lat/long) and I need to see if that point is in the city limits or not.
The Problem:
I can't figure out how to convert the FeatureLayer or query the FeatureLayer to provide a valid type to the geometry engine.

const featureLayer = new FeatureLayer({
    url: ""
})
map.add(featureLayer)
let graphicsLayer = new GraphicsLayer();
map.add(graphicsLayer)
var pointGraphic;
function drawPoint(pt){
  view.graphics.remove(pointGraphic)
  let simpleMarkerSymbol = {
    type: "simple-marker",
    color: [226,119,40],
    outline: {
          color: [255,255,255],
          width: 1
        }
      }
      let point = {
        type: "point",
        longitude: pt.longitude,
        latitude: pt.latitude,
      }
      pointGraphic = new Graphic({
        geometry: point,
        symbol: simpleMarkerSymbol
      });
      view.graphics.add(pointGraphic)
    }
    drawPoint(location)
    function isInside(){
      let within = geometryEngine.contains(featureLayer.geometry, pt)
      console.log(within)
    }
    isInside()
    let basemapToggle = new BasemapToggle({
        view: view,
        nextBasemap: "streets-relief-vector"
    })


texts: Why are my layers after sharing and re-downloading a QGIS map almost all unavailable?

texts:
I have made a map on QGIS and when I save it and send it to myself and re-open it, the layers are unavailable. The only layer that shows up is the one I got through ArcGIS Feature Layer service. It says it can't find the data source for all the other layers.
The way I made the layers that are now unavailable was by adding a shapefile. I then filtered the shapefile and exported it as a new layer and added it to the map.


texts: Is a proxy required to use OpenLayer's GetFeatureInfo?

texts:
My domain is hosted on HostGator and apparently they don't allow the use of proxies.

I have a map that has a WMS point feature hosted from my GeoServer using OpenLayers.

I want to be able to select a point and get information from it.

Can I do this without using a proxy?


texts: How do I convert existing fields to lat and long using the Calculate Field tool?

texts:
I am trying to convert my X and Y fields from feet to lat and long.  I can easily do this in Calculate Geometry from the attribute table, but I'm needing to use this in a model and Calculate Geometry is not available as a tool.  I'm using the Calculate Field tool and trying to find a script that converts this to lat and long.  I've tried the following script using the advanced code for VBA with no luck:

Dim dblX As Double
Dim pPoint As IPoint
Set pPoint = [Shape]
dblX = pPoint.X

dblX

I'd like to avoid having to create a totally new shapefile or feature class.  I just want to change the existing fields in this existing feature class.

Thanks!!


texts: After reading a bit about the ArcGIS-R bridge (https://r-arcgis.github.io/) it seems like the bridge is only designed for Windows, but that seems a bit odd, I think. Is there a possibility to install an ArcGIS-R bridge on a Linux server between R 3.4.4 and ArcMap 10.5?


texts: Converting ArcGIS point shapefile to Adobe Illustrator?

texts:
I have 60000 points .shp file and I want correctly convert them into .AI.
I want to receive the simple circles, but when converting I can get only:

polygon with a number of points which when zooming looks clumsily - when selected "Convert Marker Symbols to Polygons" export option.
font units(ESRI Default Marker) - when unselected "Convert Marker Symbols to Polygons"

Is it possible to automatically replace all those objects in Illustrator?


texts: Store the lat long coordinates in matplotlib figure to a table in Python

texts: The matplotlib figure is made of polygons and I want to take the centroid of each polygon and convert it into raster data and store it in a table.


texts: RasterStack extract() for duplicated dates

texts:
I have a a Large RasterStack of temperatures and a 10570 points in a Large SpatialPointsDataFrame and I'm using extract() to assign the temperatures to each point in R.

sub<-stack(temp@layers[18263:23011])
pts@data <- data.frame(pts@data, extract(sub, pts))

This gives me a table with a column for each raster:

DATE2       BICHO   X2000.01.01   X2000.01.02   (...)   X2012.12.31
2009-04-08  Woody      20.7          19.2        ...         9.1
2009-04-09  Woody      20.5          19.3        ...         9.5
2009-04-10  Woody      20.7          19.2        ...         9.6
2004-11-30  Woody      20.9          19.1        ...         9.8
2004-12-01  Buzz       20.3          19.4        ...         10
2004-12-02  Buzz       20.7          19.2        ...         9.5
2012-12-05  Buzz       20.6          19.2        ...         9.8
2012-12-05  Andy      -99.99        -99.99       ...        -99.99
2012-12-05  Rex        20.5          19.3        ...         9.1

The problem is, when there are repeated dates, the temperature value of one of the dates is set to -99. How can I solve this problem?


texts: Enabling MapTips in ArcGIS Engine using ArcObjects?

texts:
My organization is working on a new version of our software using ArcGIS Engine 10. Previous versions of the software (running on ArcGIS Engine 9.3) displayed MapTips fine as long as they were enabled in the mxd. Our new version running on ArcGIS Engine 10 doesn't display MapTips (and they are fine in the mxd).

Is there any code or setting to enable MapTips, or any known reasons that would cause them to not display in an ArcGIS Engine 10 application?

I have already discovered that layers within a Basemap layer won't display MapTips, so that is not the cause.


texts: Abnormal results projecting WGS84 to local Azimuthal Equidistant projection with pyproj

texts:
I am trying to project regular WGS84 coordinates to a local projected system (Azimuthal Equidistant), using meters and centered on the eiffel tower (as an exemple). I am using python 3.8.2 and pyproj 2.4.1 for that.

I tried to reproduce the method of Spacedman from [this post], but the results I get are clearly wrong ...

Here is my test code, trying to get the coordinates of Le Louvre Museum in that system :

# coding: utf8
import pyproj

def to_local(lon_angle, lat_angle, origin):
  crs_wgs84 = pyproj.Proj('epsg:4326') # WGS84 input projection (angle)
  crs_aeqd = pyproj.Proj(proj='aeqd', datum='WGS84', lon_0=origin[0], lat_0=origin[1], units='m') # Local Azimuthal Equidistant projection, centered on the 'origin' parameter
  x, y = pyproj.transform(crs_wgs84, crs_aeqd, lon_angle, lat_angle)
  return(x, y)

origin = (2.294473, 48.858440) # Eiffel tower in Paris
destination = (2.335769, 48.861062) # Le Louvre Museum

x, y = to_local(destination[0], destination[1], origin)
print(f'In local system centred on origin, destination has coordinates ({x}, {y})') # Result, in meters, should be around (3030, 290)

From what I roughly computed manually, I should get something like 3030 meters as longitude and 290 meters as latitude, both positive since Le Louvre is North-West from the Eiffel Tower, but here is the output :

> In local system centred on origin, destination has coordinates (5635219.051216577, -3788748.14149113)

I don't understand thoses values, what am I missing here ?


texts: Return roads that extend entire length of bounding box from OSM data

texts:
Lets say I have a bounding box of lat/lon of:

Left -122.27671
Bottom 37.80445
Right -122.26673
Top 37.81449

I have OSM Data of all roads/ways/nodes...etc within this bounding box. Is it possible to return roads that extend the entire length of the bounding box? Or that intersect with two different areas of the bounding box?

Or is there a better way to solve this: I'm essentially trying to filter out small side streets. Maybe I could do this by the type of way or by the total length of the way?


texts: Raster calculator - set default output path - QGIS 3.4.6

texts:
Raster calculator: How can I set the default output folder?
By default it's set to "C:\Program Files\QGIS 3.4\bin"
I'm using QGIS 3.4.6


texts:
I've written a bit of code to do a simple spatial join in QGIS 2 and 2.2 (points that lie within a buffer to take attribute of the buffer). However, I'd like to employ a QgsSpatialIndex in order to speed things up a bit. Where can I go from here:

pointProvider = self.pointLayer.dataProvider()
rotateProvider = self.rotateBUFF.dataProvider()

all_point = pointProvider.getFeatures()
point_spIndex = QgsSpatialIndex()
for feat in all_point:
    point_spIndex.insertFeature(feat)

all_line = rotateProvider.getFeatures()
line_spIndex = QgsSpatialIndex()
for feat in all_line:
    line_spIndex.insertFeature(feat)

rotate_IDX = self.rotateBUFF.fieldNameIndex('bearing')
point_IDX = self.pointLayer.fieldNameIndex('bearing')

self.pointLayer.startEditing()
for rotatefeat in self.rotateBUFF.getFeatures():
    for pointfeat in self.pointLayer.getFeatures():
        if pointfeat.geometry().intersects(rotatefeat.geometry()) == True:
            pointID = pointfeat.id()
bearing = rotatefeat.attributes()[rotate_IDX]
self.pointLayer.changeAttributeValue(pointID, point_IDX, bearing)
self.pointLayer.commitChanges()


texts: Extract point cloud data from shapefile with Python

texts:
I am trying to plot profiles from LAS data. So my first step is to extract the data using a shapefile. I found this piece of code on the laspy website and thought I could use it to do this :

def explode(coords):
   for e in coords:
       if isinstance(e, (int, float,complex)):
           yield coords
           break
       else:
           for f in explode(e):
               yield f

def bbox(f):
    x, y = zip(*list(explode(f['geometry']['coordinates'])))
    return min(x), min(y), max(x), max(y)

def clip_extract(las_file , shp_file ):
    import laspy, os
    import numpy as np

    inFile = laspy.file.File(las_file, mode = "r")
    shp = fiona.open(shp_file, "r")

    min_x, min_y, max_x, max_y = acav.bbox(shp)
    X_invalid = np.logical_and((min_x <= inFile.x),
                              (max_x >= inFile.x))
    Y_invalid = np.logical_and((min_y <= inFile.y),
                              (max_y >= inFile.y))
    Z_invalid = np.logical_and((inFile.header.min[2] <= inFile.z),
                              (inFile.header.max[2] >= inFile.z))

    good_indices = np.where(np.logical_and(X_invalid, Y_invalid, Z_invalid))
    good_points = inFile.points[good_indices]

But of course it extracts the full min(x), min(y), max(x), max(y) rectangle while ideally it would only extract the points within the shapefile :

I have read many other posts on how to mask a numpy array with a shapefile but I can't seem to find one that match my case... I am trying to do this with Fiona or shapely, and Numpy.