texts:
To start, I'm very new to scripting.
On ArcGIS, there is a python script for a Sinuosity tool http://resources.arcgis.com/en/help/main/10.1/index.html#//001500000022000000

I've tried it and it didn't work and so I did some changes to it and while it runs without error, I get no output in my attribute table. What are my errors? What can I do/add to this script to get an output?

import arcpy
import math
import os

#overwrite existing output
arcpy.env.overwriteOutput = True

class Toolbox(object):
    def __init__(self):
        self.label =  "Sinuosity toolbox"
        self.alias  = "sinuosity"

        # List of tool classes associated with this toolbox
        self.tools = [CalculateSinuosity]

class CalculateSinuosity(object):
    def __init__(self):
        self.label       = "Calculate Sinuosity"
        self.description = "Sinuosity measures the amount that a river " + \
                       "meanders within its valley, calculated by " + \
                       "dividing total stream length by valley length."

    def getParameterInfo(self):
        #Define parameter definitions

        # Input Features parameter
        in_features = arcpy.Parameter(
            displayName="Input Features",
            name="in_features",
            datatype="GPFeatureLayer",
            parameterType="Required",
            direction="Input")

        in_features.filter.list = ["Polyline"]

        # Sinuosity Field parameter
        sinuosity_field = arcpy.Parameter(
            displayName="Sinuosity Field",
            name="sinuosity_field",
            datatype="Field",
            parameterType="Optional",
            direction="Input")

        sinuosity_field.value = "sinuosity"

        # Derived Output Features parameter
            out_features = arcpy.Parameter(
            displayName="Output Features",
            name="out_features",
            datatype="GPFeatureLayer",
            parameterType="Derived",
            direction="Output")

        out_features.parameterDependencies = [in_features.name]
        out_features.schema.clone = True

        parameters = [in_features, sinuosity_field, out_features]
        return parameters

    def isLicensed(self): #optional
        return True

    def updateParameters(self, parameters): #optional
        if parameters[0].altered:
            parameters[1].value = arcpy.ValidateFieldName(parameters[1].value,parameters[0].value)
        return

    def updateMessages(self, parameters): #optional
        return

    def execute(self, parameters, messages):
        in_features  = parameters[0].valueAsText
        fieldName   = parameters[1].valueAsText

        if fieldName in ["#", "", None]:
            fieldName = "sinuosity"

        arcpy.AddField_management(inFeatures, fieldName, 'DOUBLE')

        expression =
    def getSinuosity(shape):
        length = shape.length
        d = math.sqrt((shape.firstPoint.X - shape.lastPoint.X) ** 2 +
              (shape.firstPoint.Y - shape.lastPoint.Y) ** 2)
        return d/length

    arcpy.CalculateField_management(in_features,fieldName,'getSinuosity(!shape!)','PYTHON_9.3')


texts: Clip a Mask (NDSI) from another Mask (NDWI) in GEE

texts:
I have created a mask of Normalized difference Snow Index (NDSI) in the late winter using a combination of Landsat 5,7,8 imagery and I would like to only keep a remaining land features by clipping out the overlapping results from a Mask created on a normalized difference water index to only get land ice and snow. When I do a simple subtraction, the variance in reflection due to different seasons becomes to great to erase one another.

//Create a Mask on all the ice+Marl+Snow+Water features.
var NDSIMasked = NDSI.updateMask(NDSI.gte(0.25));
Map.addLayer(NDSIMasked.clip(Study), {palette:'d675ff'}, 'NDSI Tresholded Area');

// Create an NDWI image, define visualization parameters and display.
var ndwi = Composite.normalizedDifference(['B3', 'B5']);
var ndwiViz = {min: 0.0608, max: 0.1706, gamma:[1]};
Map.addLayer(ndwi.clip(Study), ndwiViz, 'NDWI', false);
Map.addLayer(Composite.clip(Study), {bands:['B4', 'B3', 'B2'], min: 0.0608, max: 0.1706}, 'Summer Landsat 8');

var optionsNDWI = {
  title: 'NDWI',
  fontSize: 20,
  hAxis: {title: 'NDWI Value'},
  vAxis: {title: 'Frequency'}
};

var histogramNDWI = ui.Chart.image.histogram(ndwi, Study,30)
.setOptions (optionsNDWI);
print(histogramNDWI);

var NDWIMasked = ndwi.updateMask(ndwi.gte(0.15));
Map.addLayer(NDWIMasked.clip(Study), ndwiViz, 'NDWI Thresholded Area');


texts: I need to start learning Python, and I want to learn with version 3.x. I understand that QGIS--at least some plug-ins--relies on Python and Tcl/Tk, and probably on specific versions. Assuming that QGIS is dependent on Python 2, can anyone tell me how to set up parallel installations of Python 3 and Tcl/Tk such that QGIS will have what it needs and I can use Python 3 for other purposes?


texts: Wrong layout when using OpenLayers plugin

texts:
I'm drawing a simple map and I noticed a weird problem. Very briefly: I have a simple shapefile (a region) and the Google Satellite layer of the OpenLayers plugin activated on my map canvas.

On the fly reprojection is on (EPSG: 3857).

I want to create a print layout with the region and, next to this map, another map with an overview of the first map.

All is fine, I blocked both the map, but, when I try to save the layout as image the second map (that with the overview) is shifted and it doesn't correspond to the original view of the map.

The following pictures show what you can see in the map composer and the exported image:

BTW: I noticed the same problem on the 2.4 and on the master version.


texts:
I have a .shp file from here, and I want to dump it into an .sql file, or a postgres/postgis database, but everytime I use shp2pgsql I get this:

shp2pgsql -s 4326 -a Europe_coastline.shp > test.sql
Shapefile type: Arc
Postgis type: MULTILINESTRING[2]
Segmentation fault

What am I doing wrong, or how can I fix it?


texts: Saving Google Earth Location: OpenLayers Plugin in Quantum GIS

texts:
I use the OpenLayers plugin to load Google Earth Layers in Quantum GIS to digitize/identify certain features. As my work is large occassionally I have to quit Quantum GIS to resume later. The problem I face is though I save my project as a qgs file I am not able to get the dynamically updated layer of Google Earth in the next session. The Google Earth layer just appears in the top left corner of the map area in QGIS and it shows only a portion of the area I work with. I can't zoom/pan further to other places.

Also I am not in favour of using Google Earth plugin for this work as it just takes a snapshot of the scene I have zoomed onto in Google Earth.


texts: Raster calculator - problems with syntax

texts:
I have a raster layer with values ranging from 0.00597303 to 0.102894 and I want to assign specific number representing a group to specific range of values:

Group 4: x >= 0.1
Group 3: 0.01 <= x < 0.1
Group 2: x < 0.01

I am using the following syntax:

("Ri_Q50@1" >= 0.1) * 4 + (("Ri_Q50@1" >= 0.01) AND ("Ri_Q50@1" < 0.1)) * 3 + ("Ri_Q50@1" < 0.01) * 2

However, the output file only has assigned group 2 and 3 but not the 4th group (x >= 0.1). What could be the reason?

Note: When I use the Raster pixels to points and check the output point layer there is 12 points having exceeded the condition for 4th group - ie 12 pixels has value above 0.1).


texts:
Why does my naming convention change depending on where the output is saved?

When I save this to a .gdb, the name of the output is "tif", not final_mosaic.tif.  When I save the same output to a regular Windows directory, the name is correct (final_mosaic.tif).

import arcpy, os
inws = r'C:\input'
outws = r'C:\output.gdb'
rasters = []
for dirpath, dirnames, filenames in arcpy.da.Walk(inws, topdown = True, datatype="RasterDataset", type = "TIF"):
    for filename in filenames:
        rasters.append(os.path.join(dirpath, filename))
arcpy.MosaicToNewRaster_management(rasters, outws, "final_mosaic.tif", pixel_type = "32_BIT_UNSIGNED", number_of_bands = 1)


texts: Function in OpenLayers 5 JavaScript does not work

texts:
I am making a weather application and it is essentially working. (It is my first GIS-application, so I am really glad with that!) It is just still very basic.

I made de application with PostGIS, NPM (Node.js/Parcel), Geoserver (Tomcat) and OpenLayers 5.

Now I am trying to add the simple option to change a variable with user-input. Except, when I run the application it tells my that my function (doStuff) is not defined. It is in the same JavaScript file as all the other JavaScript and that works perfectly fine.

(When I put the  code in the body of my HTML, then it does work. (The input part.) But I need the function to be in the JavaScript file. Not only because that is where it belongs, but also because I need the input for a variable in that file.)

Below the code. Can anybody tell me what I am missing?

    import Map from 'ol/Map.js';
    import View from 'ol/View.js';
    import TileLayer from 'ol/layer/Tile.js';
    import OSM from 'ol/source/OSM.js';
    import TileWMS from 'ol/source/TileWMS.js';

        var inputvp = "2018-10-19 08:00:00";

//Below the function that I made for the input. But also the function that gives an ERROR. (doStuff is not defined)
function doStuff() {
            var nameElement = document.getElementById("someInput");
            inputvp = nameElement.value;
            console.log(inputvp);
        };

        var wmsSource = new TileWMS({
            url: 'http://localhost:8080/geoserver/Observations/wms',
            params: {'LAYERS': 'Observations:Obs', 'TILED': true, viewparams: 'chosen_timestamp:' + inputvp},
            serverType: 'geoserver',
            crossOrigin: 'anonymous'
          });

        var wmsLayer = new TileLayer({
            source: wmsSource
          });

        var view = new View({
            center: [0, 0],
            zoom: 1
          });

        var map = new Map({
            layers: [wmsLayer],
            target: 'map',
            view: view
          });

--

    <!DOCTYPE html>

        <title>Tiled WMS</title>

    <input id="someInput" type="text">
    <input type="button" value="GoToDate" onClick="doStuff()">


texts: Attribute inspector not editable - FLEX or Javascript

texts:
I am using ArcGIS 10.2. I have an application that is using the editor and the attribute inspector. I need to add a string showing the current date to a field. Everything works but after creating the feature and selecting it again I can see the string in that field in the attribute inspector but the attribute inspector is not editable any more for that feature.

Is it possible to add a string to a field and still have that feature editable in the attribute inspector?

var currDateTime:String = ""
private function drawEnd(event:DrawEvent):void
   {
    dateFormatter.formatString = 'YYYY/MM/DD HH:NN:SS';
 currDateTime = String(dateFormatter.format(dtCurrent) + '.' + dtCurrent.getMilliseconds());

   FeatureLayerstewardship.addEventListener(FeatureLayerEvent.EDI}TS_STARTING, editsStartingHandler);
         }

     private function editsStartingHandler(event:FeatureLayerEvent):void
            {
                if (event.adds)
                {
                    event.adds[0].attributes['DrawDate']  =  currDateTime;
                }
            }


texts: Expression labelling to annotation - ArcMap to CAD

texts:
I have point feature layer (more than 100).
My task is labelling that point and convert annotation (I use ArcMap) then export that to DWG format

I use this script to labelling :

    mxd = arcpy.mapping.MapDocument("CURRENT")
