texts:
I was working in a project (in QGIS) which had rule based style, when I  draw a new polygon it disappears, I now know this was because I didn't assign it a value to comply with the rule based style, but how can I show these polygons so I can delete them?

I tried to open the shapefile without the rule based style and the polygons I drew that disappeared don't show, they also don't appear on the attribute table, I know they are there because when I draw another polygon and assign it a reference, that one disappears and the reference gets allocated to another missing polygon!


texts: R raster / rasterize creating GeoTIFF with Null Value "grid lines"

texts:
I am attempting the seemingly simple task of converting a .csv with lat, lon and population values into a .tif (raster).

Here's my R code:

geoName <- read.csv("/pathToData/geoName.csv")
geoName_raster <- raster(xmn=min(geoName$longitude), xmx=max(geoName$longitude), ymn=min(geoName$latitude), ymx=max(geoName$latitude), res=0.0027, crs="+proj=longlat +datum=WGS84")
geoName_rasterize <- rasterize(geoName[, c('longitude', 'latitude')], geoName_raster, geoName[, 'population'], fun=sum)
writeRaster(geoName_rasterize, "/pathToData/geoName_rasterize.tif")

The .csv is formatted like this:

longitude,latitude,population
-73.274688427539,19.817098050328,100.001
-72.697905721098,19.82226569178,200.002
-73.153838375345,19.799009402678,300.003
-72.71163913536,19.873934311831,400.004
-72.887420723946,19.863602053517,500.005
-73.288421351258,19.850685573779,400.004
-72.752838665811,19.79384121785,300.003
-72.939605787255,19.871351380997,200.002
-73.126372968453,19.713707358991,100.001

The output has bands of null values which appear to be influenced by the res value: the bands are further apart as res approaches 0.

The .tif with narrow bands below is with no res specified

The .tif with wide bands is with res = 0.0027 (which is the approximate width in degrees of a Bing tile at z17 which is the resolution of the population data set)

I've read a few different R documentation pages outlining resolution, but I don't really understand its function.

My questions: what is res doing and how do I replace these bands with the data which belongs in those pixels?

Be gentle: I'm very new to R.


texts: When I export shapefiles from ArcMap 10 there appears to be no xml file created?

texts:
When I create shapefiles in ArcMap, be it by selecting certain features from existing data or creating new polygons/points/lines,
I look in My Computer and see a dbf prj sbn and sbx file.
These shapefiles all successfully open in ArcMap, but I'm trying to upload these shapefiles to Mangomaps.com and the lack of an shp file is crucial.
When I open up the shapefiles in ArcMap an shp mysteriously appears in the form of "(Whatever the name of my shapefile is).shp.URA-0422.6328.6588.sr.lock" URA is the name of the place where I work and just fyi before someone harps on me for sharing important information I changed some of those numbers in case they have significance.
However this locked shp can't be uploaded and immediately disappears once ArcMap closes.
What's going on? Do I have some sort of setting preventing ArcMap from creating an shp/xml document?


texts: ArcMap Remote Desktop Connection Error LoadLibrary failed with error 126

texts:
Environment:
ArcMap 10.6.1 loaded on Windows 10 PC
RemoteApp with Remote Desktop application
Windows 8 PC (used for remote access)

Issue:
ArcMap 10.6.1 works as expected when logged directly into the PC it is loaded on.  However, now that we are teleworking, I am using a Windows 8 PC to access my Organization's RemoteApp application and use Remote Desktop to log into my computer.  I am able to open ArcCatalog and all connections are listed.  However, if I click on a feature class to preview, I get an error that says, "LoadLibrary failed with error 126: The specified module could not be found." Also, if I try to open ArcMap I get the same message.

Troubleshooting:
First, we had other users attempt to use Remote Desktop to access the PC and open ArcMap. Other users received the same error message ("LoadLibrary failed with error 126: The specified module could not be found.")
Next, we edited group policy and Enabled parameters in the Remote Session Environment per
https://gis.stackexchange.com/a/354868/160425  (thanks for that!)

We tested again and found that some users could now open ArcMap with no problem using Remote Desktop, however others are still unable to.

Here are our test results so far:
*  [User1] VPN from PC with Windows 10 + Remote Desktop = ArcMap works as expected
*  [User2] RemoteApp from PC with Windows 7 + Remote Desktop = ArcMap works as expected
*   [User2] RemoteApp from PC with Windows 10 + Remote Desktop  = Error: “LoadLibrary failed with error 126: The specified module could not be found"
*  [User3] RemoteApp from PC with Windows 8.1 + Remote Desktop  = Error: “LoadLibrary failed with error 126: The specified module could not be found"
*  [User4] PC on Org Network with Windows 10 + Remote Desktop  = Error: “LoadLibrary failed with error 126: The specified module could not be found"


texts: Gdal: How to reproject from equirectangular to mercator?

texts:
I work with raster ETOPO1, made a crop of my area of interest.

curl -L -C - 'http://www.ngdc.noaa.gov/mgg/global/relief/ETOPO1/data/ice_surface/grid_registered/georeferenced_tiff/ETOPO1_Ice_g_geotiff.zip' -o ./ETOPO1.zip
unzip -n ./ETOPO1.zip '*.tif'
# --- crop
gdal_translate -projwin -5 51 10 41 ETOPO1_Ice_g_geotiff.tif cropXL.tmp.tif
# --- resize for speed sake
gdalwarp -of GTiff -s_srs epsg:4326 -t_srs epsg:4326 -te -5 41 10 51 -ts 1200 0 cropXL.tmp.tif resized.tmp.tif
# --- reproject into mercator
gdalwarp -of GTiff -s_srs EPSG:4326 -t_srs EPSG:3857 resized.tmp.tif resized-mercator.tif

But this result into an incorrect file. What does I do wrong ? How to reproject correctly from EPSG:4326 to EPSG:3857 ?

Note: command inspired by Re-project raster image from Mercator to Equirectangular

Edit:

yug@yug-PC:~/projects/WikiAtlas_scripts/back$ gdalinfo ./01_reliefs/crop_resized.tmp.tif -hist
Driver: GTiff/GeoTIFF
Files: ./01_reliefs/crop_resized.tmp.tif
       ./01_reliefs/crop_resized.tmp.tif.aux.xml
Size is 1962, 1551
Coordinate System is:
PROJCS["WGS 84 / Pseudo-Mercator",
    GEOGCS["WGS 84",
        DATUM["WGS_1984",
            SPHEROID["WGS 84",6378137,298.257223563,
                AUTHORITY["EPSG","7030"]],
            AUTHORITY["EPSG","6326"]],
        PRIMEM["Greenwich",0],
        UNIT["degree",0.0174532925199433],
        AUTHORITY["EPSG","4326"]],
    PROJECTION["Mercator_1SP"],
    PARAMETER["central_meridian",0],
    PARAMETER["scale_factor",1],
    PARAMETER["false_easting",0],
    PARAMETER["false_northing",0],
    UNIT["metre",1,
        AUTHORITY["EPSG","9001"]],
    EXTENSION["PROJ4","+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext  +no_defs"],
    AUTHORITY["EPSG","3857"]]
Origin = (11365720.009993232786655,1654650.287315490888432)
Pixel Size = (323.425157454019200,-323.425157454019200)
Metadata:
  AREA_OR_POINT=Area
  NC_GLOBAL#Conventions=COARDS/CF-1.0
  NC_GLOBAL#GMT_version=4.4.0
  NC_GLOBAL#history=grdreformat ETOPO1_Ice_g_gdal.grd ETOPO1_Ice_g_gmt4.grd=ni
  NC_GLOBAL#node_offset=0
  NC_GLOBAL#title=ETOPO1_Ice_g_gmt4.grd
  x#actual_range=-180, 180
  x#long_name=Longitude
  x#units=degrees
  y#actual_range=-90, 90
  y#long_name=Latitude
  y#units=degrees
  z#_FillValue=-2147483648
  z#actual_range=-10898, 8271
  z#long_name=z
Image Structure Metadata:
  INTERLEAVE=BAND
Corner Coordinates:
Upper Left  (11365720.010, 1654650.287) (102d 6' 0.00"E, 14d42' 0.00"N)
Lower Left  (11365720.010, 1153017.868) (102d 6' 0.00"E, 10d18' 6.40"N)
Upper Right (12000280.169, 1654650.287) (107d48' 1.26"E, 14d42' 0.00"N)
Lower Right (12000280.169, 1153017.868) (107d48' 1.26"E, 10d18' 6.40"N)
Center      (11683000.089, 1403834.078) (104d57' 0.63"E, 12d30'36.90"N)
Band 1 Block=1962x2 Type=Int16, ColorInterp=Gray
  Min=0.000 Max=0.000
  Minimum=0.000, Maximum=0.000, Mean=0.000, StdDev=0.000
  1 buckets from 0 to 0:
  0
  NoData Value=-2147483648
  Metadata:
    NETCDF_VARNAME=z
    STATISTICS_MAXIMUM=0
    STATISTICS_MEAN=0
    STATISTICS_MINIMUM=0
    STATISTICS_STDDEV=0


texts: EE:A region must be a GeoJSON Polygon or LinearRing. Got: 'MultiPolygon'

texts:
Tried to export transition classes for a region of interest. I cant export image to  drive for my selected feature collection. Getting an error after running for a while,"A region must be a GeoJSON Polygon or LinearRing. Got: 'MultiPolygon'.
Here is the code below- how can i export image for a region that i selected from my  shapefiles?

var reg = ee.FeatureCollection('users/karmakersourav/shape')
    .filter(ee.Filter.eq('NAME_1', 'Chittagong'));

Map.addLayer(reg);

var gsw = ee.Image('JRC/GSW1_0/GlobalSurfaceWater');
var transition = gsw.select('transition');
Map.addLayer({
eeObject: transition,
  name: 'Transition classes (2010-2015)',
});

Export.image.toDrive({
 image: gsw,
 description: 'imageToCOGeoTiffExample',
 scale: 30,
 region: reg,
 fileFormat: 'GeoTIFF',
 maxPixels: 1e12,
 formatOptions: {
    cloudOptimized: true
  }
});


texts: How to get point-in-polygon for different time stamps?

texts:
I have an input polygon vector layers which is essentially a single KML file containing different areas over Europe. I also have an input point vector layer which is actually flight data, which contains Lat/Lon and time stamp (24hr worth of data) of aircrafts.

What I am trying to do is to get the maximum number of aircrafts that will be inside each of these polygons over the 24hr window.

I have tried Points in Polygon, but that gives me the total number of points registered inside each polygon, but they may occur at different times of the day. What I basically want is a max of max.

EDIT

@Henhuy
when i include: print(max_points, max_id, feature.id()) in the loop, i get the max values printed as follows:

But this is how it is shown in the attribute table:

In my case, row 884 (object id 885) should have a max_point of 4, but it is showing this as NULL.


texts:
I am looking to do a simple append using Pyshp and keep running into walls.  The
editor object could not read the dbf header for the input shapefile so I tried using reader and writer as suggested but have run into some problems with writer.

Initially I wanted to copy entire ShapeRecord objects but did not see a way to use writer to write them, so I tried a more granular approach like iterating and copying shape and record attributes which failed as well:

reader = shapefile.Reader('c:/temp/input.shp') #Open input file
w = shapefile.Writer(shapefile.POLYGON)        #Create writer
w.field('FLD1','C','20')                       #Create fields
w.field('FLD2','C','20')
w.field('FLD3','C','20')
w.field('FLD4','C','20')
w.field('FLD5','N','20')
w.field('FLD6','N','20')
w.field('FLD7','C','20')
for sr in reader.shapeRecords():         #iterate through shapeRecords in the input
    w.poly(sr.shape)                     #write shape to writer
    w.record(sr.record)                  #write record to writer
w.save('c:/temp/appendoutput.shp')       #save writer to file

I end up with two errors:

IndexError: tuple index out of range for w.record(sr.record)
File "C:\Python26\ArcGIS10.0\lib\shapefile.py", line 959, in record
[record.append(recordList[i]) for i in range(fieldCount)]
This perplexes me since print sr.record shows me that there are seven items in the record list that was read in by the reader and I have seven fields.
TypeError: iteration over non-sequence for the w.poly(sr.shape)


texts: How to tell if GeoWebCache REST API is working?

texts:
In my web application, i wanted a service to cache updated data using geowebche. so i worked on seeding tiles automatically with GeoWebCache as in this post:
custom time interval for geowebcache

then i replaced wms with gwc/service/wms in layer requesting in OpenLayers. i didn't do anything more than what's in the post. here it said i have to install the extinction but i didn't. http://docs.geoserver.org/2.0.0/user/extensions/rest/installation.html#rest-installation

Now, how can i tell if it works? do the tiles get refreshed by themselves without me refreshing the page or what?

and I use WMS to display my points on the map, is there any way to cache the layer where it doesn't need to reload points whenever i navigate on the map?


texts: Any way to perform zonal statistics on column other than value or do reclass faster?

texts:
I have to perform ArcGIS zonal statistics on a raster, but the column I am interested in is not the 'value' column. Now, I can reclass the raster so that the column of interest becomes the 'value' column. However, the reclassification is super slow (reclassifying a 60 m raster for the US Midwest, length of reclass ASCII file ~500,000 rows.)

Is there any way I can skip the reclassification and just perform zonal statistics on my column of interest? Alternatively, any tips on making the reclassification process much faster will help too. Currently the reclassification is on course to take 10 hours to finish.


texts: Intersecting line at junction in PostgreSQL

texts:
I have roads of a country having 899371 features, which were in shapefile and I had imported to PostGIS. I am trying to intersect line at every junction. I have used following commands:
1st command:
CREATE TABLE line_intersection AS
SELECT DISTINCT (ST_DUMP(ST_INTERSECTION(a.geom, b.geom))).geom AS ix
from roads_with_type a
INNER JOIN roads_with_type b
ON ST_INTERSECTS(a.geom, b.geom)
WHERE geometrytype(st_intersection(a.geom, b.geom)) = 'POINT';

2nd command:
CREATE INDEX ON line_intersection USING gist(ix);

3rd command:
CREATE TABLE line_union AS
SELECT ST_UNION(geom) as geom
FROM roads_with_type;

4th command:
CREATE INDEX on line_union USING gist(geom);

All above commands run successfully. How ever the last command I run, it takes more then 12 hours and still running. My last command is :
CREATE TABLE line_segments AS
SELECT(ST_DUMP(ST_SPLIT(a.geom,b.ix))).geom
FROM line_union a
INNER JOIN  line_intersection b
ON ST_INTERSECTS(a.geom, b.ix);

Is there any faster way to do this? I am using PostgreSQL 12 and PostGIS 3.0.


texts: Losing elevation values converting to CAD in ArcGIS for Desktop?

texts:
This is complex and my first question. I'm using 10.3 and need to export a lot of contour files to CAD. When I do this individually, they convert fine and retain the elevation values. Having hundreds, I used model builder to accomplish this task and the elevation values come out wrong: .0001 feet.

Could the problem be with my iterator? I'm not familiar with these and wonder if not selecting the optional feature type is part of my problem. I'm going to run the model one more time with the "line" feature type selected.

Yes, I have the "Elevation" field properly named for the fickle CAD conversion. I do have an alias for it. Again, I can manually export to CAD without any issues.


texts: Georeferencing SpecTIR Free Data Sample from IGM and/or GLT files

texts:
I have recently downloaded some data from the official SpecTIR website for some personal research interests. The website says that the ZIP file contains information about how to geo-reference the image sets. Appropriate information is given in the webpage and the links to download the data as well. I downloaded the Gulf of Mexico Wetland Sample (Lower Suwannee NWR) dataset, which are in ENVI Header file format.

Can anyone provide any insight into this? Else, can anyone at least point to the right forum, in case this is not appropriate for GIS-SE.


texts: Changing colour of point based on null value using Arcade Expression in ArcGIS Online?

texts:
I have a map in ArcGIS Online with a point layer showing lighting assets. These are symbolised based on unique type (post = circle, column = square).

The user will update a separate field to have a unique alphanumeric ID for each Asset.

I would like to use an Arcade expression to change the colour of the points when the field value changes from null to its new ID.

E.g. If the Unique ID is null the point colour is red, if the Unique ID is not null then colour green.

I haven't used the Arcade language before and cannot find guidance online for this particular query.


texts: Randomly shuffle values from a column into a series of new columns in a feature class in ArcGIS for Desktop?

texts:
I am trying to run a Monte Carlo simulation on a point feature class. In order to do so, I am trying to take the values from a column of observed data and randomly "shuffle" them between the points over n additional "simulated" columns. In my case, I'd like to add 199 new columns, each with the values of the the observed data randomly redistributed among the points.

My observed data are binary (1 and 0)

I have been able to do this in R previously and bring the table back into ArcGIS, but the tables have become so unwieldly that I am having difficulty bringing them back into ArcGIS, and would like to run the analysis in ArcGIS, rather than moving in and out.

Does anyone have any idea how to do this? I have tried using cursor, but have failed.


texts: Changing processing extent with each iteration using ArcGIS10 ModelBuilder

texts:
I have a very large raster for which I am trying to compute zonal means using a shapefile that covers the same extent but has hundreds of thousands of individual polygons as zones. Trying to just use the large shapefile as the input feature zone and the raster as the value raster doesn't seem to work.

What I have done is split up the large shapefile into ~50 shapefiles containing a more manageable number of individual polygons in each. I am now trying to use ModelBuilder to iterate through those ~50 shapefiles and compute the zonal mean using their individual polygons and the large value raster.

What I am having trouble with is changing the processing extent to match that of the zone shapefile for each iteration. This seems necessary for this workflow to complete successfully (It worked for me when I tried it manually on one of the shapefiles, outside of ModelBuilder) - if I leave the extent as default, or set it to that of the large raster, the tool freezes or crashes.

It seems like I should change the processing extent in ModelBuilder to "Same as variable 'input shapefile'".

Will this change the extent with each iteration?

The few times I have tried this it crashes ArcMap and I get the message:

  ArcGIS Desktop has encountered a serious application error and is
  unable to continue.


texts: How to access a "geoprocessing value object" when a row in ValueTable is empty (Python Toolbox)

texts:
I have a tool with a ValueTable consisting of two columns - text (GPString) and layer (GPFeatureLayer).
When I fill the parameter with desired values (field names in the first column, some feature layers in the second column, I can run the tool.
Problem is that not every row is filled with a layer, so some rows have the field names only. The second row of the value table then returns:

a geoprocessing Layer object if it has been filled with a feature layer or
a geoprocessing value object if it has not been filled with a feature layer.

It looks like this:

I have a problem accessing the values row by row - I want to process all the rows with filled feature layer:
...
def getParameterInfo(self):
    """Define parameter definitions"""
    param0 = parameter("lokality", "Lokality", "GPFeatureLayer")
    param1 = parameter("value_table", "Atributy a FeatureLayery", "GPValueTable", "Optional")

    param1.columns = [["String", "Atribut"], ["GPFeatureLayer", "Limity"]]

 def execute(self, parameters, messages):
    """The source code of the tool."""
    lokality = parameters[0].valueAsText
    valuetable = parameters[1].value

    for v in valuetable:
       # if v[1] has been filled, it is a geoprocessing layer object. I can check e.g. its name and continue
       if v[1].name:
          do something

       # if v[1] has not been filled, it is an empty(?) geoprocessing value object, I don´t know how to handle this empty row

How can I check if a layer has been filled and process rows with filled layers only?


texts: How do I get JSON data into Python script from a ArcGIS geoprocessing service?

texts:
I am using Network Analyst to calculate the travel time from point A to point B. I need to do this for thousands of points, so the obvious solution is automating in Python. While I can write a script that calls the relevant ArcPy tools, I'd like to be able to just call our network analyst webservice and parse its results -- I only need the travel time, not the turn-by-turn directions, the route, or any of the other informative results produced through Network Analyst. I assumed that would be faster.

Based on this answer and the Requests module documentation, I thought this would work:

import requests

response = requests.get('http://[url]/arcgis/rest/services/Click/ClickRouting/NAServer/Route',
                        auth=('[user]', '[password]'))

print response.text
print response.json()

BUT, I'm getting a 401 error that claims I don't have permission, even though I can see it just fine through a web browser. Our ArcGIS server guy says that service is not restricted, and doesn't know why there would be an authentication error.

401 - Unauthorized: Access is denied due to invalid credentials.

You do not have permission to view this directory or page using the credentials that you supplied.

Am I not using requests correctly, or is this a service configuration issue?

(If this doesn't have enough to do with GIS, I apologize; either migrate, or I will ask again on StackOverflow.)


texts:
I want to read sentinel-2's image (jp2 format)  with anaconda:

geopanda: for read shapefile
folium (for create map in jupyter notebook ) (optional)
gdal /osgeo : for read jp2 image

I follow this excellent tutorial:

https://medium.com/@chrieke/howto-install-python-for-geospatial-applications-1dbc82433c05

My problem is that geopandas and fiona, maybe folium are not compatible with gdal v3.0.0.

With this command : conda install gdal , gdal v3.0.0 is installed by defaut.

If you install geopanda, then gdal is downgraded, but gdal v2... does not read jp2 image.

If I do not install geopanda then I cannot read shapefile.

If I install geopanda after installing gdal, then gdal cannot read a jp2 image.

Is there any way to read the jp2 with gdal downgraded?

EDIT:
This is what anaconda does when I install geopandas

  The following packages will be REMOVED:

  geotiff-1.5.1-h6e819c3_4   proj-6.2.0-ha7a8c7b_1

  The following packages will be UPDATED:

  pcre                 conda-forge::pcre-8.41-h6538335_1003 -->
  pkgs/main::pcre-
  8.43-ha925a31_0

  The following packages will be SUPERSEDED by a higher-priority
  channel:

  gdal               conda-forge::gdal-3.0.1-py36h2fee047_9 -->
  pkgs/main::gdal-
  2.3.3-py36hdf43c64_0   geos                   conda-forge::geos-3.7.2-he025d50_2 --> pkgs/main::geos-
  3.7.1-h33f27b4_0   icu                      conda-forge::icu-64.2-he025d50_1 --> pkgs/main::icu-5
  8.2-ha66f8fd_1   libgdal             conda-forge::libgdal-3.0.1-haf49bb1_9 --> pkgs/main::libgd
  al-2.3.3-h10f50ba_0   rasterio
  conda-forge::rasterio-1.0.28-py36h261~ --> pkgs/main::raste
  rio-1.0.21-py36h6bd7d87_0

  The following packages will be DOWNGRADED:

  hdf5                           1.10.5-nompi_ha405e13_1103 -->
  1.10.4-nompi_hcc 15c50_1106   kealib                               1.4.10-hf7dc31f_1005 --> 1.4.10-heacb130_ 1003   libnetcdf                             4.6.2-h376842a_1003 --> 4.6.2-h396784b_1 001   libspatialite                        4.3.0a-hee5a54d_1031 --> 4.3.0a-h6a0152f_ 1026

If I validate this choice, then jp2 driver is remove to the list gdalinfo --formats.

I need on the same platform of geopandas, gdal and rasterio.

Is there a solution?


texts: ArcMap Replication tool does not synchronize changes made from database tool i.e SQL Developer?

texts:
I want to synchronize some datasets and feature classes from Oracle to MS SQL Server using ArcMap replication tools. Both databases are geodatabase enabled.
I don't want to replicate/synchronize data in real time but once a day.
I have created one-way replica(parent to child) and it works fine for only the changes that are made from ArcMap, but when I make changes in the table/feature class from Oracle (SQL Developer) i.e updating the attributes of a record, those changes are not synchronized.
How can I synchronize all the changes either made from ArcMap or from SQL Developer?


texts: Using PostgreSQL/PostGIS as database with ArcGIS Pro?

texts:
Using ArcPro 2.5 I can connect to our PostgreSQL/PostGIS database (9.6.15/2.3), but I cannot edit the features. In ArcPro I get the error message "The enterprise database table is not registered with the Geodatabase. Edits cannot be made."
Can I use ArcGIS Pro (2.5) to connect to our PostgreSQL/PostGIS database to make revisions and edits to existing data?
What I have tried: Extensive reading on the ESRI website.


texts:
I'm regularly backing up an ArcSDE Geodatabase. The backup is done by using arcpy.Copy_management to copy datasets from SDE to a local File GeoDatabase.

How can I verify the integrity of the back up and ensure that nothing is corrupt?


texts: How to import and project ASTER 1B data into Arcmap?

texts:
I recently purchased a granule of ASTER 1B data from ERSDAC, when I import any of the associated rasters into ArcGIS, the image is displayed as being only 1m across, when the actual area represented is tens of kilometers across. Aside from this, the image is also in the incorrect location. The raster came already projected in UTM zone 35N but the area the raster represents is in UTM Zone 35S. I have tried both defining and projecting the coordinate system of the the raster to WGS1984 Zone 35S to no avail.

I am using ArcGIS 10.2

Does anyone have any idea of what the issue might be?


texts: Add a custom search to an OpenLayers map

texts:
I have looked at this thread: add location search to openlayers map
but it is not the result that I am trying to achieve.

Probably best if iI show you: http://www.potholestudios.com/Content/pid=46.html

I have made this Interactive Game Map using OpenLayers. What I would like to do is add a search box, so when say someone types into a search box "Deep Space 9" the map would fly to coordinates (-33.87, -8.58) Deep Space 9 in the Beta Ursae sector block.

Now, I'm guessing I'd have to list the X,Y coordinates of every system in a list with names. So that when a name is entered in a search box it moves the map to the listed coordinates.

But I have no idea even where to start with this, any help would be appreciated.


texts:
I am trying to convert KML to shapefile.

I'm using ogr2ogr (gdal version = 2.0.0).
Here is the command:

/home/vineet/Project/gdal-2.0.0/bin/ogr2ogr --config  SHAPE_ENCODING UTF-8 -update -append  output.shp /home/vineet/Desktop/rail.kml -nln output -nlt GEOMETRY

I have all three ways mentioned here: ogr2ogr kml to shp conversion created 184 shapefiles?! What am I missing?

And each time its giving me same error:

Warning 6: Normalized/laundered field name: 'description' to 'descriptio'

Warning 6: Field timestamp create as date field, though DateTime requested.
Warning 6: Field begin create as date field, though DateTime requested.

Warning 6: Field end create as date field, though DateTime requested.

Warning 6: Normalized/laundered field name: 'altitudeMode' to 'altitudeMo'

FAILED: Layer output already exists, and -append not specified.
Consider using -append, or -overwrite.

ERROR 1: Terminating translation prematurely after failed
translation of layer Professional Leagues (use -skipfailures to skip errors)

Any idea why ogr is giving me these errors?

OR

Any other way to directly dump KML to PostGIS (all data in single table)


texts: QGIS- extract raster information into a point return nulls

texts:
I have a 1) raster layer and a 2) point layer.

I want to extract the pixel value to each point, but it is not working when using this tools (QGIS):

plug-in "Point sampling tool" (the new shapefile is full of "null" cells)
"SAGA > Vector to raster > Add raster values to points"

Do you know which more tools are available?


texts: QGIS Server WFS/WMS user and pass authentication

texts:
I configured a QGIS project as follows:

As you can see, QGIS Server is now serving two layers using WFS or WMS service. These two layers don't have the user/pass parameters saved in their layer configuration, so every time I open the project I am prompted to insert the user pass for the PostGIS connection (they are PostGIS layers):

Now we go to client (another computer) and I open a QGIS Client and I configure a new WFS connection introducing the user and password here (the user and password for the server to connect to PostGIS database):

I can see in the GetCapabilities request made by QGIS Client (captured using Fiddler proxy) that it is now adding authorization info in header:

If I try to connect to this new connection I get "there is no layer in service's capabilities".

I don't know if QGIS server is not binding the user/pass stored in HTTP's header to the QGIS project to connect the layers to PostGIS or what...

My goal is to be able to connect to QGIS Server using WMS/WFS services with different users and the server should connect to PostGIS with the user introduced in the client (this way I could in PostGIS know which user  is connected, making changes, and control what each user can or can't do)


texts: Seems that there no tag for datums or coordinate system in kml file?

texts:
I have a very simple kml file written as xml format:

<?xml version="1.0" encoding="utf-8"?>
<kml xmlns:kml="http://earth.google.com/kml/2.2">
  <Document id="featureCollection">
    <Style id="defaultStyle">
      <LineStyle>
        <width>1.5</width>
      </LineStyle>
      <PolyStyle>
        <color>7d8a30c4</color>
      </PolyStyle>
    </Style>
    <Folder>
      <Placemark>
        <styleUrl>#defaultStyle</styleUrl>
        <ExtendedData>
          <Data name="innerwater">
            <value></value>
          </Data>
          <Data name="shape_len">
            <value>0</value>
          </Data>
          <Data name="shape_are">
            <value>0</value>
          </Data>
          <Data name="perimeter">
            <value>0</value>
          </Data>
          <Data name="sde_sfgis">
            <value>0</value>
          </Data>
          <Data name="objectid">
            <value>1</value>
          </Data>
        </ExtendedData>
        <MultiGeometry>
          <Polygon>
            <outerBoundaryIs>
              <LinearRing>
                <coordinates>
    -122.33333333333333,37.83333333333333
-122.33333333333333,37.70000000000000
-122.53333333333333,37.70000000000000
-122.53333333333333,37.83333333333333
                </coordinates>
              </LinearRing>
            </outerBoundaryIs>
          </Polygon>
        </MultiGeometry>
      </Placemark>
    </Folder>
  </Document>
</kml>

From the coordinates, you can easily understand that the used datum is WGS-84.
But I've been searching the kml documentation for about an hour now and I can't find any tag for datum definition.
Does that mean KML files just support coordinates reported in WGS-84?
(I know that google earth coordinates are in WGS-84)
If not, then how a geospatial software will understand what's the datum used? And which formulas should be used to project it on the map?


texts:
I have a couple of python installations on my windows 7 machine. I have the one that was installed by ArcGIS, in a folder called "ArcGISx6410.2", and another I recently installed myself directly from the python website, I've put that in a folder called "DirectDownload".

The one installed by ArcGIS is the default one which I normally use, and which the windows path points too. This is what I get when I call python from the command prompt:

Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

U:\>python
Python 2.7.5 (default, May 15 2013, 22:44:16) [MSC v.1500 64 bit (AMD64)] on win 32
Type "help", "copyright", "credits" or "license" for more information.
>>> import sys
>>> sys.executable
'C:\\Python27\\ArcGISx6410.2\\python.exe'

But, ArcGIS itself appears to call the "DirectDownload" installation, and that one doesn't contain numpy, and can therefore not import arcpy. I don't need the "DirectDownload" installation any more, but if I remove it (or rename it) then ArcGIS will not load at all, it will not get past the splash screen.

How can I tell ArcGIS to use it's own installation of python, like it was doing quite happily until I installed the other version?


texts:
When I use Open Street Map and execute it as a background, it couldn't show up. Instead, The screen in QGIS became black.

How can I reorder it?


texts: Is there a version of the NLCD that doesn't have developed areas?

texts:
I'm currently working on a personal project that requires that I remove the developed areas from the NLCD. I'm currently using the 2011 data, and I have some solutions in my head that might work, but is there already data that has the assumed biome/terrain for these developed areas?

Edit: I plan on filling in the developed areas by gathering the nearest landcover data, i.e. woodlands, wetlands, etc, and based on the percentage of my nearby sample, will fill in the developed land with appropriate "blotches".


texts: Looking for USA county level health and socio-economic indicator data that is comparable to data on other countries of the world

texts:
I want to compare USA counties with other countries.

I am looking for USA county level health and socio-economic indicator data that is comparable to data on other countries of the world.

Ideally the answers provided will come with URL links to the data sources.

Ideally, if you are an expert in a domain area, you can share your knowledge about making comparisons using specific variables/indicators.

Thanks


texts: How do I make an icon with some text to popup when I hover over it and for it not to be slow?

texts:
I would like to make an icon on the screen and have hover popup text. Ideally the text will be black with a white background.

Right now my icon is a bitmap created like this

GraphicTrackerClass incidentIcons = new GraphicTrackerClass();
incidentIcons.Initialize(mapControl.Map as IBasicMap);
int graphicID = incidentIcons.Add(thisIncident.point, alertIcon);

Then I set up a hit test and would like a text popup when I hover over the GraphicTracker (should I use a different class for displaying the icon?).

AxMapControl.DrawText is fast, but I can't figure out how to customize the text and background

MapTips look really cool but I can't find a function to plot a maptip with a point and text - I've only found layer.ShowTips = true;

I tried creating a balloon callout and activating my IElement like this (but it is really slow about 2 seconds for the popup to appear) :

pGraphicsContainer = activeView as IGraphicsContainer;
pGraphicsContainer.AddElement(pElement, 0);
pElement.Activate(activeView.ScreenDisplay);
activeView.PartialRefresh(esriViewDrawPhase.esriViewGraphics, pElement, null);

I also had a bad experience experimenting with dynamicdisplay.

Below I've left the original post in case anybody wants to read it:

What are the main steps to use to improve performance for an arcengine hosted in WPF with C#.  It's super slow.  I made a bunch of layer invisible which helped but its still no where near being snappy / usable.

Edit:

I load DataMaps10/streets_na/StreetMap North America.mxd and turn make the following layers invisible

CanadaBoundaries, CoastalWater, Parks, Airports, Landmarks, UrbanAreas, USBoundaries(World-25m), USBoundaries(25-1.5m), USBoundaries(1.5m-0), CanadaBoundaries, CanadaCoastlineandProvinces(World-25m), CanadaCoastline(25m-0), CanadaProvinces(25-1.5m),
CanadaProvinces(1.5m-0), Exits(Numbers)(15k-0)

I haven't tried switching to Winforms, I don't exactly know how to do that.

Edit 3:

SO the problem is DynamicDisplayEnabled = true ruins EVERYTHING!

so I turn it off... but now I want text that pops up when you hover over something... I was going to use dyanmic display for that, but dynamic display turns everything to crap !  I'm super frustrated.


texts: Get length of components of a multilinestring

texts:
I am looking to get not the length of the overall multilinestring but rather the length of the component parts. Here is what I have so far:

library(sf)

s1 <- rbind(c(0,3),c(0,4),c(1,5),c(2,5))
s2 <- rbind(c(0.2,3), c(0.2,4), c(1,4.8), c(2,4.8))
s3 <- rbind(c(0,4.4), c(0.6,5))
mls <- st_multilinestring(list(s1,s2,s3))

# calculate overall length
st_length(mls)

# split multilinestring into component linestring objects
mls_points <- st_cast(mls, "MULTIPOINT")
mls_split <- st_split(mls, mls_points)

plot(mls)
plot(mls_points, add = TRUE, col = "red")

# error on length of split output
st_length(mls_split)

  Error: inherits(x, "sfc_LINESTRING") || inherits(x, "sfc_MULTILINESTRING") is not TRUE

Maybe there is something I am supposed to be doing with st_cast?


texts: PostGIS Spatial Index not used after copying table

texts:
I am copying a PostGIS database from my computer to our webserver. I always had problems to copy the entire database using pg_dump and pg_restore so I am creating a new database on the server and copy the tables individually using

CREATE DATABASE mydb TEMPLATE = postgis_template;

and

pg_dump -U user -t mytab mydb > file.sql

and

psql -U user -d mydb -q -f "file.sql"

I am using this process for quiet some time now and never had any trouble. Now there is some trouble:

After copying the tables the spatial indices of the tables are not used any more. I tried to refresh and renew them. No success. Also I created a new database on my computer and copied the tables (so same OS same PostGIS version etc.). Same problem.

So when I look at the new database everything seems to be just like the old database but for some mysterious reason the spatial indices won't be used any more. So the same query on the same machine is not using the spatial indices any more...

The entire query is a bit long and confusing to post here but the spatial operator is "<->" to get polylines nearby. More or less as described here: http://boundlessgeo.com/2011/09/indexed-nearest-neighbour-search-in-postgis/
But as the same query is working totaly fine on the orignal database I assuming that the problem is the database (or the process of copying it) and not the query.

Is there any parameter I have to set in the database? Or is there a more convenient way to copy my database?

EDIT:

I found a workaround for my specific problem. My query is like the one from boundless (link above) just that I have added a WHERE clause using bitwise AND in the inner query. Like:

with index_query as (
  select
    st_distance(geom, 'SRID=3005;POINT(1011102 450541)') as distance,
    parcel_id, address
  from parcels
  WHERE (parcel_type & 3) = 3
  order by geom <#> 'SRID=3005;POINT(1011102 450541)' limit 100
)
select * from index_query order by distance limit 10;

When I place the where clause in the outer query like:

with index_query as (
      select
        st_distance(geom, 'SRID=3005;POINT(1011102 450541)') as distance,
        parcel_id, address
      from parcels
      order by geom <#> 'SRID=3005;POINT(1011102 450541)' limit 100
    )
 select * from index_query
   WHERE (parcel_type & 3) = 3
 order by distance limit 10;

the spatial index is beeing used again. Still that does not explain why the first query worked on the original database but not on it's copy. When I don't use a binary operation in the inner clause it also works fine...


texts: Openlayers4: cannot get layers from group layers

texts:
I am having super hard times trying to figure out how to get the layers of my ol.Map object. I have two group of layers (ol.layer.Group). One is called (property 'title') "Basemaps" and contains two basemap layers (ol.layer.Base) named "OSM" and "ESRI_WorldImagery"; the other group is named "Overlays" and has only one layer inside (named "umbe points").

I'd like to be able to check if "umbe points" layer of group "Overlays" is visible with the ".getVisible()" method. However, I can only go down to each of the two group of layer level, and not to the child layers each of them contains.

I've been trying (e.g.)

1)

var group = map.getLayerGroup(); // returns a layer group containing the layers in the map (which one ???)
var layers = group.getLayers(); // returns a collection of layers that are part of this group (which one ???)
layers.item(0).get('title'); // return "Basemaps" (argh...I hoped "OSM")

2)

var group = map.getLayerGroup();
var layers = group.getLayers();
var element = layers.item(0);
var name = element.get('title');
name; // return "Basemaps" (argh...I hoped "OSM")

My code looks like this (is mostly identical to the example from ol3-layerswitcher website):

var wmsSource = new ol.source.ImageWMS({
  url: 'http://localhost/cgi-bin/mapserver/mapserv.exe?map=C:\\Umberto\\webgis\\mapserver\\umbe\\mapfile\\test5.map',
  params: {
    'LAYERS': 'points_umbe',
    'CRS': 'EPSG:32632',
    'BBOX': '465789,4999869,553468,5055262',
    'WIDTH': '800',
    'HEIGHT': '500',
    'FORMAT': 'image/png'
  },
  projection: 'EPSG:32632',
  serverType: 'mapserver',
  imageExtent: imageExtent
});

var overlays_group = new ol.layer.Group({
  title: 'Overlays',
  layers: [
    new ol.layer.Image({
      title:'umbe points',
      visible: true,
      source: wmsSource
    })
  ]
});

var basemap_group = new ol.layer.Group({
  title: 'Basemaps',
  layers: [
    new ol.layer.Tile({
      title: 'OSM',
      type: 'base',
      visible: true,
      source: new ol.source.OSM()
    }),
    new ol.layer.Tile({
       title: 'ESRI_WorldImagery',
       type: 'base',
       visible: false,
       source: new ol.source.XYZ({
       url: 'http://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}',
       attributions: 'Tiles © Esri — Esri, DeLorme, NAVTEQ, TomTom, Intermap, iPC, USGS, FAO, NPS, NRCAN, GeoBase, Kadaster NL, Ordnance Survey, Esri Japan, METI, Esri China (Hong Kong), and the GIS User Community',
     })
   })
  ]
});

var layer_groups = [
  basemap_group,
  overlays_group
]

var map = new ol.Map({
  layers: layer_groups,
  target: 'map',
  overlays: [overlay],
  view: view
});


texts: ArcGIS model tries to tabulate the number of rows from multiple table intersections

texts:
I'm trying to generate a table that captures the number of rows, and the source feature class, from the intersection of several FCs against one common layer. My expected output is one row per intersection set containing the number of rows intersected and the source feature class for that intersection (technically there are two source feature classes for a given intersection set but the second FC is always the same). However my final table turns out empty and I don't understand what I'm doing wrong.

My model, as shown, iterates through FCs in a geodatabase and intersects them against a common layer for all FCs. I subsequently use Summary Statistics to get a count of rows, add a field to include the name of the FC selected from the geodatabase, and append this to a dummy table I've generated.

The process runs and creates a table with the right fields but the cells are empty.


texts: How can I get legend from Arcgis MapServer url

texts:
İs it possible to get legend item from arcgis mapserver or feature url. For example http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Specialty/ESRI_StateCityHighway_USA/MapServer

I can use legends if I use esri javascript api. But I am using openlayers or leaflet. So I have to get legend item of a layer.


texts:
I have a PostGIS table full of polygon geometries.

Some of these polygons are contained inside other polygons in the same table.

I need to find which polygons have parents and self-relate them to their parent. How do I go about this?

Can I use ST_Contains()?


texts:
I am building a suitability map in which I have different vector layers and raster data, I have converted all my vector layers into raster and I am using these two formulas to normalize the distribution and then standardize into a common scale from 1 to 0.
Theses are the formulas that I am using: Raster calculator in ArcGIS, (x - mean) / stdv --> ( x - min(x) ) / ( max(x) - min(x) )
I just want to check if this is a good approach to standardize my layers? or what is the best approach to normalizing different nature layers to then proceed with weighted overlay analysis?


texts: Has anyone used QGIS as an alternative to Terrasync or ArcGIS mobile?

texts: We are planning to purchase a rugged field computer (Trimble, Juniper, Ashtec etc.) for accurately surveying habitats and work sites in remote locations. In the past we have found that the software from ESRI or Trimble will cost nearly as much as the machine. We have occasionally used QGIS in the office on PCs that don't have a licence for our MapInfo GIS (with reasonable results), so I am wondering if anyone has tried using QGIS on any of these professional mobile mapping devices? I can see from online comments that there have been numerous issues with attempts to use QGIS use on tablets, mobiles etc so I am keen to know if there is a device that I can be confident it will work on.


texts: Accessing joined Image using ee.Join.saveFirst() in Google Earth Engine?

texts:
I am trying to append a band from a scene in one Landsat 8 image collection to a scene in another Landsat 8 image collection in Google Earth Engine. I am joining the scenes using ee.Join.saveFirst()

The join works and I am able to see the joined scene in the image properties, however, I am not able to access the band.

The resulting image collection behaves differently than a normal image collection.

If I try to map a function (even where input equals output) on the collection, the resulting image collection doesn't know it bands anymore. Applying a reducer doesn't work at all.

Has anyone experienced similar issues and knows a sollution?

Here my code:

function addMask(img){

  // grabbing the attached image
  var fmask_img = img.get('fmask');

  // Trying to access a band in the original image works
  //var b1 = img.select(["B1"]);

  // Trying to access a band in the image doesn't work
  //var fmask = fmask_img.select(["fmask"]);

  //trying to add a band from the attached image to the orignal image doesn't work
  //var newImg = img.addBands(fmask_img, ["fmask"])

  //trying to all bands from the attached image to the orignal image also doesn't work
  //var newImg = img.addBands(fmask_img, ["fmask"])

  //even trying to the origianl image to is self doesn't work
  //var newImg = img.addBands(img)

  return img // returning the unchanged image instead of newImg
}

// Load a primary collection: Landsat imagery.
var primary = ee.ImageCollection('LC8_L1T')
    .filterDate('2014-04-01', '2014-06-01')
    .filterBounds(ee.Geometry.Point(-122.092, 37.42));

// Load a secondary collection: MODIS imagery.
var secondary = ee.ImageCollection('LANDSAT/LC8_L1T_TOA_FMASK')
    .filterDate('2014-04-01', '2014-06-01')
    .filterBounds(ee.Geometry.Point(-122.092, 37.42));

// Create a filter to define a match based on the scene ID.
var sceneFilter = ee.Filter.equals({
  leftField: "LANDSAT_SCENE_ID",
  rightField: "LANDSAT_SCENE_ID"
  })

// Define the join.
var saveFirstJoin = ee.Join.saveFirst({
  matchKey: 'fmask',
  ordering: 'system:time_start',
  ascending: true
});

// Apply the join.
// This returns an image collection
var landsatFmask = saveFirstJoin.apply(primary, secondary, sceneFilter);

// Mapping a simple function where input = output returns an image collection
var fmask = landsatFmask.map(addMask);

// applying a reducer on the orignal collection works
var primary_median = primary.median()

//applying a reducer on the orignalnew collection works doesn't work
//var fmask_median = fmask.median()
//var joined_median = landsatFmask.median()

// Display the result.
// the orginal collection
print('raw:', primary)
// looks the same as the orginal, only difference is that images inside the collection have an additional property "fmask" with the joined image inside
print('Join.saveAll:', landsatFmask);
// looks the same as the joined collection, but now the band list of the images collection is empty ??
print('fmask:', fmask);


texts:
I have two Geotiff files. with one side overlapping. Each Geotiff is surrounded by a black frame.

I have created an Image Pyramid with Geoserver 2.3.0 but when I try to see the layer on OpenLayers, the layer borders appear in black, so I can't see correctly the layer, because of thats black borders.It looks like tiles in the pyramid already has black zones inherited from the original tiffs.

I've followed these steps:

First I have execute the next command on tiles to convert to Image Pyramid:

gdal_translate -a_nodata 0 <origin.tif> <target.tif>

When I have executede this command, I executed the next one:

 gdal_retile.py -levels 3 -ps 2048 2048 -co "TILED=YES" -co "BLOCKXSIZE=256" -co "TILED=YES" -co "BLOCKXSIZE=256" -co "BLOCKYSIZE=256" -targetDir tiles --optfile tiles.txt -s_srs EPSG:32719 -targetDir tiles --optfile tiles.txt

After that I try to make the Image Pyramid with Geoserver, but the result is the same that at first, I preview the layer on Openlayers and it appears with black borders.

I think Image Pyramid plugin is properly configured:

InputTransparentColor: #000000
OutputTransparentColor: #000000
SUGGESTED_TILE_SIZE: 512,512
USE_JAI_IMAGEREAD: true

I don't know what I must to do.

Any help, please???


texts: Does the validity of a shapefile depend on the projection?

texts:
I am working with shapefiles for UK police force boundaries published by the police, defined in WGS84. Some of the boundary shapefiles are invalid (due to self-intersections of the boundary). When I reproject the shapefiles to the British National Grid (OSGB 1936), they are valid.

I would like to understand why this is the case. Is this simply a case of the police using projected shapefiles and uploading WGS84 shapefiles without checking for validity? In other words, is this simply an artefact of reprojecting? Or does it indicate that the original projection definition of the shapefiles is not correct?

R code to reproduce this problem is below:
The force boundaries can be downloaded here: https://data.police.uk/data/boundaries/force_kmls.zip

The invalid shapefiles are "derbyshire.kml" and "greater-manchester.kml".

library(rgeos)
library(rgdal)

# read in shapefile
derby <- readOGR("../force_kmls/derbyshire.kml")
# show object
summary(derby)
Object of class SpatialPolygonsDataFrame
Coordinates:
    min       max
x -2.034083 -1.166476
y 52.696521 53.540456
Is projected: FALSE
proj4string :
[+proj=longlat +datum=WGS84 +no_defs +ellps=WGS84 +towgs84=0,0,0]
Data attributes:
Name Description
:1   :1

# check for validity of polygon
rgeos::gIsValid(derby)
[1] FALSE
Warning message:
In RGEOSUnaryPredFunc(spgeom, byid, "rgeos_isvalid") :
Self-intersection at or near point -1.31360199 53.164194000000002

# reproject derby
derby_proj <- spTransform(derby, CRS("+init=epsg:27700"))
summary(derby_proj)

Object of class SpatialPolygonsDataFrame
Coordinates:
   min      max
x 397829.5 455677.1
y 311055.2 404875.1
Is projected: TRUE
proj4string :
[+init=epsg:27700 +proj=tmerc +lat_0=49 +lon_0=-2 +k=0.9996012717 +x_0=400000 +y_0=-100000 +datum=OSGB36 +units=m +no_defs +ellps=airy +towgs84=446.448,-125.157,542.060,0.1502,0.2470,0.8421,-20.4894]
Data attributes:
Name Description
:1   :1

# check for validity of polygon
rgeos::gIsValid(derby_proj)
[1] TRUE


texts: Splitting polygons in OpenLayers is not working

texts:
I have some WFS layers in OpenLayers, containing Polygons. I try to make a tool to split these polygnos and save them to db.

//The layer which I want spliting work on
var contract_layer = map.getLayersByName("contracts");
//The spliting control
var split_control = new OpenLayers.Control.Split({
       layer: contract_layer,
       listeners: {
           'beforesplit' : function(){
               alert("before");
           }
       }
});

and then I add this control to my map and make it active:

toolbarItems.push(new GeoExt.Action({
       control: split_control,
       map: map,
       toggleGroup: 'map'
   }));

   map.addControl(split_control);
   split_control.activate();

And now when I chose the tool, I can draw a line which ends with double-click, but that's it. nothing else.Nothing splits and nothing is sent to geoserver.
What do you think I'm missing?


texts: Show feature classes as a checklist in a workspace in ModelBuilder

texts:
In my model, I would like to show all the feature classes inside a file gdb as a "checklist", similar to how the tool dialog window for Make Query Table looks:

So instead of the input being a table, and the field names are populated below so the user can select which fields are needed, I would like the input to be a file gdb and the feature classes inside it are populated in the window, so only the required feature classes can be selected. Is this possible inside modelbuilder via a tool or some Python code (maybe ListFeatureClasses but it must display the output)?

It would also be helpful to know what that type of window is called. I know the top section is the Multiple Value window, so what would the "checklist" window be called?


texts: ArcSDE - Creating new install on new database with existing SDE schema

texts:
I asked a question before, but was probably not specific enough, so didn't get the information I required. My fault completely.

I am creating a new sde instance on a server.  This needs to be pointed at an existing Oracle 11g database, that has a pre exisiting SDE schema and data in it.

Now all the installs I have seen, have created all of the system tables, but this one doesn't need to, as they are there. Also, which is more alarming, is that I cannot perform an upgrade, as it hasn't been installed before.

Not too sure how to take it from here.  I don't normally work with SDE, buit have thoroughly researched the issue.  Has anyone seen this issue, or have advice as regards the issue?

Thanks in advance.

EDIT
This is my plan of action.

Dump file of Oracle non spatial data
Install SDE
Create new Schema
export SDE data from old DB (sdeexport)
import SDE data from sdeexport file

We'll see how that fares, but it appears the only way to me.


texts: Republishing an existing map service with the same name without stopping the old one?

texts:
Please, consider the following scenario:

The following mosaic dataset contains 3 images in it, it was published as a service and cashed, and it works fine and many organizations read from my server.

I need to add 2 more images to the same mosaic dataset, so the shape of the new  published service will be similar to the screenshot below.

Now my question is what is the best practice to update the old published service such that the new one reflects the change in the mosaic dataset and shows the 5 images?

Note that I want to publish it with the same name in order not to interrupt the other organizations “not to change the link to this service in their web mapping applications”.


texts: Colorizing polygons based on color values in dataframe column?

texts:
I preparing some choropleth election result maps in Geopandas. The assigned color for each electoral district must correspond with the winning party (a color that I pre-determine), and the intensity of the color (opacity, saturation, etc) must be adjusted based some variable such as the margin of victory. Basically your traditional post-election map job.

My GeoDataFrame is structured as such (note there are three or more parties):

district_no   winning_party  color    margin  geom
0             Conservative   #C62828  .56     POLYGON(599240.6488817427....)
1             Conservative   #C62828  .78     POLYGON(589240.6488427823....)
2             Liberal        #283593  .34     POLYGON(563405.6788424563....)
3             Conservative   #C62828  .08     POLYGON(563405.6488424563....)
4             Labour         #FF9800  .22     POLYGON(583405.6918424563....)
5             Labour         #FF9800  .37     POLYGON(633405.6128424563....)
6             Liberal        #283593  .48     POLYGON(533405.6278424563....)
etc...        etc...         etc...   etc...   etc...

I have not been able to figure out how to achieve this with the .plot() method. The argument 'color' simply applies the inputted color to all rows, and I am unsure how using cmap would help me achieve this, especially given that I must also adapt the color intensity based the margin column.

The only solution I can conceive is to loop through each row in the GeoDataFrame, and one by one plot out each polygon by assigning the color column value to the color argument, and then use the margin value to adjust the alpha level. Then somehow, I would have to merge/append all the plots back together to rebuild a final map (I'm not even sure this is possible).

Surely there is a better way than this. I have scoured the Internet, but surprisingly, I cannot find any solutions for this multi-party choropleth maps. Any ideas?.


texts: Hot spot analysis indicated the areas with 0 value as hot spot?

texts:
I tried to look at whether there is cluster of psychiatric patients in a county. I have census tract data with a column showing how many psychiatric patients are there in a census tract. There are many  (more than a half) census tracts without any psychiatric patients.

I used both fixed distance band and spatial weights matrix to do the hot spot analysis. When used fixed distance band, I used spatial auto correlation to generate the distance, and I chose the max peak, (because the when first peak occured, some features had no neighbor). Both fixed distance band and spatial weights matrix methods yielded the similar result (tracts with 0 value were marked as hot spots).

When examine the result, I found that many polygons marked as hot spot were actually with 0 value, which should have been cold spots. I understand that hotpost analysis calculates the values within a certain defined areas instead of the original polygons, but still don't totally understand the result and how to explain it.


texts: Number of point locations inside a shape?

texts:
I am pretty green with GIS, however:

I have two data sets:

a shapefile defining various exclusive populated areas.
a text file defining the location of all telecommunications sites in a site

I would like to determine what area a particular site is in.

I am using the Desktop version of QGIS 2.18.1

I already had the XY location data imported.  However your solution gave me half the result I was looking for.  I also used Difference tool to detail the sites not covered by a polygon.


texts:
I have a layer with a customized form. Dropdowns, checkboxes, etc. in a QGIS project which is kind of a template. This QGIS project will be copied and pasted every time a new study has to be done (usually twice a week).

The problem is that I want the layer to be empty for each project at the beginning, so that users can insert the data for the new study. The data once saved, should be visible only in that specific project. So all the projects will use the same layer, but each QGIS project will only see in that layer the data introduced in that specific project.

I thought of making a new field in the layer named "project name" and in layer's filter option add the following filter:

"project name"= @project_filename

@project_filename is a project variable which stores the name of the project but in layer's filter I can't use project variables...

Is there any way to achieve what I have explained?


texts: Convert a raster to a polygon with gdal in command line

texts:
I want to convert a raster (agric.tif) to a polygon layer (agric.shp). I want to use gdal in command line since the QGIS (raster to polygon) seems to takes for ever (still running over an hour).

I am trying to use gdal_polygonize.py . Is this working in command line? I get en error "the command not found".

gdal_polygonize.py $outdir/"agric.tif" -f "ESRI Shapefile" agric.shp


texts: How to map all 0.001° graticules that contain land?

texts:
I'm trying to map all 0.001° graticules (across the planet) that contain land.

My first attempt naively tried to brute force this by literally looping over the entire planet in 0.001° increments and checking if each point contained land or not. Should've done the math first -- not optimal :(.

My second attempt tried narrow down the scope by first finding the bounding boxes for known land areas and then doing the same "loop and check" technique over that. I used the "land polygons" from NaturalEarth, however, the bounding boxes I was able to generate from those polygons weren't granular enough.

I'm thinking next I'll try to find a larger set (of smaller polygons) so the bounding boxes are more "accurate"... maybe countries instead of land masses?

Either case, I'm sure this approach will eventually work, but, I'm thinking there's gotta be something better/more optimal. (Also, it should probably be noted that I'm incredibly new to GIS related things :).

Thoughts? Is there a way to do this via a query inside of PostGIS (which is what I'm currently using to store the data)? Or is there a better alternative?

Thanks, and let me know if you need any extra clarification.


texts: Rendering error ArcGIS javascript API IE8

texts:
I have an issue when displaying features on a map in ArcGIS Javascript API V. 2.8. I want to know if this behavior is seen before, and what could cause it.

In Internet Explorer 8 the map looks like this:

In Internet Explorer 9 and Chrome and any other browser I have tested, the map looks like this:

The red color we see is the color of the outline of the polygons.

Below is a part of the code for drawing the polygons. As the application is quite complex, as will avoid posting the whole application here. Unfortunately I am not able to provide a direct link to the page, as it is not released yet.

var symbol = new esri.symbol.SimpleFillSymbol(
    esri.symbol.SimpleFillSymbol.STYLE_SOLID,
    new esri.symbol.SimpleLineSymbol(esri.symbol.SimpleLineSymbol.STYLE_DASHDOT,
        new dojo.Color([100, 0, 0, 0.5]), new dojo.Color([100, 100, 100]))
)

...

dojo.forEach(features, function (feature) {
    var graphic = new esri.Graphic(feature.geometry, symbol);
    graphic.attributes = feature.attributes;
    map.graphics.add(graphic);
});

The flow in the program is basicly this:

Page is loaded
Map is initialized
Polygons are loaded with query task
Polygons are drawn on map
Event handlers are attached ...


texts:
I want to make a simple outline map on QGIS with basic city names. I downloaded the map from Nature maps but the city names keep appearing in greek, even though I changed the locale and application language.

What should I do to make the names appear in english?


texts: Different behaviour between imported and harvested records in GeoNetwork 3.4.0

texts:
I'm working on Geonetwork 3.4.0 and I have some metadata files generated with ArcGIS 10.5.

The XML files are stored into a folder that I would like to harvest, but when harvesting, it says "badFormat" and doesn't load anything.

If I import manually through "Import new records", the records are imported without issues.

I tried it with 3.4.0 and 3.4.1 versions. Please find below a link to an example record.

Is that the expected behaviour or a bug?

Please note I asked the same question on the GeoNetwork users mailing list (and just had the idea to put here today).

[1] https://gist.github.com/Bakaniko/db59ed33012313121eaf81c0e7d9ac76


texts:
This is confusing, and a question I've harvested from a duplicate, so let me start with my setup.

OS: Windows 7 x64
GIS Client 1: ArcGIS Desktop 10.5
GIS Client 2: ArcGIS Pro 1.4
GIS Client 3: Boundless Desktop 1.0 (QGIS 2.14)

Background

Many of the scripts I write, I try to keep open-source for those without a fancy ArcGIS license.  However, I can't set PyQGIS as my default system interpreter in my environment variables because it will break many of the tools in ArcMap.  So I have taken the approach of making ArcGIS's Python instance the system Python, and installing open-source libraries there (and using .pth files to pull in qgis.core functionality if I need it).  I am using Gohlke's precompiled GDAL wheel (32-bit) in this case.  I am operating under the assumption that this breaks the fewest amount of things.

Problem

I have multiple installs of GDAL, and the system seems to keep defaulting to one of them, ignoring any environment variables I set.

C:\Program Files\GDAL contains version 2.1.0 (64-bit).

C:\Python27\ArcGIS10.5\Lib\site-packages\osgeo contains version 2.1.3 (32-bit).

C:\Program Files\GDAL appears nowhere in my user environment variables.

Instead, I have the variables:

GDAL_DATA pointing to C:\Python27\ArcGIS10.5\Lib\site-packages\osgeo\data\gdal

and a variable called

GDAL_DRIVER_PATH pointing to C:\Python27\ArcGIS10.5\Lib\site-packages\osgeo.

C:\Python27\ArcGIS10.5\Lib\site-packages\osgeo is in my PATH.

Yet, when I open a command prompt and type ogrinfo --version it does not give me 2.1.3 (the version in PATH) but rather 2.1.0 (the 64-bit version in \Program Files\GDAL, which is nowhere in PATH).

What gives?

Answers that do not answer my question

How to force QGIS to use GDAL version?

Unable to call GDAL functionalities from Python

How to add support for FileGDB (Esri file gdb API) driver in fiona?

GDAL version in QGIS

Does Gohlke GDAL break Command-Line GDAL/OGR in Windoiws?


texts: PostGIS database design: For polygon data

texts:
I am designing a spatial database using PostGIS. My main aim of this spatial database is to organize Administrative (250 polygon layer) and postal layers (154 layers) in a database. These layers covers different countries of the world. Each country has difference administrative/ postal code levels. At last this model should provide a way to update these layers using QGIS.

I have studied difference techniques of organizing spatial data in postgis. Till now inheritance model (PostGIS in Action/chapter 3) impress me but I am not sure how to implement it.

Can inheritance used for geometrical inheritance as well? Like Administrative level 01 is always subset of Administrative level 02 means from the geometry of Administrative level 02 we can extract the geometry of Administrative level 01 using dissolve.

If we update any geometry in Administrative level 02 then geometry of Administrative level 01 should be automatically updated. How can I achieve this?


texts: Iteration through shapefile rows is taking too long

texts:
I'am using a shapefile with leaflet in r, where i am iterating through each row of that shapefile with a for loop and then i run an if statement on each of the rows as it iterates through the shapefile. My problem is that when I run it, it takes ages to iterate through and show the results. Is there any way to speed up my code?

R code:

# loop through each row of shapefile and run if statement on each row.
for(i in 1:nrow(shapeData)) {
  if(shapeData@data[i,]$TOTAL2011 > 400){

    m <- addPolygons(m, data=shapeData[i,],weight=1, popup = map_popup2, fillOpacity = 0.5,
                     color = "yellow") %>%
    print(m)

 }
}


texts: Return nodes along portions of edges with pgrouting

texts:
I have been experimenting with generating isochrones with pgrouting using osm data. So far, I have been able to generate isochrone polygons by getting the concave hull of the nodes returned from the pgr_drivingdistance function. Here is a sample query to generate 10 minute (0.166667 hr) isochrone from node 46397, assuming a speed of 5km/h :

SELECT 1 AS id, st_concavehull(st_union(t.the_geom), 0.95)
FROM
(SELECT seq, id1 AS node, id2 AS edge, cost, pt.the_geom AS the_geom
  FROM pgr_drivingdistance(
    'SELECT id, source, target, (km/5) as cost FROM at_2po_4pgr',
    46397, 0.166667, FALSE, FALSE
  ) AS di
  JOIN at_2po_4pgr_vertices_pgr pt
  ON di.id1 = pt.id) t

Which yields the following isochrone :

I would like to know if it is possible to calculate an isochrone
while considering the possibility of reaching points along a portion of each edge? This would be especially useful in cases where network edges are very long. For example, the pgr_drivingdistance function would return a point 50% along an edge, if only half of the edge could be traversed.


texts: How can I use wms service layers to edit in openlayers?

texts:
I'm new to openlayers. I'd like to edit a feature layer of wms service in openlayers.

I created a wms service using ArcGIS server 10. I couldn't use the wms layers to edit using the openlayers editor. Is there any solution to set layers of the wms service (ex: layer 1 of wms service) to edit in openlayers? In other words, how can I set the wms layer to OpenLayers.Control.EditingToolbar()?

<!DOCTYPE html>

    <title>Creating a simple map</title>
    <meta http-equiv="Content-Type"
          content="text/html; charset=UTF-8">


texts: How to get Lat/Lng from a Geometric property?

texts:
Alright, I am very new to GIS, my question might not even make sense, but help me get through this.

I have this JSON data of some fields which have this geometry property:

"geometry": {"type":"Polygon","coordinates":[[[-9808308.55,4693529],[-9808325.985,4693527.669],[-9808334.548,4693526.964],[-9808333.404,4693527.538],[-9808328.685,4693530.385],[-9808326.444,4693532.015],[-9808322.29,4693535.601],[-9808318.672,4693539.547],[-9808315.572,4693543.916],[-9808313.091,4693548.874],[-9808311.481,4693554.29],[-9808310.817,4693559.639],[-9808310.73,4693566.446],[-9808307.432,4693534.353],[-9808308.55,4693529]]]},

So these co-ordinates are, obviously, not Lat-Lng's of the field co-ordinates which is what I want when I have to project them on Google Maps. How should I go about this? Can we get Lat/Lng of these co-ordinates without knowing which the transformation formula which had been applied on it? (I even don't know these field co-ordinates belong to which region!)


texts: how to extract line features from a raster

texts:
I have a raster of land cover types where roads are represented by pixels (1 pixel = 25m x 25m = 625 m²). Is there a way to extract line features (here roads) from a raster ?

## Create raster as an example:
library(raster)
library(rgeos)
r <- raster(ncols=90, nrows=50)
values(r) <- sample(1:10, ncell(r), replace=TRUE)

## Road raster
r[r[] < 10] <- 0
r[r[] >= 10] <- 1
plot(r)


texts:
I'm having an issue in setting the buffer in geopandas. Right now I am trying to set an 805m buffer (roughly 1/2 mile) buffer around an airport.
airporturl = 'https://opendata.arcgis.com/datasets/1082ad016bc2457ca18451ecc49d1a75_0.geojson'
airport = gp.read_file(airporturl)
airport = airport[airport['COUNTY'] == 'Placer']
airport = airport.to_crs(epsg=4326)
airbuffers['geometry'] = airport.geometry.buffer(805)

I get the following warning:

:1: UserWarning: Geometry is in a geographic CRS. Results from 'buffer' are likely incorrect. Use 'GeoSeries.to_crs()' to re-project geometries to a projected CRS before this operation.

and additionally, my buffer is a complete mess (I believe it is in decimal degrees but I'm not entirely sure). What I am doing wrong?


texts:
I have a question regarding ArcMap. Lets say I have a .shp with watersheds and a .shp with drainage lines. How can I combine both, so that I can display single watersheds and the length of their inner streams. Just like in the nice picture below.

I want to access the length of the stream segments inside each catchment. I have tried several clipping methods but have still no useful results.

Thanks for the help!


texts: Intersection of multiple layers in PostGIS

texts:
I need to write PL/pgSQL stored procedure for calculation of intersection of multiple layers. For example, for three layers A, B, C this function should return ABC geometry:

Function takes as input the id of layers which need to be intersected. Can anyone give me advice for building this function? My thoughts about this I need to intersect first layer and second then result of this intersection intersect with third layer etc.


texts: Create Published Parameter as a Transformer Output

texts:
Using FME 2017 Desktop with ArcGIS 10.2.1 & Oracle 12c.
I am filtering features using a WHERE clause which has a LAST_RUN_DATE being read from a control table.
I am using a SDE reader to get the LAST_RUN_DATE which feeds into another transformer but in some scenarios, like using SQLCreator where there is no input port, it cannot be used unless published as a parameter or hard-coded.
I have now created a published parameter which I am populating before every run - manually.
My question is - can the output of my reader be creating or populating a Published Parameter?


texts: creating a pyramide tiles of a geotiff using gdal

texts:
I have a big geotiff file (about 300MB), and I saw an example of a big data organized in folders :

folder 0 contains one folder 0 which contains one .png file named 0.png

folder 1 contains two folders 0 and 1 and each one contain two pictures 0.png and 1.png

folder 2 contains four folders 0, 1, 2 and 3 each one contains four pictures ...

and I want to devide my geotiff like above. and I know that by usinggdal we can do it but I don't know how?

I tried this but it does not give a result

gdaladdo -r average abc.tif 2 4 8 16


texts: QGIS2WEB Plugin (openLayer3) for QGIS not exporting raster images

texts:
I am using the QGIS2WEB plugin for QGIS. I have added vector features as well as a raster image (.tif or .ecw) format.

When I try to export the webmap, all the layers are visible expect the rasters. Why is this?


texts: I have a punctual shapefile of wind turbines. The task is to discover if those wind turbines are visible to the human eye. The human eye can see a maximum of 1.6 meters. Which tool can create or add new points near to the wind turbines in a radius of 5 km and then apply the viewshed analysis.


texts: Geocoding Street Segments Based on Extents in ArcGIS for Desktop?

texts:
I have a list of projects that need to be geocoded or drawn through some sort of automated process in ArcGIS 10.3 for Desktop. The are listed by primary street, a begin street intersection, and an end street intersection. The data files are in the format listed below.

    Street                Extent 1          Extent 2
    N Spring St           W Temple St       W Arcadia St
    Aviation Boulevard    93rd Street       Century Boulevard
    Le Conte Ave          Hillgard Ave      Levering Ave
    Pershing Drive        Westchester Pkwy  Imperial Highway

I am using a street centerline file that includes each street segment name, a unique ID for each segment, and the begin/end intersections for each segment. The streets observe consistent directionality. I also have available to me a separate intersection shapefile that contains the intersections, with their unique IDs, but I have been unable to figure out how to integrate them correctly into a street centerline shapefile that can be used to create an address locator or linear reference system.

These are the centerline files I am using; they are publicly available from the City of Los Angeles.

I am not trying to map addresses, but to create line segments that begin at Street/Extent 1, and then trace along the polyline specified by Street until it reaches Street/Extent 2.

Here is an example of the line type I am trying to create, using the first example in the codeblock above:

The line segment would begin at W Temple St/N Spring St, and then continue along N Spring St until the intersection of W Arcadia St/N Spring St.

I have tried using a linear reference system, but the begin/end fields for the event table have to be numeric, rather than string values. Address locators will only create points for me, but could I create start/end points, and then tell ArcMap to trace along Street 1 between the start end points? I have been unable to figure out a workaround for this so far...

I have limited Python experience (and my workplace has almost none) but am open to a solution that would include it. This would have to be a process that could be integrated into a workflow, and taught to other people/updated regularly. Ideally, this would be integrated into an address locator, but I could also provide the workflow as a Modelbuilder object as well.


texts: QGIS refFunctions override maximum amount of features

texts:
A have a polygongrid on a 1x1m spacing.
I have multiple XYZ files also on a 1x1 grid.

I would like to write the Z-value of the xyz-files (is in geometry and in the DB) to the polygongrid if the XY of the pointgrid is within the perimeter of the polygon (in the polygon layer).

On small files i use refFunctions "geomwithin" to do this.

Geomwithin is limited to 100k records, and I have files that easily have more records (points).

Is there a way to override the 100k limit on refFunctions? Or is there a different way to approach this problem?


texts: Can't install PostGIS extension to PostgreSQL

texts:
I just installed a fresh new install of PostgreSQL-10.5-1-win64-bigsql

Once installed I wanted to add the PostGIS extension ran: CREATE EXTENSION postgis;
Got error message could not find C:\PostgreSQL\pg10\share\postgresql\extension\postgis.control

I found the file at this location C:\PostgreSQL\pg10\share\extension\

So I thought I could just copy the postgis.control into the directory where it was being looked for and ran the create extension and got this: ERROR:  extension "postgis" has no installation script nor update path for version "2.4.4"


texts:
I would like to use RasterLite data in a Cordova-based App but don't know the right tools to achieve this.

The [Geopaparazzi Project] uses SpatiaLite files generated with the rasterlite2 library to display a background map.

From what I understand this raster data storage technology is less performant
in comparison to MBTiles since they do not contain prerendered tiles for every zoom level (in a mapping library like OpenLayers) but instead use (physical or virtual) pyramids to render data for smaller zoom level which makes it storage efficient. Bigger mosaics can be tiled for smaller zoomlevels and still be utilized in a mobile app.

The Geopaparazzi app mentioned above is Android-based. I would now like to use RasterLite data a in webbased, mobile (hybrid) app to display a basemap for a larger area. While plugins for OpenLayers or Leaflet exist for MBTiles, there seems to be no plugin for RasterLite.

How can this be done sing existing components like Chris Brody's cordova-sqlite-ext or the JavaScript port of SpatiaLite?


texts:
I'm trying to create my first tool, where will be possible to insert multivaule into process. I need to insert these values to "where clause" but in my code it inserts only one value. Here is my simple code:

import arcpy
stands = arcpy.GetParameterAsText(0)
protecAreas = arcpy.GetParameterAsText(1)
protecAreasList = protecAreas.split(";")
arcpy.MakeFeatureLayer_management(stands,'standmap', """ [ARTYPE] IN ('{}')""".format("','".join(protecAreasList)))

Can someone advise me where could be a problem ? Attribute ARTYPE has String data type. In parameter properties, MultiValue is set to Yes and Filter has Value List where I added several string values.


texts: How to make a single raster which shows the year since the last fire

texts:
I am using ArcGIS 10.2.2 to make a single raster which shows the year since the last fire in an area based on the MODIS Maryland University raster layers.

I have 15 raster layers all from a different year (2000-20015).
Currently each burn is classified as 1 for burnt and 0 for unburnt within each layer.

Firstly, I though I could reclassify each layer by its year (2000-2015).
Then, using a tool, perhaps using raster calculator, to take the most recent fire pixel and make that into a raster with 16 cats (one for each year and for burnt areas)? Does anybody know a simple why to do this?


texts: arcpy - how to run geoprocessing python script on SDE

texts:
I was testing my script on a .gdb on my local drive and I got it to work. The actual geodatabase I would like to run the script on is an SDE. I tried changing my filepath from the .gdb to the .sde and it failed. Can someone help me figure out how to configure my script so that it will work on the SDE?

#import system module
import arcpy, os

#define filepath
filepath = r"C:\Users\kkaszas\AppData\Roaming\ESRI\Desktop10.0\ArcCatalog\SANGeodatabase.sde"

arcpy.env.workspace = filepath

#enable overwrite
arcpy.env.overwriteOutput = True

fcList = arcpy.ListFeatureClasses()
fieldName1 = "Author"
fieldName2 = "LastUpdated"
expression1 = "\"John Doe\""
expression2 = 20121011

for fc in fcList:

    arcpy.AddField_management(fc,fieldName1, "TEXT")
    arcpy.AddField_management(fc,fieldName2, "LONG")
    print "fields added to " + fc

    arcpy.CalculateField_management(fc, fieldName1, expression1, "PYTHON")
    arcpy.CalculateField_management(fc, fieldName2, expression2,"PYTHON")
    print "Fields have been calculated for " + fc


texts: ArcObjects Background Process (Thread) Progress Bar?

texts:
Using a toolbar, written in ArcObjects, it is possible to push processing to a separate thread so that the GUI does not lock.

Is it possible to have the thread update a progress bar in the same position (lower right - arcmap) that a geoprocessing tool does?

I must be missing some obvious documentation to gain access to that progress bar update location.


texts: Conditional formatting for Advanced Label Expression in ArcMap

texts:
I am trying to do some conditional formatting in order to highlight specific criteria. The main error I keep getting is that there are no features found. I've done a simple label with the exact same parameters that works fine. I've also occasionally gotten an error that says the function FindLabel is not defined. Thinking now, I might need a nested if statement. I have 4 parameters, [Percentage_Complete], that if they exceed the criteria of 90, then I want to change the color to green. If it doesn't it will stay black. So 1 to 4 of them could be green, or they are all black text.

def FindLabel ([SWSID], [Stn_Name], [First_Date_In_DB], [Last_Date_In_DB], [Percentage_Complete], [First_Date_In_DB1], [Last_Date_In_DB_1], [Percentage_Complete1], [First_Date_In_DB2], [Last_Date_In_DB_2], [Percentage_Complete2], [First_Date_In_DB3], [Last_Date_In_DB_3], [Percentage_Complete3]):

lab1 = "T_avg" + "  " + [First_Date_In_DB]+ "  " + [Last_Date_In_DB] + "  " + [Percentage_Complete]+"\n"
lab2 = "Snowfall"+ "  " + [First_Date_In_DB1]+ "  " + [Last_Date_In_DB1] + "  " + [Percentage_Complete1]+"\n"
lab3 = "Snow Depth"+ "  " + [First_Date_In_DB2]+ "  " + [Last_Date_In_DB2] + "  " + [Percentage_Complete2]+"\n"
lab4 = "Rain"+ "  " + [First_Date_In_DB3]+ "  " + [Last_Date_In_DB3] + "  " + [Percentage_Complete3]"\n"
higlight =  "<bol><clr green='255'>"
endhigh = "</bol></clr><\n>"

if int([Percentage_Complete]) >= 90:
lab1 =  highlight + lab1 + endhigh
if int([Percentage_Complete1]) >= 90:
lab2 =  highlight + lab2 + endhigh
if int([Percentage_Complete2]) >= 90:
lab3 =  highlight + lab3 + endhigh
if int([Percentage_Complete3]) >= 90:
lab4 =  highlight + lab4 + endhigh

label = "<und><bol>"+[SWSID]+"</bol></und>"+ "    "+ "<und><bol>"+[Stn_Name]+"</bol></und>\n" + lab1 + lab2 + lab3 + lab4

return label


texts: Zoom to a selected feature with Openlayers 2

texts:
var cen = new OpenLayers.LonLat(lng,lat)
.transform(proj, map.getProjectionObject()); map.setCenter(cen,30);

I need to zoom into the feature selected.


texts: ArcMap, QGIS 3.10.7, QGIS 2.12.3 all interpret ASCII file values differently

texts:
I have QGIS 3.10.7 and QGIS 2.12.3. I am loading the same ASCII (.asc) file into both versions of QGIS. QGIS 3.10.7 says the values in the ASCII file range from 186.573 - 1458.33. QGIS 2.12.3 says the values range from 267.966 - 1142.93.
ArcMap says the range is 549.979 - 1462.79.
Do different programs interpret ASCII files differently? If I were to use SAGA tools to calculate something like slope/aspect/topographic position index using the different programs, I assume the results would be different in absolute terms, but would they be the same/similar in relative terms?


texts: Extract by mask/copy raster a RGBA (4bands) raster results in a greyscale image in photoshop discarding all RGB composite info

texts:
I used a polygon Shapefile to extract by mask (ArcGIS) the sea area from a RGBA (4 bands aerophoto) raster. The Extract by Mask caused up-sampling from 16 bit (my raster's initial pixel depth) to 32 bit so I used "copy raster" to down sample the raster to 16 bit and entered the "0" value for nodata.

The problem is that when I open the new raster in photoshop the band composition is lost and the RGBA raster opens as a grey scale raster in photoshop. Do you have any idea why this is happening?

I used composite bands operation and made a new composition but nothing changed. Is it possible photoshop is not working with nodata values?


texts:
Here are the steps i did:

Added ppa to repository sources
in synaptic marked all pgrouting for postgres 8.4
apply (everything was ok)
restarted postgres

But, i just tried a simple function shortest_path and it seems to do not recognise it:

  ERROR:  function shortest_path(text, integer, integer, boolean, boolean) does not exist
  LINE 1: SELECT * FROM shortest_path('

This is the query:

  SELECT * FROM shortest_path('SELECT
  gid as id,source::integer as
  source,target::integer as
  target,length::double precision as
  cost FROM topologia'::text,1, 2,
  false, false);

Is there anything else that I'm missing?


texts: Embedding Mapbox map into wordpress web page?

texts:
I want to embed a mapbox map into my wordpress web page.

I did the map with tilemill and saved into mapbox but I don't know how I would embed the map in wordpress.


texts: How does what3words build a grid of squares on the surface of the Earth?

texts:
What3words built a grid of squares of 3m2 on the earth. Does anyone know what is the algorithm ?

I started with this method: the range of longitude is [-180, 180] and the range of latitude is [-90,90]. If you cut them into equal intervals, you can have almost perfect squares near equator, but near the poles, they arenot squares, are they ?

After Gary's answer. I still want some precisions.

If between -85° and 85° (latitudes), the squares are in a grid, do I have to assume that the number of squares at a any latitude is the same (for me, when I say a grid, for each side of the square, there should be one and only one square)? If so, at the equator, we can have a square of 3mx3m, but at latitude 85°, it is a 0.26m x 0.26m then. (Because the parallel at latitude 85° is cos(85°) shorter.)

So, do I have to assume that it is not a perfect grid , since the area of the square always 3m x 3m at any latitude between -85° and 85°. But when I tried to zoom into a what3word map, I always see a perfect grid. How is it possible? Is it possible to see some deformations, directly on a map ?

@Gary, is it possible to see the deformations (near the poles) you mentionned in a map ? (it seems that we can't see on a google map).


texts:
I want to calculate the height of an object based on nearest ground surface. I have GPS coordinates and GPS elevation(which I assume is ellipsoid height) as an input in WGS84 coordinate system. I read through some basics and it seems I have to convert this ellipsoid height to orthometric height which I guess is roughly equivalent to Above Mean Sea Level (AMSL), correct?

I downloaded NOAA's VDatum for ellipsoid height conversion.. Attaching screenshot herewith.

I'm not 100% sure if 122.6m ellipsoid height for GPS location 47.662511,-122.152067 is correct or not?

Please also let me know if I want to get accurate height am I following correct approach?

I may have to again convert NAVD88 to AMSL for more accuracy right?


texts: How to open QGIS using a customisation file?

texts: I have a customisation file which can provide a much simplified QGIS interface for beginner users. We have QGIS available on a shared machine. I'd like to provide a shortcut which would open QGIS with the simplified interface already active (and another which opens it without customisation). It seems that on Linux this can be done with command line options. Is there some equivalent SIMPLE arrangement for Windows (I'm not a programmer, and I don't have admin permissions on any machines).


texts: grass algorithms no longer run in QGIS/Sextante

texts:
I used to be able to run GRASS algorithms in QGIS 2.0 via Sextante (Ubuntu 12.04) but not anymore. Initially I would double click on any grass algorithm and the execution would stop with:

"WELCOME TO GRASS              Version 6.4.3         2013

1) Have at your side all available GRASS tutorials

2) When working on your location, the following materials
      are extremely useful:
      - A topo map of your area
      - Current catalog of available computer maps

3) Check the GRASS webpages for feedback mailinglists and more:
       #I removed url because my reputation is below 10 and that doesnt allow to post more than 2 links

Hit RETURN to continue"

But after rebooting, if I double click on any grass algorithm, QGIS just hangs there. The same algorithm then works as expected in GRASS GIS 6.4.3 and via QGIS/GRASS plugin.

I've already completely removed and reinstalled (sudo apt-get purge qgis* and sudo apt-get purge grass*) QGIS and GRASS and removed ~/.qgis2 and ~/.config/QGIS

GRASS GIS is apparently working ok. When I double click on the icon, the command line launches with:

WELCOME TO GRASS              Version 6.4.3         2013

1) Have at your side all available GRASS tutorials

2) When working on your location, the following materials
      are extremely useful:
      - A topo map of your area
      - Current catalog of available computer maps

3) Check the GRASS webpages for feedback mailinglists and more:
      http://www.grass-gis.org
      http://grass.osgeo.org

Hit RETURN to continue

It's most likely a local problem but at the moment I'm out of ideas. Any will be greatly appreciated.


texts: What are a00000 files and how to control them?

texts:
Within my file geodatabase (ArcMap 10.6), I have probably thousands of files that begin with "a00000". Most of them are .gdbindexes, .gdbtable, .gdbtablex, .spx and the full name will be something like "a00000526".

What are these files and why are they being generated?

I'd like to know if I can delete them, and if I can tweak my file management to avoid having a bunch of unidentifiable files stored in my file geodatabase.


texts: Testing tools to simulate user map browsing / stress test tile server?

texts:
are there any online/offline tools that would simulate user map browsing behavior, possibly concentrating on certain areas or random?

I am trying to stress test a tile server.


texts:
I'm consistently getting an error 000725 (Output Feature Class already exists) when trying to use the "points to line" tool in ArcMap 10.3

It's a points shapefile with 4 points and I just want to make them into a square outline. I've used this tool before and gotten this error, then rebooted my computer and it worked perfectly for multiple files for this exact same function. No luck this time.

I've rebooted, I've checked the "overwrite outputs" option under Geoprocessing options, I've created a new File Geodatabase in case the problem was that my default geodatabase was full. Now it's writing to a blank geodatabase, and being told to overwrite files, and STILL giving me the error that the file already exists. I've re-ordered my points within the shapefile to make sure they are in the correct order, I've tried converting my data to a shapefile through multiple avenues... I can't think of any other reason I'm getting this error.

I am using just the ArcToolbox:
Data Management Tools > Features > Points to Line.

My input feature is a points layer shapefile that is visible on the map and in the table of contents

I've quadruple-checked every time that the output file name doesn't already exist, so it is not actually an overwrite problem as far as I can understand. And I leave Line Field and Sort field blank.

I've also noticed a second error message, Runtime 999999, the coordinates or measures are out of bounds.


texts: Using Rasterio to index by traditional longitude and latitude with Molleweide Projection GeoTIFF

texts:
I'm currently trying to read carbon footprint information from a GeoTIFF, I've never worked with geographic data before.

The link is http://worldmrio.com/citiesmaps/GGMCF_v1.0.tif

I was wondering how I would index the nd-array with longitude and latitude values that I've scraped for some cities. What I want is the actual value at each longitude and latitude.

Additionally, would there be a problem with the projection format?

print(dataset.crs)

gives me

PROJCS["World_Mollweide",GEOGCS["WGS 84",DATUM["WGS_1984",SPHEROID["WGS    84",6378137,298.257223563,AUTHORITY["EPSG","7030"]],AUTHORITY["EPSG","6326"]],PRIMEM["Greenwich",0],UNIT["Degree",0.0174532925199433]],PROJECTION["Mollweide"],PARAMETER["central_meridian",0],PARAMETER["false_easting",0],PARAMETER["false_northing",0],UNIT["metre",1,AUTHORITY["EPSG","9001"]],AXIS["Easting",EAST],AXIS["Northing",NORTH]]
{'type': 'Polygon', 'coordinates': [[(-18040095.3812882, 9020047.84316439), (-18040095.3812882, -9020047.84316439), (18040095.3812882, -9020047.84316439), (18040095.3812882, 9020047.84316439), (-18040095.3812882, 9020047.84316439)]]}


texts: FME DWGStyler "specified block '...' is not defined in AutoCAD file"

texts:
In a DWGStylertransformer I connect DWG/DXF Template File to a Published Parameter $(TEMPLATE_FILE):

The Template file exists and contains a block named kreuzchen which I am able to choose in the DWGStyler Parameters 'Block Name':

So, undoublty the block 'kreuzchen' exists in the template file.

So far so good, but running the workspace give the following error message:

Dynamically creating layer `koordinaten_auf_flurstuecken'
Specified block 'kreuzchen' is not defined in AutoCAD file.  Skipping feature
... Last line repeated 9 times ...

and below:

Processing AutoCAD File...
AutoCAD Writer: 165 feature(s) were rejected and not written to the destination dataset

What am I doing wrong or what am I missing rsp.?


texts: Running and debugging PyQGIS scripts in PyCharm Community Edition?

texts:
I am working with creating plugins for QGIS 2.4.0 (Chugiak). I am curious to know how I can write the codes, and debug them in the environment I am comfortable in, i.e. PyCharm Community Edition 3.4.1.

I am looking for a step wise methodology of how to set up PyCharm to read the debug scripts formulated in PyQGIS syntax.


texts: Preferred programming language and software for entire remote sensing workflow?

texts:
I have been involved in remote sensing for some years now during studies.  I am wondering which combination of software and image processing modules would be most suitable for an entire process chain for professional image processing solutions and products. I am very curious about what other users think and perhaps it will even lead into an interesting discussion from experienced users.

What I mean in detail is the combination of:

a database storing geographical data like shapefiles but especially huge amounts of satellite imagery with its corresponding metadata
image processing modules automatically using appropriate data from the database useful for the chosen processing step (e.g. all satellite data with at least a certain spatial resolution for a given time span and geographic area to produce change detection maps)
the results then should be integrated into the database and perhaps even be available for distribution via a web server

Unfortunately I do not have any advanced knowledge on databases for geographic data. Perhaps GeoNetwork/GeoServer with PostGIS would be an option?

For the image processing modules I thought of either implementing necessary algorithms in C++/GDAL or JAVA/Geotools. Also there would need to be some kind of module connecting to the database in order to fetch the needed data for processing and the creation of metadata for the processed images/products. My thoughts were that generally open source solutions would be best as such a system would be developed for a long run and being independent of commercial companies would be desired.


texts: How to get the polygon defining a road when I have the way's `osm_id`?

texts:
I have the osm_id of various roads defined in OpenStreetMap and I am trying to get the polygon defining the road. How might I do this, preferably in JavaScript and preferably without downloading data from OSM to my own server. I am new the whole GIS ecosystem so I apologise if my question does not make sense because I misunderstood something.

What I intent to do is to highlight certain roads on my map and for that I thought of adding a new layer (I am using Mapbox.js) which would contain a coloured polygon over the road I'm trying to highlight.


texts: Looking for open source Spatial file server that ArcGIS 10.1 will connect and work with?

texts: I'm looking for an open source spatial file server to house and serve my GIS data.  I'm currently using my Ubuntu Server as a ssh file server and have to download the data to the local computer, manipulate and then re-upload to the server.  I would prefer to use ArcCatalog to connect to the server and manipulate the data in-situ.  Are there any open source Spatial servers that Arc will communicate with? I'm not very interested in WMS or other web based displays.


texts: What is the color standard for roads or Transportation for USA?

texts: Are there color standards for US Transportation roads such as Interstate, County,, Interstate, local, private, state highway and other roads out there ?


texts: Attribute error:'NoneType' object has no attribute

texts:
I tried to run a python script for getting the coordinate system of a feature/shapefile as follow

>>> import arcpy
>>> from arcpy import env
>>> env.workspace="D:\data"
>>> fc="river.shp"
>>> dsc=arcpy.Describe(fc)
>>> dsc.spatialReference.Name
>>> print dsc

i'm getting following error at line 5

  Attributeerror:'NoneType' object has no attribute Name.