... for lyr in arcpy.mapping.ListLayers(mxd):
...     if lyr.isFeatureLayer:
...         f = arcpy.ListFields(lyr,"*grid_dec*")
...         if f:
...             lyr.labelClasses[0].expression = '"{}" &
    (left([grid_dec],1)) & " " & "<SUB>" & (right(
    [grid_dec],1)) & "</SUB>" & "{}"'.format("<FNT size = '17'>
    <CLR blue = '255'>","</CLR></FNT>")
...             lyr.showLabels = True
...         else:
...             print lyr.name
...     lyr.visible = True
...
... arcpy.RefreshActiveView()

It works, but the problem is, I just realize when I convert to annotation it become text not number (value in the field), so when I export to DWG it become text, Here is the screeshot

If I use simple expression for example :

 lyr.labelClasses[0].expression = round([field],2)

It is still a number in string field, but I need to use subscript function to be applied at my number and the result should be become a number, so any clue or workaround?

this is screenshot of my solution that ive made


texts: Is there a list of Open Source tool alternatives for ArcGIS tools?

texts:
Is there any place one can find a list of ArcGIS alternative or near-alternative tools found in (any of) the open source softwares? I am not looking for software but individual tools found in the software.

I started my GIS career with ArcGIS. Today I am using more and more Open Source software such as QGIS, SAGA GIS, and R among others. I have spent hours and hours of time when finding different tools that do the same thing as those so conveniently found in ArcGIS (because you know what to look for). It would be very convenient and time saving to just check the alternative from a list than spend time googling and reading various manuals and doing trial and error at your desktop.

e.g., ArcMap: Spatial Analyst: Raster calculator - SAGA GIS: Grid Calculus: Grid Calculator

I see that there are several threads dealing with this, but they are regarding this with a smaller scope:

Seeking open source alternative to ArcGIS Desktop's Integrate tool?
GDAL (or other open-source) equivalent of Arc's Point To Raster Tool
Are there open source alternatives to ArcCatalog?

I am looking after a comprehensive, "dictionary type" of list.

So is there a comprehensive list or a site regarding this, and if not, how could we get one? I think this would be very useful for a whole lot of people!


texts:
I am working on an application that renders land parcels from PostGIS as polygons in Leaflet.
I have an event handler set for 'viewreset' on the map:

this.leaflet_map.on('viewreset', this.viewport.regenerate, this.viewport);

The this in this case is an object I've created, called pt_map. viewport is an object I've created to wrap the methods for regenerating the view based on the current map bounds. My code works on initial load, as well as on panning the map. However, when I zoom in or out, I get the following error in line 4842 of leaflet-src.js:

  Uncaught TypeError: Cannot call method 'latLngToLayerPoint' of null

Any ideas? My full code is available at https://github.com/CoherentLogic/ptarmigan/blob/experimental/web/ptarmigan/parcels/layers.js


texts:
I inherited some shapefiles that I've been trying to clean up in QGIS and Grass. The shapefile is a large area covering a watershed, the person who digitized it, did so in small chunks without using the snapping tool, so there were many overlaps and gaps. I cleaned those up with the dissolve tool, and everything seems fine.

This is when we run into the problem. When I validate the shapefile, it comes out as invalid with 4 different errors. They are all "polygon inside polygon" but they show up at the coordinates 0,0 and there's nothing actually there.

Has anyone ever had this error?

Here's a link to a Google Drive folder with the files I've included the shapefile in question, and the two files created from the validation tool. I also included a PSR file showing my steps.

Basically, I'm trying to find the location of the error, according to the Error layer, and when I zoom into the selection it brings me to the coordinates 0,0, and there's no error there.


texts: Downloading street names from OSM using QGIS yielding different datasets

texts: I want to create an Excel sheet with all residential streets in France. To do so I want to use QGIS and the QuickOSM tool. By doing so I have been running into an issue. QGIS is giving me 4 different data sets when I download residential streets for an area (one with a square, 2 with a line and one with a dot). I'm not sure which one yields the information I am looking for as all 4 datasets have different amounts of observations when I look into their table. Also, when choosing the right dataset, can I be sure that no streets are being double-counted?


texts: Determing partially Overlapped features from two linear feature classes

texts:
I have been trying to find object ids of features that overlap partially.
Input taken is two linear feature classes , I have tried IRelationalOperator Overlaps methords , but it seems that it only provides those features that overlaps completely . Is there any way round to get those features which overlaps partially.

The other way I tried was through esriSpatialRelationOverlap methord but it seems to produce error, which I have posted in following forum link .

http://forums.arcgis.com/threads/87164-AutomationException-0x80004005-error-while-quering-overlapped-features?p=308026#post308026

Kindly provide me a way to resolve this issue .
Thanks in advance////

Edit Update-----
Got the answer by using "esriSpatialRelOverlaps"////


texts: How to use IDatabaseCompact.Compact() on an used IWorkspace, without permission denied

texts:
I am writting an ArcMap-AddIn with vb.net. I get an error when trying to compact my IWorkspace(mdb), the error is:

  COMException

  You tried to open a database, which was already opened by the user
  'ADMIN' on Computer 'XXXXXX'. Try it again when the database is
  available.

  On ESRI.ArcGIS.Geodatabase.IDatabaseCompact.Compact() on
  MyProject.MyClass.CompactGDB(IWorkspace pWS)

How can i access that workspace, which i used before, to compact it?

The Code:

' CompactGDB
    Public Sub CompactGDB(ByVal pWS As IWorkspace)

        Dim pDatabaseCompact As IDatabaseCompact
        If (TypeOf pWS Is IDatabaseCompact) Then
            pDatabaseCompact = CType(pWS, IDatabaseCompact)
            If (pDatabaseCompact.CanCompact) Then
                Try
                    pDatabaseCompact.Compact()
                Catch ex As Exception
                    MessageBox.Show(ex.type & ex.Message & ex.StackTrace, "Error", MessageBoxButtons.OK, MessageBoxIcon.Error)
                End Try

            End If
        End If

    End Sub

I've got 8 other functions, which work with my workspace.

Any suggestions?


texts:
I have a number of raster files saved locally which I use for basemapping in QGIS. I have built virtual raster fields to load these in one go but I'm looking to store them within my PostgreSQL database to share with other users.

Does anyone know whether this is possible?


texts: Calculating miles between two points using Vincenty formula

texts:
I have the following MySQL function:

DELIMITER $$
DROP FUNCTION IF EXISTS `fn_vincenty_distance`$$
CREATE FUNCTION `fn_vincenty_distance` (
        lat1 FLOAT, lon1 FLOAT,
        lat2 FLOAT, lon2 FLOAT
     ) RETURNS FLOAT
    NO SQL
    DETERMINISTIC
    COMMENT 'Returns the distance in degrees on the
             Earth between two known points
             of latitude and longitude
             using the Vincenty formula
             from http://en.wikipedia.org/wiki/Great-circle_distance'
BEGIN
    RETURN  DEGREES(
    ATAN2(
      SQRT(
        POW(COS(RADIANS(lat2))*SIN(RADIANS(lon2-lon1)),2) +
        POW(COS(RADIANS(lat1))*SIN(RADIANS(lat2)) -
             (SIN(RADIANS(lat1))*COS(RADIANS(lat2)) *
              COS(RADIANS(lon2-lon1))) ,2)),
      SIN(RADIANS(lat1))*SIN(RADIANS(lat2)) +
      COS(RADIANS(lat1))*COS(RADIANS(lat2))*COS(RADIANS(lon2-lon1))));
END$$
DELIMITER ;

I cannot reproduce some of the airport distances in miles. I'm using 69.2 miles as the distance between each degree of latitude at the equator:

Case 1

SFO-DFW

fn_vincenty_distance(37.6188056, -122.3754167, 32.896800990, -97.038002010)*69.2

Returns 1463.70 which is close to 1464.373 from https://www.airmilescalculator.com/distance/sfo-to-dfw/

Case 2

MIA-ORD

fn_vincenty_distance(25.7953611, -80.2901158, 41.9745219, -87.9065972)*69.2

Returns 1200.77 which is not close to 1197.062 from https://www.airmilescalculator.com/distance/mia-to-ord/

Question

How can I get the same answer being produced from airmilescalculator.com?

This is to match the calculation by airlines, for example from AA.com:


texts: I'm trying to convert a line shapefile to a raster image at QGis, but my attempts have been unsuccessful. I've tried to use Raster/Conversion/Rasterize and SAGA/Grid - gridding/Shapes to  grid, but to no avail. Is there any other way to accomplish this?


texts: Extracting GeoTIFF colours and adding to equal geometry shapefile

texts:
I have the following map in .png-format that I would like to replicate, but I cannot obtain the original data.

The map shows the current water supply vulnerability for local municipalities in South Africa. I took a screenshot of the map and georeferenced with a local municipality shapefile. Here is the original .png-map:

And here is the Local Municipality shapefile on top of the georeferenced raster:

I would now like to extra each municipality value/colour (there are 10) to the shapefile. I tried using the SAGA-GIS Module 'Add raster values to features' tool, but the result classifies all features as 255:

Where am I going wrong, or is it not possible to do this? This question is similar but the answer exceeds my capabilities.


texts: ArcGIS dynamic layers performance with many features to display

texts: So we have data with over 10,000 features in a very small area of less than 50 acres or so and we are getting pretty slow performance of several seconds when the extent is changed via panning and zoom in/out on the client.  We are publishing these as dynamic layers using ArcGIS Server 10.2 and displaying in a ArcGIS JS web app.  Is there something we can do to improve performance and not show all features at once?  Somehow intelligently dissolve the data so the UI isn't tied up when the extent changes on the client.  Let me know if I need to explain this any better.


texts: How to display inches in the Print Composer margin guide

texts:
I can't figure out how to change the margin guides in Print Composer to inches rather than metric.

In the "Composition" tab, under "Page size" I have ANSI A (8.5 x 11 in) selected.

However, the "Units" box below that is greyed out. The "Guides and Grid" section below that only gives options in terms of "mm".

This was indicated as fixed at

How do I set the composer layout units to inches?

However, as was noted there,

"I am having the same issue as above, and have not been able to reproduce your answer. In my installation, choosing a paper size in inches only changes the presets box. The width, height and units are all still in 'mm', and the units are locked and grayed out. – Get Spatial Oct 28 '15 at 23:13"

I am having the same experience as "Get Spatial". Does anyone have any idea why we continue to have this problem, although it seems to have been fixed for some?


texts: Optimal Way to Assign Most Popular Neighbor Variable in PostGIS

texts:
I've got a census block table in Postgres with the appropriate geom column and a string variable. All census blocks that have a population greater than 0 have an assignment for my string variable. Those that do not have any population have no assignment.

What is the optimal (in terms of query time) way to assign the most popular value of the neighboring census blocks to the center census block below? In simpler terms, how can I assign "A" to the center census block below because it's the most popular surrounding value?

st_touches seems to be running unrealistically long, perhaps I'm missing a where filter or some other tactic to decrease the run time of the query?

Example Query:

select
    b.censusblock,
    b.countyname,
    c.district,
    c.censusblock as touch_block from bb
left join schema.districts c on st_touches(b.geom,c.geom) and c.countyname=b.countyname


texts: Downloading OpenStreetMap data with street names and city attributes for ArcGIS Desktop?

texts:
I'm currently trying to download data from OpenStreetMap specifically from San Carlos, Venezuela. I'd like to take the OSM file and convert it to SHP for use in ArcGIS.

I've used geofabrik for other country's in the past, but Venezuela is not available for download. Exporting a bounding box of the city directly from OpenStreetMap, then using OpenStreetMap Toolbox to convert the OSM to SHP gives me the lines but it's missing street names and city. Ideally I'd have addresses as well, but I can live with just street names.

Is there any way to achieve this? Export all streets within a city from OpenStreetMap, then convert it to SHP with city and street name attributes?


texts: Selecting one subdataset when using ModelBuilder in ArcMap for reprojection

texts:
I'm trying to reproject roughly 500 MODIS images (MOD09GQ) into an Equal Areas Projection. I've been informed that ModelBuilder would be the best way to do this. However, when I set up my model and try to add my data, I can't see any way to select just one subdataset from the HDF data. I just want to reproject the Band 1 data. As such, when I run the model, all of the datasets are also reprojected, including numerical observations etc., resulting in an image which is just geometric patterns of colours.

I'm new to GIS.


texts: How do I prevent QGIS 1.8.0 changing my dbf table values when joining tables?

texts: Im a newbie on GIS as well as QGIS. I have a table of data saved from Excel as dbf format. After dragging and dropping the file into QGIS and then opening the attribute table, all values less than 1 in my original table have been changed to 0. How can I prevent this?


texts: QGIS GeoPDF Export - change field that appears top in pdf model tree

texts:
I am exporting a map layout to GeoPDF using QGIS.
Is there a way to change/choose the layer field that gets used in the pdf model tree as the display field for each record? I have attached a screenshot that shows the 'PSOL Category' field has been used as the display field in the model tree, whereas I would like it to the the 'Asset Number' field.


texts: In embedded map - can I temp disable all hoverwindows while any infowindow is open

texts:
I have CartoDB map with hover and infowindows for 1000 polygons.
When user click we want to open infowindow for processing (update able form)
and want: stop hover windows from working until user finishes and closes infowindow
Then: re-enable all hover windows...

In embedded CartoDB map - can I temp disable all hoverwindows while any infowindow is open


texts: Extending line segment to polygon edge using ArcGIS for Desktop?

texts:
I am trying to extend line segments to the related parcel.  There is not an address field in the line segment but there is a year field.  The year field is what needs to be added to the parcel to conduct further analysis.
Is there a tool that allows you to extend a group of line segments to the nearest polygon based off of start or end points?  I also would like to have a threshold of X.
I've played around with the extend line tool.
Could just turn the vertices to start point for the line and then join spatially to the nearest polygon but I don't have confidence in this method.


texts:
Trying to shoot a ray (LineString) through multiple shapely objects and figuring out how many intersections there are.
Having some issues though, as the intersection-method have multiple return types and I need to handle all of them in order for my program to run smoothly. The obvious ones are Point and MultiPoint but can someone tell me the rest? Have tried looking at source code and the manual, but it seems tricky to figure out..


texts: Set the QGIS display to show decimal degrees?

texts:
Using QGIS 2.6.1 Brighton. I am trying to set the CRS for the project to display Decimal Degrees, where it is defaulting to Feet. I can change it in the Properties Dialog, but it does not change it, it is just staying on Feet. How do I change it?

Edit: this layer was imported from a shapefile where it was internally set to Feet. I was able to get the vendor to supply one with Decimal Degrees so my problem is gone. Still would love to know if there was a way to do it myself from within QGIS.


texts: Getting back both the map and the data from a request via overpass-turbo.eu

texts:
For a little (!) project I need to have the data (in DB) and the maps-
this request delivers the Map
[timeout:600];
area["ISO3166-1"="BR"]->.brazil;
area["ISO3166-1"="AR"]->.argentina;
area["ISO3166-1"="VE"]->.venezuela;
area["ISO3166-1"="PE"]->.peru;
area["ISO3166-1"="CL"]->.chile;

/* more areas..*/

(
  nwr[amenity=hospital](area.brazil);
  nwr[amenity=hospital](area.argentina);
  nwr[amenity=hospital](area.venezuela);
  nwr[amenity=hospital](area.peru);
  nwr[amenity=hospital](area.chile);
  /* other queries... */
);
out center;

... and this request delivers the data;
[out:csv(::id,::type,::lon, ::lat, "name","addr:postcode","addr:city","addr:street","addr:housenumber","contact:website"," contact:email=*")][timeout:600];
area["ISO3166-1"="BR"]->.brazil;
area["ISO3166-1"="AR"]->.argentina;
area["ISO3166-1"="VE"]->.venezuela;
area["ISO3166-1"="PE"]->.peru;
area["ISO3166-1"="CL"]->.chile;

/* more areas..*/

(
  nwr[amenity=hospital](area.brazil);
  nwr[amenity=hospital](area.argentina);
  nwr[amenity=hospital](area.venezuela);
  nwr[amenity=hospital](area.peru);
  nwr[amenity=hospital](area.chile);
  /* other queries... */
);
out center;

I want to have both - the map and the data. But how to achieve this? Which request gives back both?


texts: Setting processing extent for image classification using ArcMap

texts:
I'm trying to limit a maximum likelihood image classification in ArcMap 10.7.1 to the processing extent of my AOI shapefile. However, no matter how many times I've tried, it just does the image classification for the extent of the entire satellite image, and not the AOI.
In the image classification settings, I go to environments and set the processing extent to my AOI, but it just doesn't work. I even just tried to clip the image classification file to the extent of my AOI after completing the classification, and it said it had done the clipping function correctly but the image wasn't clipped to my AOI.
I'm wondering if this has anything to do with projections, including the projection of the dataframe. The satellite image I used to create my signature file for the image classification is in a projected coordinate system. So, I also made sure to reproject my AOI shapefile to the same projected coordinate system. I also went ahead and changed my dataframe to this projected coordinate system, but this didn't fix the problem.


texts: Data not showing in QGIS after re-opening the file

texts:
I'm pretty new to QGIS and have some problems loading content. After loading some vector and shapefiles i'd like to make a new layer myself or edit data coming from the loaded files (like clipping, dissolve etc.). Everything works normal and everything shows exactly how it has to be. But after closing the document and re-opening it later, only the loaded layers are visible, the edited layers are invisible and the attribute table is empty (which it wasn't before I closed the file).

Can somebody help / explain what I did wrong?


texts:
How would I setup PyCharm to recognize import arcpy?

I'd like to use PyCharm to develop and debug geoprocessing tool.


texts: Norwegian and Swedish Coastline/Shoreline Types GIS Data

texts:
I am looking for a data source for Coastline or Shoreline data of Norway and Sweden. I have this data for Denmark, and it specifies the coastline type such as:
- Man made
- Rocky
- Sandy
- Vegetated/Marsh

I have been trawling the web, and not found much.  I am using QGIS 2.14.5 (Essen) and a vector shapefile (.SHP) or Raster data source would be best.


texts:
I need to disable L.control.layers when user click's on a certain button and enable when it click's on a seccond button.

Is this possible?


texts:
I want to modify the copy_coords plugin such that when I click on it, It should open a dialog box and ask for a file name and address. After this it should store all the points I click on into that file. As of now, I have modified the code such that it will save it in a CSV file which is predetermined, so rather than saving it in a predetermined file, it is better to store it in a file determined by the user.

I have added these few lines at the end of the original code:

xx=str(point.x())
yy=str(point.y())
clipboard= QApplication.clipboard()
clipboard.setText(str(xx)+","+str(yy)) #This is the original part of the code
#these are the lines i have added
fd=open("XYZ.csv","a")
fd.write(str(xx)+","+str(yy)+"\n")
fd.close

So I need help on getting the input dialog for getting the filename and address. Please note, I am new to Python.


texts: Why is this MODIS Output from Google Earth Engine Shifted?

texts:
I'm creating and saving the NDVI output of MOD13Q1 of a given district to Google Drive from Google Earth Engine.

If I use the following code, the output tiff gets generated, but it is shifted about 14 KM to the north.

(The shift is not present in the Image shown on the map, but only in the Tiff file that is created)

var modis=ee.Image('MODIS/006/MOD13Q1/2018_09_30')
  .select(['NDVI', 'sur_refl_b03']);

var vi = modis.expression(
    '(BL >1500)?0:((A==-3000)?0:(A*0.0001))', {
      'A': modis.select('NDVI'),
      'BL':modis.select('sur_refl_b03')
});

var geometry = ee.Geometry.Rectangle([79.5, 20.4, 81.8, 21.7]);

Map.setCenter(80,20.5, 8);
Map.addLayer(vi, {min: -1, max: 1, palette: [
    'FFFFFF', 'CE7E45', 'DF923D', 'F1B555', 'FCD163', '99B718', '74A901',
    '66A000', '529400', '3E8601', '207401', '056201', '004C00', '023B01',
    '012E01', '011D01', '011301'
  ]});

Export.image.toDrive({
  image: vi,
  description: 'Gondiya_NDVI_30Sept',
  scale: 250,
  region: geometry,
  fileFormat: 'GeoTIFF',
  formatOptions: {
    cloudOptimized: true
  },
  maxPixels: 1e12
});

What is causing this shift? How do I correct this?


texts:
I am running Windows 7, QGIS 3.12.3 Bucuresti and hitting a wall trying to create a new shapefile. I have georeferenced (GeoTIFF) imagery and I want to create polygons that cover forested areas within the imagery in order to assign a particular forest type (coniferous, deciduous, etc.) in an area in Eastern U.S. This will be used to import into FlightGear as new Scenery that will populate the tree(s) into the scenery. I ran across a "How To" article (http://wiki.flightgear.org/Howto:Create_custom_terrain) that appeared to cover what I want to do, but I believe it's based on a very, very old version of QGIS (1.X).
I may be approaching this wrong, but I select Create New Shapefile Layer, give it a unique name, select Polygon, and add a new field called "Class" (Text Data) and add it to the Fields List. With both the respective imagery and the just-created Shapefile in the Layers window (made sure that the CRS was the same in both), I left click on the Shapefile, then right-click, select Toggle Editing, then draw the polygon on the visible imagery. I believe that after the last point is selected, I should "right click" and the polygon should remain visible. However, nothing happens. However, if I select the Imagery file, then do the same, the polygon disappears and I get the following error: "No active vector layer: To select features, choose a vector layer in the layers panel." In the instructions in the above "How To", it never mentioned creating a Vector layer.
Any info, or a pointer to a more up to date tutorial?


texts: Adding arrow to Layout View in map of ArcGIS for Desktop?

texts:
To say it right at the beginning: I don't mean the North Arrow ;-)

In fact I have a map in the layout view which contains an orthophoto. On this orthophoto there is a little forest road and I want to insert an arrow at the edges of the map that shows where this road is going.

I have been searching for quite some time...how is that possible in ArcMap?

Here is a quick illustration of what I mean:


texts: Converting Road Lines to a Binary Raster Image

texts:
I got road data from the USGS database and imported it into QGIS.

And I want to transform it into a binary raster image that looks like this in QGIS (this is only a processed screen shot but I want to be able to control the raster resolution in QGIS)

So far I've done a buffer and dissolve (Vector -> Geoprocessing Tools -> Buffer(s)...) but I have been unsuccessful in transforming it into a actual raster in QGIS.


texts: Python GDAL: degrees to meters without reprojecting

texts:
I am trying to get senseful results in my Python script. I want to measure distance between features in a shapefile. I'm working with the SRS: GCS_WGS_1984, so my units are in degrees. But for the user, it would be better to have these units in meters, for more comprehension.
How can I convert degrees into meters? I'd like to not reproject my shapefile...


texts:
My first map shows typical two-language map in Finland. I have used first rule green (finnish name) and after that rule magenta (swedish name). Labeling looks now a quite fine but still I want to add missing street names (marked red circles). I want to fill those areas using smaller font and shorten forms about name ending.

Next I create new label rule (black color) where I reduce size of font and I want to prioritize this rule lower than green and magenta. I have set priority value as lower as possible and also z-index is zero or under. Green has 1001 and magenta has 1000. Priority order should be green, magenta, black.

Next I check result which is not wanted. There black has replaced many label places from green and magenta rule. How to set black rule really under green and magenta? Is this bug in QGIS labeling or is there some settings which need to do?


texts: How can I find a point inside a polygon in PostGIS?

texts:
How can I find a point that is guaranteed to be within a given polygon in PostGIS?

I am aware of the ST_Centroid function.  However, the centroid is not always within a polygon, see below:

Furthermore, I would like to avoid using a point that is on the polygon boundary, but rather want one that is inside the boundary (and not inside a hole in donut shaped polygons).


texts: Writing an algorithm for filtering spatial data based on the local coefficient of variations in R

texts:
I'm trying to write an algorithm for filtering spatial data based on the local coefficient of variations within a search radius. If the number of points with CVs over 25% equals to the total number of points within a search radius, the centre point will be classified as a local outlier or a noise. But I currently stuck on calculating the number of points within a search radius.  Codes below:

test_data <- XXX

# calculate the coefficient of variations in the local neighbour

CV <- function(mean, sd){(sd/mean)*100}

LocalCV = sapply(1:length(test_data),
                function(pt)
                {d = spDistsN1(test_data, test_data[pt,])
                return(CV(mean=mean(test_data[d < 5,]$Z),
                          sd=sd(test_data[d < 5,]$Z)))})

LocalCV[LocalCV > mean(LocalCV, na.rm = T)] <- NA

Temprory.df <- na.omit(data.frame(test_data, LocalCV))

coordinates(Temprory.df) <- c("coords.x1","coords.x2")

# If the total number of CVs over 25% equals to
# the total number of CVs within a search radius
# then return TRUE or 1

Num.CV = sapply(1:length(Temprory.df),
         function(pt) {d = spDistsN1(Temprory.df, Temprory.df[pt,])
             return(length(Temprory.df[d<5]$LocalCV[Temprory.df$LocalCV>25])
                                       ==length(Temprory.df[d<5]$LocalCV))})

Then I got an error message:

Error in `[.data.frame`(x@data, i, j, ..., drop = FALSE) :
undefined columns selected
Called from: `[.data.frame`(x@data, i, j, ..., drop = FALSE)

Reproducible example:

    coords.x1 coords.x2       Z
1    1803299   5786242 28.1757
2    1803297   5786242 30.6624
3    1803295   5786241 37.4547
4    1803293   5786241 39.6034
5    1803290   5786240 34.4702
6    1803288   5786239 38.8357
7    1803286   5786239 31.5278
8    1803284   5786239 20.4700
9    1803281   5786238 19.4517
10   1803279   5786238 24.8794
11   1803277   5786238 26.0178
12   1803274   5786238 30.4886
13   1803272   5786238 27.1075
14   1803270   5786238 27.6069
15   1803268   5786238 23.1940
16   1803268   5786238 10.2322
17   1803269   5786238  0.0000
18   1803270   5786238  0.0000
19   1803272   5786238  0.0000
20   1803274   5786238  0.0000

Can anyone help me resolve this issue or give some recommendations please?


texts:
How do you set a polygon layers transparency in DotSpatial?

I'm using vb.net in visual studio express 2013 and using a Dotspatial nugets package which has given me DotSpatial version 1.7.

Please see my code below in how i'm currently adding a new polygon shape to a dotspatial map control (mpMain), colouring it blue with a black outline.

shp = New Data.Shapefile
shp.FeatureType = Topology.FeatureType.Polygon
shp.Name = "CoveragePolygon"
shp.AddFeature(New DotSpatial.Topology.Polygon(m_coverCoords))
Dim mpl As DotSpatial.Controls.MapPolygonLayer
mpl = mpMain.Layers.Add(shp)
mpl.Symbolizer = New DotSpatial.Symbology.PolygonSymbolizer(Color.Blue, Color.Black)


texts:
My team is working on a python script that does various updating tasks to our streets file. A part we are getting stuck on is trying to update a field.

Currently we have a field FEDROUTE that is populated with federal, local, state route numbers. We want to loop through a list of federal route numbers and if the search cursor finds a number in the list, leave it alone, however if it finds a number that isn't within the federal route list, then delete the value in that field, leaving it blank.

Right now the script will run through the first value in the list but won't start over and go through the remaining values in the list.

The code we have written so far is:

import arcpy
import os
import StringIO
import datetime

Target_SDE_FC = r"C:\Users\craig\Desktop\10X_Testing_databases\SDE_TEST.gdb\RoadCenterline_test"
Source_Layer = r"C:\Users\craig\Desktop\10X_Testing_databases\SDE_TEST.gdb\RoadCenterline_sample"
SL_Layer = "CreateSource_Layer"
arcpy.DeleteFeatures_management(Target_SDE_FC)

print "Target_SDE_FC features deleted"

arcpy.MakeFeatureLayer_management(Source_Layer, SL_Layer, "", arcpy.env.scratchWorkspace)

fms = arcpy.FieldMappings()
fms.addTable(Target_SDE_FC)

#fedRts = ("75","441","41","301","27","21")
fedRts = ("21","27","301","41","441","75")

# Define the output layer for the append
arcpy.env.workspace = r"C:\Users\craig\Desktop\10X_Testing_databases\SDE_TEST.gdb"
outFC = "RoadCenterline_test"

# Try block to Append Feature Layer to the SDE (Test Data) with field mappings
try:
    arcpy.Append_management(SL_Layer,outFC,"NO_TEST",fms)
#    test_output.close()
finally:
#    outFC.close()
    print "append finished from try loop"

#arcpy.env.workspace = r"C:\Users\craig\Desktop\10X_Testing_databases\SDE_TEST.gdb"
#sde = "RoadCenterline_test"

print "start cursor"

#create update cursors to delete the records not needed in Federal, State, and County Routes
try:
    for i in (fedRts):
        print "reading a new i value"
        with arcpy.da.UpdateCursor(outFC, "FEDROUTE") as fCursor:
            for record in fCursor:
                print "start cursor"
                if record == i:
                    print "record is not i"
                    break
                elif record == "":
                    print "record is blank"
                    break
                else:
                    print "read a new record from cursor for same i"
            fCursor.deleteRow()
        break

finally:
    del record
    del fCursor
    del SL_Layer
    print "script finished"

@JasonScheirer’s answer helped clean up our code considerably. To achieve what we wanted to do we wound up with:

import os
import arcpy

fedRts = ("21","27","301","41","441","75")
original_fc = r"C:\Users\craig\Desktop\10X_Testing_databases\SDE_TEST.gdb\RoadCenterline_sample"
Target_SDE_FC = r"C:\Users\craig\Desktop\10X_Testing_databases\SDE_TEST.gdb\RoadCenterline_test"

arcpy.Append_management(original_fc, Target_SDE_FC, "NO_TEST")
newValue = ""

with arcpy.da.UpdateCursor(Target_SDE_FC, "FEDROUTE") as fCursor:
    for record in fCursor:
        print "start cursor"
        if record[0] not in fedRts:
            record[0] = newValue
            fCursor.updateRow(record)


texts: How access Google Maps through a proxy server

texts:
I'm on a private network where the user's machine only has access to the internal network. I need to make the user's machine access the Google maps api through a proxy server.
Anyone know if it's possible to use the Google API in this way?


texts: Extracting values starting at certain point using ArcGIS for Desktop?

texts:
I have a '2015 Temp' shapefile that tells me the temp_min and temp_max for the entire year at one site. I want to make a new file from this where I have the day where temp_min fell above 40 degrees and all the following days until the first day where temp_max is above 75. Essentially, I am trying to find the growing season for a crop. For example, March 3 was the first day it hit above 40 and July 7 was the first day it hit above 75. I want to extract March 3 - July 7.

I know I can use 'Select'. But as far as I understand it, this only gets me days where it's above 40 but not all days that follow the first day when it was above 40.

Is there a way to do this?

I am using ArcGIS 10.4 for Desktop with the Spatial Analyst extension enabled.


texts:
The road names are no longer showing on my Google Earth Pro. The only general layers available in the bottom left  panel are "primary Database " and "terrain".
I have tried turning Google Earth Pro on and off / tried removing a stack of folders in 'my places', checked my computer storage has free disc space, shut down the computer.
Can anyone help?


texts: Publish World topographic map to arcgis server

texts:
I need to publish esri World topographic map to arcgis server but I got this error
"Layer type is not supported" in the arcmap

Url to the original map
http://server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer


texts: Turn list of values into selection set query by copy and pasting?

texts: Is there a website or script online that allows you to copy and paste a large list of unique values in excel and turn this list into a selection set query for ArcMap?


texts: Error while connecting qgis with postgres?

texts:
sql="select long,lat from poidata.poi_ca from where city LIKE '%unnyvale'"
uri = QgsDataSourceURI()
uri.setConnection("localhost","5432","gis_data","postgres","vajja")
uri.setDataSource("",sql,"long","","lat")
vlayer =QgsVectorLayer(uri.uri(),"LayerName","postgres")
QgsMapLayerRegistry.instance().addMapLayer(vlayer)

  Error: Unable to access the "select long,lat from poidata.poi_ca from
  where city LIKE '%unnyvale'" relation. The error message from the
  database was: ERROR: relation "select long,lat from poidata.poi_ca
  from where city LIKE '%unny" does not exist LINE 1: SELECT * FROM
  "select long,lat from poidata.poi_ca from wher... ^ . SQL: SELECT *
  FROM "select long,lat from poidata.poi_ca from where city LIKE
  '%unnyvale'"

Sources:

https://georepublic.info/en/blog/2013/joining-tables-with-sql-using-pyqgis/
http://docs.qgis.org/2.8/en/docs/pyqgis_developer_cookbook/loadlayer.html

I tried both the above from different source but still I get an error


texts: gdalbuildvrt error when mosaicking SRTM data with different NoData values?

texts:
I'm attempting to mosaic together 9 SRTM tiles downloaded from CGIAR to produce a DEM of Borneo. I'm using:

gdalbuildvrt Borneo.vrt BorneoSRTM/*.tif

where BorneoSRTM contains the 9 tif files to be combined. The command runs without error, however the resulting DEM looks like the below image and all the elevations are less than 13m (some of the input files have elevations close to 4000 m).

Clearly there's a problem with the tile corresponding to the big white square (5-10N, 110-115E). Looking at the original tif files and I've noticed that NoData is 255 for the problem tile and -32768 for all others. I tried changing NoData to -32768 using:

gdal_translate -a_nodata -32768  srtm_59_11.tif  out.tif

but this didn't solve the problem.

Calling gdalinfo on the problem tile gives:

Driver: GTiff/GeoTIFF
Files: srtm_59_11.tif
       srtm_59_11.tfw
Size is 6001, 6001
Coordinate System is:
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"]]
Origin = (109.999583817610983,10.000416763514124)
Pixel Size = (0.000833333333333,-0.000833333333333)
Metadata:
  AREA_OR_POINT=Area
Image Structure Metadata:
  INTERLEAVE=BAND
Corner Coordinates:
Upper Left  ( 109.9995838,  10.0004168)
Lower Left  ( 109.9995838,   4.9995834)
Upper Right ( 115.0004172,  10.0004168)
Lower Right ( 115.0004172,   4.9995834)
Center      ( 112.5000005,   7.5000001)
Band 1 Block=6001x1 Type=Int16, ColorInterp=Gray
  NoData Value=255

And, calling it on another tile gives:

Driver: GTiff/GeoTIFF
Files: srtm_59_12.tif
       srtm_59_12.tfw
Size is 6001, 6001
Coordinate System is:
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"]]
Origin = (109.999583817610983,5.000416642442191)
Pixel Size = (0.000833333333333,-0.000833333333333)
Metadata:
  AREA_OR_POINT=Area
Image Structure Metadata:
  INTERLEAVE=BAND
Corner Coordinates:
Upper Left  ( 109.9995838,   5.0004166)
Lower Left  ( 109.9995838,  -0.0004167)
Upper Right ( 115.0004172,   5.0004166)
Lower Right ( 115.0004172,  -0.0004167)
Center      ( 112.5000005,   2.5000000)
Band 1 Block=6001x1 Type=Int16, ColorInterp=Gray
  NoData Value=-32768

When I call gdalbuildvrt without this problem tile, everything works fine. I realize that this tile only includes a tiny piece of Borneo, but if possible I'd like to figure out a way to include it.


texts:
I have a QgsCategorizedSymbolRenderer and I'm trying to configure it so that symbol_a:

appears at the top of the layers window legend, but also
appears on top of all other QgsRendererCategory symbols (i.e. it should be rendered last).

In QGIS, I can do this by going to Symbology > Advanced > Symbol Levels, checking Enable symbol levels and configuring the Layer 0 for Label A to 1, leaving the others at 0.
Using PyQGIS, I can enable symbol levels, but can't find a way to change the specific symbol levels (i.e. the order they are rendered).  Re-ordering the categories achieves this, but I'd prefer Label A to appear first in the layers window.  Is this possible?
My existing code looks something like this:
categories = [
    QgsRendererCategory('value_a', symbol_a, 'Label A'),
    QgsRendererCategory('value_b', symbol_b, 'Label B'),
    QgsRendererCategory('value_c', symbol_c, 'Label C'),
]

renderer = QgsCategorizedSymbolRenderer('field_name', categories)
renderer.setUsingSymbolLevels(True)


texts: When we create a CartoDB table using SQL, is there a way to register it with the tables dashboard?

texts:
I have been able to create tables that conform to the CartoDB style by the following method:

Create empty table [table name], no columns via SQL API
SELECT CDB_Cartodbyfy([table name]) via SQL API
Insert [table name] and current time into CDB_TableMetadata
Add user columns and data via SQL API

I can even get the table to show up on the CartoDB tables dashboard, by creating an empty table and then renaming it to [table name]. However, what I really want is a way to make my programmatically-created tables appear on the dashboard without having to manually interact with the CartoDB web app.

I suspect I could make this happen by posting to the Imports API with table_name=[new table name]&table_copy=[table name]. However, using the table_copy parameter is forbidden, and I do not wish to violate that.

So, my question is this: Is there a way to accomplish what I want (programmatic registration of existing tables) without violating the rules of CartoDB's APIs?


texts: Seeking free public LIDAR data of road in LAS format?

texts:
I am currently working on LiDAR point cloud road marking extraction.

Please help me to get relevant public dataset in LAS format?
Sample data is as shown in the image below:
Data without original colour is also acceptable.

I am currently working on sample data provided by private organisation.


texts: Combine two rasters- only value 1 stays; zeros converted to NoData cells

texts:
I am trying to combine 2 rasters: one with values = 1 and the other with values = 0 because I need a final raster with no empty cells.
When I use the Raster calculator, the resulting raster only retains the cells with value = 1. It ignores cells with value=0 so therefore I now have a new raster with many No Data cells.
How do I combine these 2 rasters and maintain both value = 1 and value =0, preferring value =1.
Using ArcGIS 10.2.2


texts: PostgreSQL is loading wrong PostGIS library

texts:
I am attempting to upgrade my version of PostgreSQL (from 9.2 to 9.6) on a Mac running 10.13.5.

I used pg_dumpall to backup the 9.2 database as per the instructions in the postgres documentation stopped the 9.2 instance and started the 9.6 one and then piped the backup file into the 9.6 version of psql.

As soon as it comes to create the tables I get these errors:

CREATE TYPE
psql:/Library/PostgreSQL/backups/9.2.3-dumpall:250: ERROR:  incompatible library "/Library/PostgreSQL/9.2/lib/postgis-2.0.so": version mismatch
DETAIL:  Server is version 9.6, library is version 9.2.

I have tried reinstalling a couple of times without making any difference.

I can't figure out why the loader is loading the 9.2 library instead of the 9.6.   I have tried adding LD_LIBRARY_PATH to the environment but it made no difference.


texts: Passing reclassification values to the Reclassify tool in Model Builder in ArcGIS 10

texts: There is a set of point features that fall within polygon features, and I want these polygon features (after converting them to raster) reclassified based on how many point features fall in them. If the reclassification method, the number of classes, and the new values remain constant, is there any way of passing these to the Reclassify tool every time I run the model?


texts:
I have network analyst installed as an extension in my arcGIS 9.3, but it just does not work!!! when I go to ArcCatalog, the option of new network data set also does not appear... :( I have to do this job of finding routes & I need this to work. I am zero at programming & I don't have arc server as well.

Thanks


texts:
I have a PostGIS database with all of my spatial layers, which have then been loaded into Geoserver, styled with SLD's and put into Layer Groups.

The layer preview function in Geoserver is a bit minimalist though; my aim is to have a nice pretty browser map that other people in my office can use for simple viewing and querying, with tiled basemaps overlaid with WMS layers that can be turned on and off.

This is where I'm stuck...what program do I need to create the proper professional web maps? Geoserver doesn't have the best map interface, from my understanding its more of a server that another web mapping client program reads from? I have pretty minimal scripting experience but I'm willing to learn Javascript or HTML or whatnot.


texts: QGIS Buffer with MMQGIS and GSHHS: strange lines

texts:
I want to calculate a buffer around the worlds coastlines. To do so, I downloaded the GSHHS data version 2.3.7, imported it into qgis, used "polygons to lines" and then the MMQGIS Plugin to produce a 50 km buffer. It produces the buffer, but also a buffer around strange horizontal lines (see image). Also Europe and Asia shouldn't be filled.
I also see these lines when I use the buffer from the Geoprocessing tools, but they disappear when I'm zooming in. Do you have an idea what the problem might be?
I'm using MacOS 10.13.2 and QGis 2.18.15.

Buffer with strange lines:

GSHHS dataset: polygons:

GSHHS dataset: polygons to lines:


texts:
My goal is to add CZML to my ol-cesium application.

I have created an application using the ol-cesium-v1.27 get started instructions:

                ol3d = new olcs.OLCesium({map: map}); // map is the ol.Map instance

I have added 3D terrain and a glTF model to my application as such:

                var scene = ol3d.getCesiumScene();
                scene.terrainProvider = new Cesium.CesiumTerrainProvider({
                    url: 'https://my.terrain',
                    requestWaterMask: true
                });
                var modelMatrix = Cesium.Transforms.eastNorthUpToFixedFrame(
                        Cesium.Cartesian3.fromDegrees(-3, 54, 0));
                var model = scene.primitives.add(Cesium.Model.fromGltf({
                    url: '/model.glb',
                    modelMatrix: modelMatrix,
                    heightReference : Cesium.HeightReference.CLAMP_TO_GROUND,
                    scene: scene
                }));

Now I would like to add a CZML solid to the globe. The Cesium example from the Sandcastle (CZML Sandcastle) looks like this:

    var czml = [{
    "id" : "document",
    "name" : "CZML Geometries: Cones and Cylinders",
    "version" : "1.0"
}, {
    "id" : "shape1",
    "name" : "Green cylinder with black outline",
    "position" : {
        "cartographicDegrees" : [-100.0, 40.0, 200000.0]
    },
    "cylinder" : {
        "length" : 400000.0,
        "topRadius" : 200000.0,
        "bottomRadius" : 200000.0,
        "material" : {
            "solidColor" : {
                "color" : {
                    "rgba" : [0, 255, 0, 128]
                }
            }
        },
        "outline" : true,
        "outlineColor" : {
            "rgba" : [0, 0, 0, 255]
        }
    }
}, {
    "id" : "shape2",
    "name" : "Red cone",
    "position" : {
        "cartographicDegrees" : [-105.0, 40.0, 200000.0]
    },
    "cylinder" : {
        "length" : 400000.0,
        "topRadius" : 0.0,
        "bottomRadius" : 200000.0,
        "material" : {
            "solidColor" : {
                "color" : {
                    "rgba" : [255, 0, 0, 255]
                }
            }
        }
    }
}];

var viewer = new Cesium.Viewer('cesiumContainer');
var dataSourcePromise = Cesium.CzmlDataSource.load(czml);
viewer.dataSources.add(dataSourcePromise);

How do I (Can I) apply that CZML example to my ol-cesium application without using the Cesium.Viewer.

Do I need to (Can I) create my application in that "Viewer" manner?

Or can I use my current method using "Scenes" to add the CZML?


texts: How to delete groups of grid files based on pixel cluster size (under 10)?

texts:
I am new to QGIS, and I am currently using flood modeller to produce a series of surface water maps. Once the data is ran, I get a series of 10m2 grid tiles with varying Z flood Values. We are only intersted in clusters of tiles that intersect to be over 100m2 big collectivley, meaning any tile that isn't in a group of 10 needs to be taken out for the purpose of mapping. As the files are quite large, they result in many small clusters and single grid squares. Is there a way I can group edit these tiles out to save time, instead of manually selecting them?
Edit - Below (Hopefully) is an example of the clusters, those that intersect to complete 10+ files are the ones that I want to keep.

Edit (2) - Thank you everybody for your help. Below is another issue I am having which I hope you can advise on. The data in green is being left out of the cleaning, whilst the brown are being cleared. The diagonal brown line of grid squares represents a watercourse which needs to remain in the study as collectively, it is a cluster of over 10 squares and whilst I recognise that, the values are being included in the cleaning process (I believe this is because they don't intersect?). Is there a way to include these diagonal values as a collective when calculating area, so that they are left in, or is this something I will have to do manually.


texts: Autodesk Infrastructure Studio - Enable WMS

texts:
With only a couple hours experience this is very likely user error but I have "Autodesk Infrastucture Studio 2013" installed with a few "Data" nodes and "Layers" nodes.  I can right-click a child of the "Data" node and select "Enable WFS..." and it gets added to my WFS service BUT I when I right-click a child of the "Layers" node I do not have the corresponding "Enable WMS" layers.  Neither is the Enable WMS/WFS toolbar item enabled.

Any thoughts on what might be causing of "Enable WMS" not getting enabled?


texts:
Background:
Display topographic plans of a specific size (1500 meters x 1500 meters). The source images of tiles can be of different sizes and resolutions. It is required to display on the plan some objects tied to their own proprietary coordinate system.

Problem:
Display the map tiles turned out. How can I attach my own coordinate system to an existing map?
I tried several solutions (for example, CRS.Simple, rastercoords), but, unfortunately, nothing came of it for various reasons: the tile display was spoiled, or it was not possible to bind proprietary coordinates.

const IMAGE_SIZES = [img_width, img_height];
const MAX_ZOOM = 1;
const MIN_ZOOM = 5;
const INITIAL_ZOOM = 3;

let map = map('map', {
    crs: L.CRS.Simple,
    minZoom: MIN_ZOOM,
    maxZoom: MAX_ZOOM,

});
map.setView([0, 0], INITIAL_ZOOM);

L.tileLayer('example.com/plan_id/{z}/{x}/{y}.png', {
  noWrap: true
}).addTo(map)

Maybe
I did something wrong, please tell me how I can do this. Below is an example of a grid

For example, if I have a scanned plan (in the image, the area is highlighted in yellow). It is cut into tiles, it is already displayed with zooming with loading tiles. How can I now snap to the image a coordinate grid similar to the one in the picture?


texts: How do I set up a PostgreSQL database for use with PostGIS and GeoDjango?

texts:
The Django docs say to use
createdb -T template_postgis geodjango

but I already have a database set up. While trying to find out what this actually does and a way to apply it to an existing database, I found this on postgis.net:
-- Enable PostGIS (includes raster)
CREATE EXTENSION postgis;
-- Enable Topology
CREATE EXTENSION postgis_topology;
-- fuzzy matching needed for Tiger
CREATE EXTENSION fuzzystrmatch;
-- Enable US Tiger Geocoder
CREATE EXTENSION postgis_tiger_geocoder;

In trying to figure out what Tiger is, I found this in the postgis docs:
psql -d [yourdatabase] -c "CREATE EXTENSION postgis;"
Topology is packaged as a separate extension and installable with command:
psql -d [yourdatabase] -c "CREATE EXTENSION postgis_topology;"

How do I ready my current Django database for use with PostGIS and GeoDjango?
I'm using Django 1.8 and PostgreSQL 9.4.


texts:
While having not used filtering that much in OpenLayers, we are discussing which type of filtering we should use: The OGC XML filter or the more simple CQL filter?

Are one of them more appropriate than the other?
What about support from various frameworks and servers - what kind of trouble will we encounter?

We are using GeoServer 2.x and OpenLayers 2.9.x, but we are also querying external servers for data.


texts: Extracting the current feature in QGIS modeler iteration

texts:
I have a model that stopped working in the last few versions of QGIS 3.x. It worked fine in the past but now there seems to be an issue with the first step. Basically, the model is supposed to be iterated over the input polygon layer (it is the right input type for iteration).
Last year when I built it, the Extract by expression tool was able to output the feature concerned by each iteration using $currentfeature as the expression. From there, the rest of the tree would be processed according to that one extracted feature, then the model would repeat for the next feature in the input layer. In the end I'd a point for every highest value in each polygon.
This doesn't work anymore and it seems, from my testing, that nothing is extracted using $currentfeature. I'm wondering if I missed some changes to the modeler or the tool itself.


texts:
New to mapping tech.

Requirements:

Stand Alone Server for offline use (will be an internal app) - No Mobile.
Ability to add custom CSS class and hover information to US counties
Programmatically interact with map

When user hovers over zip code, zoom into and highlight county on map

I saw TileMill and TileStream, but TileStream doesn't work with Node 0.6+ like TileMill.

Can someone point me to the right direction?

EDIT

Goal is something similar to: http://polymaps.org/ex/population.html


texts: Dissolving polygon with enclave does not work

texts:
i tried to dissolve two polygons(brown and the yellow marked polygons) of one layer that own some en-/exclaves in QGIS (first union both, then dissolve the union-polygon).

But dissolving dose not work :(. I don't get an error but it dissolved only one polygon an the other one is not included.
There are also other polygons without enclaves and it works perfect.

The data I used is opendata (http://www.geodatenzentrum.de/geodaten/gdz_rahmen.gdz_div?gdz_spr=deu&gdz_akt_zeile=5&gdz_anz_zeile=1&gdz_unt_zeile=13&gdz_user_id=0, -> UTM32, Ebenen, ArcInfo-SHAPE). The polygons are NUTS DE124 and DE128 from file vg250_KRS.

Is there any way to dissolve these enclave-polygons with those other "normal" polygons in QGIS (I also tried the editor but it does not help)?


texts: Render points (spheres) at certain height (trees) in QGIS 3.0 3D View

texts:
I succesfully rendered 3D View of Vienna city centre as shown in this tutorial by underdark . I download trees point data in GeoJSON from OSM using Overpass API. Now I want to render the points as spheres that are elevated above the surface. However, I cannot find where in QGIS 3D Renderer settings can I define the height of the sphere. See screenshot provided.

I looked thru GIS Stack Exchange, Lutra Consulting webpage, Twitter feeds and other tutorials but I cannot find any answer. Anyone knows how to elevate the sphrere about ground?


texts: Are there qgis equivalent to Cogo tools of ArcView 3.2

texts: We are  transistioning to Qgis, i have GIS users that currently use ArcView 3.2 (yes there are still people using this) they find the cogo tools very useful and I was wondering if there is an equivalent tool in QGIS 1.8?


texts:
Can anyone tell me how to change the labels in a legend created by spplot in R?  It is a typical vertical ribbon legend automatically generated by spplot. Based on color, it is labelled 1-7 but I would like to label it 1%-7% and make the labels larger.

I understand that the graphics are based on lattice but it is still difficult to find anywhere how to do what, I would think, would be fairly straight forward.

The code I have is

plot2 <- spplot(mymap, "percentage", col.regions = plotclr,
                     at = round(class$brks, digits=1) )

where: mymap is a typical shape file with an attributes column called percentage which pertains to certain map regions; plotclr is my vector of colors, class$brks are the divisions of the percentages to which the colors correspond.  The code works fine. I just can't change the legend labeling.


texts:
I am working on a project which has a functionality of downloading WMS tiles. The program checks for the newest radar images, but the problem is that the radar images are not ready and the tiles are generated and cached blank.
Is there a way to disable caching of tiles through GET requests? Note that i do not have the access to the GeoWebCache server.


texts: How to compute distance between 4500 points fast?

texts: I am working on a location problem with 150 customers (points) and 30 facilities (points). I have determined the location of any customer and facility by google earth and then saved them in a KMZ file. I need to compute the distance between any pair of customers and facilities. So I should compute 150*30=4500 values by ruler tool in Google Earth. Is there any other way to obtain these values faster and easier? Even by converting the KMZ file to a layer in ArcGIS 10?


texts: Change the ArcMap background from white to blue (i.e the sea)

texts: Say I have an image like the map below, how can I change the white to blue, to represent that this is the ocean? It is not part of the shapefile itself, so I cannot use symbology.


texts: Can a MapServer datasource be a materialized view?

texts: I'd like to find out if there is a way that a datasource in MapServer can be a materialized view, this is due to the presence of indexes, these cannot be in views but only in materialized view - however, I seem to have trouble having MapServer accept materialized view as a datasource.


texts: R-4.0.1 Not sure I understand this message: Warning message: In proj4string(x) : CRS object has comment, which is lost in output

texts:
Context: I want to store the TIFF data to use it for running a linear regression model later on.
Ultimate goal: Create a carbon map using field data as a basis.
Libraries:
library(sp)
library(raster)
library(tidyverse)
library(rgdal)

plotcoord <- SpatialPointsDataFrame(AGCplot[,3:4], AGCplot[,1:2],proj4string=CRS('+proj=longlat'))
pspcoord<-spTransform(plotcoord, CRS('+proj=utm +zone=21')) #Omzetten naar UTM21N (= S1)
plot(pspcoord)

s1 <- stack('Some.tif')

colnamen = c("plotid","AGC","B2","B3","B4","B5","B6","B7","B8","B8A","B11","B12","NDVI","NDWI","MMRI","IRECI","MASI","VV","VH")

s1_e <- extract(s1,pspcoord,method='bilinear')

Upon extraction I get the following message:
Warning message:
In proj4string(x) : CRS object has comment, which is lost in output


texts: Can Spatial Analyst extension be used with ArcGIS Server Standard?

texts:
I have a model written in ModelBuilder that uses a number of tools in Spatial Analyst extension, e.g. Raster Calculator and Focal Statistics, etc.

It runs perfectly with ArcMap. Can I publish it on ArcGIS Server Standard as Geoprocessing service and trigger it from there?

I am with 10.1. Having read the matrix, I found it stated ArcGIS Server Standard only supports Schematic and Network Analysts.

Do I have to run my Model off ArcGIS Server Advanced?


texts: Finding documentation for arcpy.gp functions?

texts:
I'm learning ArcPy and trying to export models to Python scripts to get a feel for it. I have a model that generalizes a land cover raster by reclassifying and using some other spatial analyst tools (boundary clean, region group, extract by attributes, and nibble). When I export my model each function is under arcpy.gp, e.g.:

arcpy.gp.Reclassify_sa(...)
arcpy.gp.BoundaryClean_sa(...)
arcpy.gp.RegionGroup_sa(...)

And so on. I gather this means "Use the geoprocessing tool Reclassify from the Spatial Analyst extension" but I can't find any documentation for it. I can find arcpy.sa.Reclassify but not the arcpy.gp version. Does anyone know where to look?


texts: Calculating built-up density for each cell in vector grid in QGIS?

texts:
I have two layers: a raster of India showing built-up areas (black pixels represent built areas) and a vector grid overlaying it.

My goal is to calculate the percentage of built-up surface in each vector grid cell so as to better understand the urban density of certain regions (e.g some grid cells are 14% built-up, others 30% etc.)

Other posts seem to suggest using zonal statistics, but this only provides calculations such as count, sum or min/max. Also having a hard time turning raster layer into vector as it is much too large (entire country of India).


texts: Eliminating duplicates only if data is the same according to attributes

texts:
Having duplications in the data is quite natural and removing them is quite hard if we didn't have the same attributes.
In QGIS there are tools to eliminate the duplications but only if the data is the same according to the attributes. What tool can I use to identify duplicates at a specific distance? The data type is Point shapefile.


texts: Measure several line segments as one in ArcGIS

texts: I have a polyline shapefile which is divided into more than 56 pieces and I want to measure the length of the whole line as one line.


texts: Way to make equal-population areas of world using administrative divisions?

texts: I am trying to make a map, that aims to divide the world into areas each with an equal population. I've found things like Dave's Redistricting for individual US states, but nothing for the entire world. Mapchart has something similar, but nowhere near as detailed as it needs to be and no population data. Is there any way to use population estimates of second or third level administrative divisions for every country, and make equal areas of, say, 1,000,000 people per division? It doesn't have to be accurate.


texts: What is the advantage of Mapbox-gl native vs. javascript on mobile devices?

texts: Mapbox-gl renders maps from vector tiles locally on the clients device. You can either use the js library or use the native c++ bindings (for ios/android/etc.) For a mobile device, what would be the practical advantages of using the native bindings? The javascript library seems much simpler.


texts: How to compare feature sets with different field names?

texts:
I am trying to compare the fields of 2 feature layers to each other. The fields, though, have different names. I think this image shows this a little better:

I am lost as to how this can be accomplished. I am trying to compare modified's FIELD2 to baseline's FIELD1, etc.

While I am sure that I will need arcpy.FieldMappings, I wrote these few lines:

baseline_copy_path = os.path.join(self.tempPath ,"baseline_copy.shp")
fieldmappings = arcpy.FieldMappings()
fieldmappings.addTable(self.revisedFile)
fieldmappings.addTable(baseline_copy_path)

At this point, I am unsure how to proceed.

I am looking for help in finding example code doing this or somebody who might outline how to proceed. At the end of the comparison, I am looking to produce a DEFeatureClass for each of these: new features in the modified file, deletions, overlapping features, changed attributes in modified fiel and finally, removed features. The changes I am looking for are in the geometries.


texts: I have routes for the days of week (i.e. Monday rt1, rt2, rt3; Tuesday rt1, rt2, rt3; etc). I want to publish to ArcGIS online so that the user can look at all the Monday routes, for example, and click off or on all all the other routes for the rest of the week. I then also want the user to be able to turn off or on certain routes for the day of interest. The easiest way to do this would be to make group layers but ArcGIS Online doesn't support this. Should I publish each day of routes as it's own service and then add these services to a web map? Seems like there'd be a better way.


texts:
I encountered a very odd result while reprojecting simplefeatures with Geotools:
I have data of Vienna (Austria) from Open Street Maps in SRID:4326 (WGS84) in a shapefile. I load the data  into a DefaultFeatureCollection. I then perform a reprojection into SRID 3035 by loading the Data from the DeafultFeatureCollection into a ReprojectingFeatureCollection:

ReprojectingFeatureCollection reprojFeatures = new ReprojectingFeatureCollection(wienfeatures,CRS.decode("EPSG:4326"),CRS.decode("EPSG:3035"));

I was very suprised to find that the resulting geodata was now located in North America, after reprojection:

I tried to maintain the SRID in order to make sure no failure was created while exporting the shape:

ReprojectingFeatureCollection(wienfeatures,CRS.decode("EPSG:4326"),CRS.decode("EPSG:4326"));

The resulting shape is identical to the input, as expected:

I finally tried to transform the features in a own function which takes the SRID and the SimpleFeatureCollection as an input:

public static SimpleFeatureCollection transform(Integer targetSRID, SimpleFeatureCollection source) throws NoSuchAuthorityCodeException, FactoryException, MismatchedDimensionException, TransformException
    {
        SimpleFeatureType schema = source.getSchema();

        CoordinateReferenceSystem dataCRS   = schema.getCoordinateReferenceSystem();
        CoordinateReferenceSystem targetCRS = CRS.decode("EPSG:"+targetSRID.toString());
        boolean lenient         = false; // allow for some error due to different datums
        MathTransform transform = CRS.findMathTransform(dataCRS, targetCRS, lenient);

        //Create new featuretype
        SimpleFeatureType newfeatureType = SimpleFeatureTypeBuilder.retype(schema, targetCRS);
        // create a builder for it...
        SimpleFeatureBuilder featurebuilder = new SimpleFeatureBuilder(newfeatureType);

        SimpleFeatureIterator featiter = source.features();
        DefaultFeatureCollection projcollection = new DefaultFeatureCollection();

        while(featiter.hasNext())
        {
            SimpleFeature feature               = featiter.next();
            Geometry geometry                   = (Geometry) feature.getDefaultGeometry();
            Geometry geometry2                  = JTS.transform(geometry, transform);

            featurebuilder.addAll(feature.getAttributes());
            SimpleFeature projfeature = featurebuilder.buildFeature(null);
            projfeature.setDefaultGeometry(geometry2);

            //add SimpleFeature to final collection...
            projcollection.add(projfeature);
        }
        featiter.close();
        return projcollection;
    }

However, this gave me exactly the same erroneous results like in the beginning.
What is the problem here? Could it be that Geotools has an issue transforming??

P.S.: I tried to project my input data with QGIS... there were no problems...


texts: Modelling soil texture using ArcGIS for Desktop?

texts:
I am doing a project for automated soil mapping using landsat TM imagery,
I have 3 output rasters: one for sand percentage one for silt percentage and a third for clay percentage.

How can I incorporate these three rasters to get an output raster where pixels are classified on the basis of percent silt sand and clay according to USDA soil textural triangle?

I want my model to symbolize it on the go, for example green represents silty loam in my map etc.

I am using ArcGIS 10.2 and want to do the work in a form of model.


texts: Using ArcPy to create Graduated Colours?

texts:
To preface this, I am using ArcMap 10.4.1, and currently new in using Arcpy and coding in general, so I am struggling on how to make my layer go from just simple point data, into graduated colour point data. The point data is just locations of cities and this point data was joined by a table that includes the city names too and additional information such as Age.

I am trying to automate this process, but I am unsure of what the coding sequence to actually turn the point data to a Graduated Colours symbology. Manually, I have no issues, but that is something I am trying to avoid. I've done some reading on this, but if I interepreted right         arcpy.ApplySymbologyFromLayer_management is using a layer to create a symbology for another layer, not necessarily referring to graduated colours? I currently have this for my code which I used some code from other questions asked when I was searching for my answer. I may have found it already, but I may be interpreting things wrong.

import arcpy
from arcpy import env
env.workspace = "K:\GEOG 3P95\Final_proj\Workspace"
# get's the map document
mxd = arcpy.mapping.MapDocument("CURRENT")
#get the data frame(s)
df = arcpy.mapping.ListDataFrames(mxd,"*")[0]

# create a new layer and adds them on Top or Bottom
lake = arcpy.mapping.Layer("K:\GEOG 3P95\Final_proj\Workspace\ghy_000e06a_e.shp")
arcpy.mapping.AddLayer(df, lake,"TOP")

municipal = arcpy.mapping.Layer("K:\GEOG 3P95\Final_proj\Workspace\BOUND_05.shp")
arcpy.mapping.AddLayer(df, municipal,"BOTTOM")

city = arcpy.mapping.Layer("K:\GEOG 3P95\Final_proj\Workspace\Final_export_all_data.shp")
arcpy.mapping.AddLayer(df, city,"TOP")

municipal = "BOUND_05"
city = "ONppn"
lake = "ghy_000e06a_e"
province = "province"

#Changes coordinate systems for the Municpal, Lake, Province and City Point layers, respectively.
coord_system = arcpy.SpatialReference('NAD 1983 UTM Zone 17N')
arcpy.Project_management("BOUND_05","BOUND_05_1983",coord_system)
arcpy.Project_management("ghy_000e06a_e","lake_1983",coord_system)
arcpy.Project_management("province","province_1983",coord_system)
arcpy.Project_management("Final_export_all_data","City_1983",coord_system)


texts: Importing shp file into GRASS - syntax error?

texts:
I'm just starting out learning GRASS. I am trying to import my first shapefile, and I'm getting an error message:

  ERROR: Unable to open data source

I think I'm just not entering the syntax correctly and that's where the problem is, although I suppose it might be something with the file. The file is located here on my computer: D:\Data\GRASSData\NhoodAssoc\Associations.shp.

Here are the instructions on importing I'm following: https://grasswiki.osgeo.org/wiki/Tips_for_Arc_users#Import_of_Shapefiles_into_GRASS.

Under 'Import of Shapefiles into GRASS' it appears that I should be able to just enter in "v.in.ogr input=associations.shp output=associations." ["input" appears to be the current syntax instead of "dsn" listed in the instructions]. But I get that error when I do.

I've also tried to use the file structure, although I'm not sure how to enter that into the suggested syntax - for example, do I need to start with "D" since that's the drive it's on?

Any idea why I'm getting this error and what I can do to fix it?


texts: Making an ArcGIS Online Presentation won't let add shapes because they are more than 10,000 features

texts:
How can I add a shape that has more than 10,000 features to make a map in Online ArcGIS?

Since it is only to show a sample of the work that has been achieved I could cut out information but I don't know how to reduce it to less than 10,000 features.

What I have mapped are census tract areas and food outlets.

I reduced the features by using shapes at the city level instead of the country level but still it is too much information to display.

Any ideas?


texts: Can I control what field comes up first in the Identify Results window in QGIS?

texts:
My shapefile has 20 fields in the attribute table.

When I click "Identify results", the third text field (Welsh_Name) comes up first. Is it possible to change which field comes up first (at the top of the tree)? I would prefer to use the field "Scientific" (which as it happens is the first after ID) but it could be useful to use "Common_Nam" as well. I don't understand why this (apparently random) field has been selected to appear here.


texts: Attach the bar's bottom to a location in 3D Cesium

texts:
I have the code below on web site cesiumjs.

Is there any way that I can fix the bar's bottom at the location (37.786805,-122.45475) on the Earth's surface?  The bar here looks like its bottom moves to different location when user changes the view point with mouse. I would like its bottom is fixed at the location showed in the picture:

Link to cesiumjs.org and code

var viewer = new Cesium.Viewer('cesiumContainer');

var data = {"data": [{'cell': 'CCL00001', 'lat': 37.7868056, 'lng': -122.45475,
                        'Instagram': 4875.9842197545295,
                        'Twitter': 12549.83683767872,
                        'Facebook': 14216.538636363637,
                        'Netflix': 134291.15366972476,
                        'Google': 172588.27142857143,
                        'Other': 202959.5143769968
                    },
                    {'cell': 'CCL00005', 'lat': 37.7298061, 'lng': -122.4738231,
                        'Instagram': 2501.451010587103,
                        'Twitter': 14455.444364809175,
                        'Facebook': 120458.94586894587,
                        'Netflix': 114198.37105171815,
                        'Google': 167619.12919343327,
                        'Other': 119965.0
                    }

                ]};
            var colors = {
                /*'Instagram': Cesium.Color.WHITE, //'brown',
                'Twitter': Cesium.Color.GREEN, //'yellow',
                'Facebook': Cesium.Color.YELLOW, //'red',
                'Netflix': Cesium.Color.BLUEVIOLET,*/
                'Google': Cesium.Color.BLUE, //'blue',
                'Other': Cesium.Color.RED//'black'
            };
            for (var i =0; i<1; i++) {
                console.log(i);
                console.log()
                var alt = -20000;
                for (var cp in colors) {
                    console.log(cp);
                    var height = data.data[i][cp]/10;
                    console.log("height: " + height)
                    alt += height ;
                    console.log("alt: " +alt);
                    var cell = data.data[i];
                    console.log(cell.lat);

                    var blueBox = viewer.entities.add({
                        name: cp,
                        position: Cesium.Cartesian3.fromDegrees(cell.lng, cell.lat, alt),
                        box: {
                            dimensions: new Cesium.Cartesian3(4000/5.0, 3000.0/5, height),
                            material: colors[cp]
                        }
                    });
                }
            }

            /*var outlineOnly = viewer.entities.add({
             name : 'Yellow box outline',
             position: Cesium.Cartesian3.fromDegrees(-100.0, 40.0, 300000.0),
             box : {
             dimensions : new Cesium.Cartesian3(400000.0, 300000.0, 500000.0),
             fill : false,
             outline : true,
             outlineColor : Cesium.Color.YELLOW
             }
             });*/

            viewer.zoomTo(viewer.entities);


texts:
My goal is to run QGIS processing algorithms using a python script on an ubuntu server.

I have installed QGIS on the server using

 $ sudo apt-add-repository ppa:ubuntugis/ubuntugis-unstable
 $ sudo apt-get update
 $ sudo apt-get install qgis

from this answer to Installing QGIS on Ubuntu.
The install was successful.

I have tried importing qgis.core but I get the module not found error.

I think I need to add some lines to the PYTHONPATH variable based on other answers. I've added the following:

:/usr/lib/qgis/plugins/:/usr/lib/qgis/plugins:/usr/lib/qgis:/usr/share/qgis/python:/usr/share/qgis/python/plugins:/home/wporter/.local/share/QGIS/QGIS3/profiles/default/python:/home/wporter/.local/share/QGIS/QGIS3/profiles/default/python/plugins:/usr/share/qgis/python:/usr/share/qgis/python/plugins:/usr/bin/qgis/share/qgis/python:/usr/share/qgis/python

But I'm still not able to import qgis.core.

How can I direct Python to the correct libraries on the Ubuntu server?


texts: labels showing up behind other labels due to unmatched z-index

texts:
I am using leaflet label plugin to show labels on markers by using layer.bindLabel('name'). As the number of markers is high the markers come above the label thus labels are not visible clearly.

Seems marker and its label have same z-index. I tried changing the z-index of marker by .leaflet-marker-icon{ z-index: 1000;} and also that of the label .lealet-label{z-index: 1001;} but still the result is the same and the z-index of marker is not changed either. What would be solution to this problem?


texts:
I need to optimize the routes of a collection vehicle working with QGIS.
To do this I have a network layer and another with the collection points, both of then in a geopackage.
What I need is a new layer with the optimized route with the segment ordered and the collection points ordered.
I have tried the v.net.salesman algorithm from GRASS GIS (manual), but it is designed to routes between cities and does not have any way to set the direction of traffic and does not return an ordered layer.
Does anyone know a way to do this?


texts: Get Cell Value Webservice for ArcGIS Raster (LiDAR) without using ArcGIS

texts:
I want to expose the getCellValue function on Lidar Data, as a web service. But I don't have access to ArcGIS (server or desktop).

What options do I have to fetch cell value, given lat lon, from a raster in ArcGIS format?

It would be great if someone can point me to some open source code/library that I can use to create a web service.  I am open to any other option except ArcGIS.

I know that Geoserver has a raster rendering feature: can it also find the cell value for a lat-long input?


texts: How can I check if a multipolygon can be represented as a simple polygon?

texts:
I have a large (30m+ records) spatial data set I have imported into a PostGIS database.  I did not expect to find multipolygons in the data set, but it does have a few of them.  I'd like to take a closer look at them to better understand the data I'm dealing with.  However, shp2pgsql indiscriminately imported everything as a multipolygon.

How can I efficiently query the dataset to filter out the multipolygons that are actually simple polygons?


texts: Having wrong CRS from graphical modeler output

texts:
I'm using graphical modeler to reclasify some rasters and then make another calculus, but when I try my model only with the first step (reclassify) I get an output with different crs of the input.
I'm using the r.recode function.

This is the crs of the input

This is the crs of the output

If someone can help me to fix that, I appreciated so much.
I tried using all the option in r.recode but never get the rigth crs.


texts: Add Google Earth imagery to Google Earth Engine project

texts:
I have the following code:

var s2 = ee.ImageCollection("COPERNICUS/S2")
  .filterDate('2018-03-15', '2018-09-15')
  .filterMetadata('MGRS_TILE','equals','34TFM')
  .filterBounds(ee.Geometry.Point(23.20, 41.88))
  //.filterBounds(ee.Geometry.Point(pin))

function addImage(image) { // display each image in collection
  var id = image.id
  var image = ee.Image(image.id)
  print(image)
  Map.addLayer(image, {bands: ['B8', 'B11', 'B4'], max: 5000}, 'S2')
}

s2.evaluate(function(s2) {  // use map on client-side
  s2.features.map(addImage)

})

To download a collection of Sentinel-2 images to a location in my project. However, I would like to add Google Earth imagery into my project. Is it possible?


texts: ArcGIS Python Add-In Assistant not updated for ca. 4 years

texts:
For some time I had not used ArcGIS and I getting myself acquainted with the newer versions. Last time I had used 10.1 and now I am using 10.4.1. I had created some simple Python add-ins with the help of the addin assistant.
Now, I started to create Python add-ins again and I am re-doing what I had done but with the newer version.

I find the documentation of the newer version of ArcMap still points to the same add-in assistant that I used 3 years ago. I did not find new functionalities despite the fact that making modifications to the addin was quite cumbersome in cases like adding buttons, renaming the classes, etc.

Is there any reason why this tool has not been updated?

Is there a new tool that I am not aware of perhaps?

Is this because of ArcGIS Pro?

Are Python add-ins not so much used now?

I read that Python is closing the gap with relation to ArcObjects, but making customizations with .Net still seems to me a better approach, am I wrong?


texts: Efficient random access into rasters for hydrological analysis

texts:
I'd like to implement an algorithm to extract Strahler Streams as geometric lines from a predefined stream raster. I've done this using GDAL by walking across the rasters from the outlets or at the peaks and walking upstream or downstream constructing geometry along the way.
However, I find when I encounter rasters that are too large to fit in RAM I incur cache thrashing penalties associated with the necessity of "randomly" walking across stream paths. I believe this causes GDAL to load and unload memory aligned blocks in memory as my algorithm iterates up and down stream paths.
Are there any known algorithms or heuristics about how to do hydrological "randomly walk across the rasters" for rasters that are too large to fit in RAM?
For context, I have looked at the source code of TauDEM but have not seen any specific algorithms to address this issue (also it's hard to just read code directly looking for something like this). I've read 20+ published articles in hydrology (most of them Tarboton lead authorship) but I have not seen any significant mention of implementation details with respect to runtime complexity or memory management. Googling these terms does not give me any leads either.
In short: Are there any algorithms or known heuristics that allow efficient processing of Very Large DEMs that do not fit in RAM?


texts: ArcGIS Network Analyst and modelBuilder problem

texts: I need to use server tool Create Service Areas. For input data i need to use iteration of features, that uses as Facilities. Task in general - to create service area. Area radius depends on count of people, living in area. Radius of area increases iterativly while it exceeds Threshold value. Model works properly for one Facility, but when I try to use iterator for feature selection as Facilities it crushes with error Facilities: dataset does not exist or does not supported"


texts: Prompting Dialog Box to Have User Enter Information without ArcGIS Engine?

texts:
Working with the ArcGIS family v10.1 on Windows 7.

So, I have this vision for a GIS project that does the following:

User opens up ArcGIS Explorer (ideally) or ArcMap (still fine), or I guess even an external website (least ideal) and loads in my project file.
It pulls up this map I've made- let's say it's a shapefile of a
city, with house/parcels linked to a database of information, like
address, owner, year built, and number of windows.
They either click one button or hit a hotkey and up pops a dialog
box where they can enter, say, 1234 main street, and click ok.
Then, without the user having to do anything, ArcExplorer/Map zooms
to that parcel/house and also selects and displays, say, all other houses that
intersect a circle with a diameter of 300 years, and outputs out a list of the houses in that selection circle.
There's a lot more. but I just want to know if this is something that can be done. In the ideal it wouldn't take a ton of sophisticated coding; it doesn't really even need to be fully functional, just a proof of concept.

While writing this I've been looking around the internet, and it seems like ArcGIS engine is something I would need? Any way the above could be done without ArcGIS Engine?


texts: Counting self intersections of linestring using PostGIS?

texts:
Is there a way of using PostgreSQL + PostGIS for finding the number of self intersections in a linestring?

I have a linestring that goes forward but in circles, and I need to find the number of times it crosses itself.


texts: Using ArcPy to Rename Feature Class by Field?

texts:
I made a little model and at the end I want to rename the feature class file to something based on the fields in that feature class. I want to rename that feature class by the date the data was collected (its a field in the FC) follow by an underscore then by the editor of the FC (which is also a field). The way our files are setup is the data is collected on the same date by one person. So there is no danger of having 2 editors to one file or 2 dates. I am just really new to Python.

I used it to do field calculations and have that understood fairly well. But I am trying to figure out the command to pull the field value and print it in the rename.

I have the stock python script for rename

# Name: Rename_Example2.py
# Description: Rename fileGDB feature class

# Import system modules
import arcpy
from arcpy import env

# Set workspace
env.workspace = "C:/workspace/test.gdb"

# Set local variables
in_data =  "test"
out_data = "testFC"
data_type = "FeatureClass"

# Execute Rename
arcpy.Rename_management(in_data, out_data, data_type)

How do I put the fields with the data into the "out_data"? I figure I have to collect it some how, maybe in the local variables? You don't need to write the script for me, but if you could point me to a solid source for commands and strings that would be great. I already checked out other threads and the python site.

https://docs.python.org/2/library/string.html#formatspec

It seems close to what I need but I am still not getting it.


texts:
I just read about latitudes and longitudes. I read latitudes are imaginary lines that run around the earth and longitudes are lines that run around from top to bottom.

Using this system:

1. How is exact position determined in degrees?
2. Why is the equator represented as zero degrees?


texts: Getting Hypsometric curve and Integral from elevation data in ENVI?

texts:
I am attempting to get the hypsometric curve (HC) and integral (HI) from some elevation data. The data I have is in ENVI format (ENVI ROIs and DEMs). Eventually, I would like to automate this, but for now, I just want to calculate the HC and HI for a few example cases using the ENVI GUI.

This should be very simple: calculate the histogram for the ROI, divide the values of the histogram by the highest histogram value (to normalize it to 1; this will give the HC), then sum the histogram values to get the HI.

I can't seem to find anything about calculating histograms in ENVI. Could someone provide instructions (or a link) on how to use ENVI to do the process described above?


texts:
I need to open a Spatialite database by using php in a php's framework. I've already work on a basic php file to test how it work but it gave me some errors.

I've already try to load extension by using two method :

$db->loadExtension('mod_spatialite.so');
Warning: SQLite3::loadExtension(): Not supported in multithreaded Web servers in C:\applications\www\sqlite3_ext\index.php on line 19
$db->exec("SELECT load_extension('mod_spatialite.so')");
Warning: SQLite3::exec(): not authorized in C:\applications\www\sqlite3_ext\index.php on line 20

Utilities :
Use a wamp (3.0.0) for a local server
 - PHP 7.0.0
 - Mysql
 - Apache 2.4.17

Link to my basic php code : https://pastebin.com/t01D7xrg
Link to my php.ini configuration : https://pastebin.com/HrTjnWPP