texts: QGIS MADEIRA - could not load SIP module and qgis.utils.uninstallErrorHook error - Ubuntu 18.04

texts:
I updated QGIS Girona to QGIS Madeira and now I have the problem. Every time I open QGIS I get two errors:

Couldn't load SIP module.
Python support will be disabled.

Traceback (most recent call last):
File "", line 1, in
File "/usr/lib/python3/dist-packages/qgis/__init__.py", line 72, in
from qgis.PyQt import QtCore
File "/usr/lib/python3/dist-packages/qgis/PyQt/QtCore.py", line 26, in
from PyQt5.QtCore import *
ImportError: /usr/lib/x86_64-linux-gnu/libQt5Core.so.5: version `Qt_5.11' not found (required by
/home/user/.local/lib/python3.6/site-packages/PyQt5/QtCore.so)

Python version:
3.6.6 (default, Sep 12 2018, 18:26:19)
[GCC 8.0.1 20180414 (experimental) [trunk revision 259383]]

QGIS version:
 3.4.0-Madeira 'Madeira', 4a4b62e

And I checked, I have QtCore.so on that path. And my version is PyQt5-5.11.3.

Second error:

An error occurred during execution of following code:
qgis.utils.uninstallErrorHook()

Traceback (most recent call last):
  File "", line 1, in
NameError: name 'qgis' is not defined

Python version:
3.6.6 (default, Sep 12 2018, 18:26:19)
[GCC 8.0.1 20180414 (experimental) [trunk revision 259383]]

QGIS version:
3.4.0-Madeira 'Madeira', 4a4b62e

Python path:
['/usr/share/qgis/python',     '/home/user/.local/share/QGIS/QGIS3/profiles/default/python', '/home/user/.local/share/QGIS/QGIS3/profiles/default/python/plugins', '/usr/share/qgis/python/plugins', '/usr/lib/python36.zip', '/usr/lib/python3.6', '/usr/lib/python3.6/lib-dynload', '/home/user/.local/lib/python3.6/site-packages', '/usr/local/lib/python3.6/dist-packages', '/usr/lib/python3/dist-packages']

After that I tried to reinstall QGIS - it didn't help, I tried to install back Girona - didn't succeed in that. I tried to reinstall Qt library, also nothing. I tried solutions from here and here - also didn't help.

And at the end. It really doesn't matter which version I would have (only to be 3.X). I needed it to set up PyQGIS with Pycharm.

I am using Ubuntu 18.04 Bionic.


texts: Rotated image for WCS GetCoverage Operation "v1.1.0" in GeoServer

texts:
I am using GeoServer v2.10.1. I have created a layer for testing using "Geo-tiff" store and later published it that computed "Native and Declared" Coordinate reference systems and computed "Bounding Boxes" automatically from image raster/data.

After creating layer I called WCS GetCapabilities operation and found my layer/coverage in available coverage. Next I have tried calling WCS DescribeCoverage Operation and found that the coordinates under Bounding Box are rotated as shown in figure.

For the confirmation I tried GetCoverage Operation on same coverage and the image downloaded was also rotated.

  GetCoverage&identifier=coveragename&BOUNDINGBOX=-92.37604305953325,19.9981422668471,-74.48971252207147,29.99999999730591,urn:ogc:def:crs:OGC:1.3:CRS84&FORMAT=image/tiff&store=true

So is this default WCS behaviour?

As I have tried the same layer using WMS (in OpenLayers) and get the correct image.


texts: Is the use of Google Earth imagery via the OpenLayers Plugin in QGIS legal?

texts:
I understand the terms and conditions WRT use of Google Earth imagery in external applications are strict.

Years ago ArcBruTile offered such service in ArcGIS the legallity of which was questionable. (Google Earth is imagery option was later removed) Bing imagery is still an option but I am not sure how this is possible if ESRI states that in order to use Bing imagery the service must be purchased from Microsoft.

Where can I find the terms and conditions of use of Google Earth imagery in QGIS as provided by the OpenLayers plugin?

I like the idea, i just want to make sure it's legal. Can i produce maps for professional use and publications with this plugin, etc.?

ANSWER:
@Andre Joost pointed me to the answer. In short, this type of use is not permitted under Google's Terms of Service:

10.1 Restrictions on How You May Use the Maps API(s). Except as explicitly permitted in Section 8 (Licenses from Google to You) or the Maps APIs Documentation, you must not (nor may you permit anyone else to) do any of the following:

10.1.1. General Restrictions.
(a) No Access to Maps API(s) except through the Service. You must not access or use the Maps API(s) or any Content through any technology or means other than those provided in the Service, or through other explicitly authorized means Google may designate. For example, you must not access map tiles or imagery through interfaces or channels (including undocumented Google interfaces) other than the Maps API(s).


texts: Importing GPS coordinates to extract multiple DN values in ERDAS

texts:
I have a set of GPS points (stored as a csv for now) and would like to import these points to ERDAS to find the DN values associated with each location.

I am able to import a SHP to ERDAS but the only way I have found of extracting the DN values is via the use of the Inquire tool.

This enables me to input the lat/lon values manually to find out the DN values but I was wondering whether I am missing a more efficient batch method for doing this using a txt / csv upload?!

Update: managed to solve this in QGIS using http://www.digital-geography.com/qgis-plugins-point-sampling-tool/


texts: QGIS 3.4.4 Issue when manually modifying values in graduated style

texts:
In Win10, QGIS 3.4.4. In a polygon layer, I go to properties->Style->Graduated->classify, and I want to manually modify values for each symbol displayed. But once I modify values manually and click "accept", the values are not the ones I wanted, and there's no way I can do it without QGIS doing something different. See screenshots:

I've tried to solve it re-installing QGIS, but the problem remains. It is also strange that this problem is not happening in another computer I have with the same QGIS version, so I am wondering if there's something I need to adjust in my computer.

It is annoying that I cannot input the values I want for each symbol, and I need to go back to QGIS 2.18 everytime I have this issue, and my wish is to work with QGIS 3.4.


texts: Convert 3-band raster imagery to distinct vector zones in ArcGIS

texts: So much like the title says I would like to convert a 3-band infrared image TIF file of vegetation into distinct vector feature zones using ArcGIS.  I'm guessing the only way to do this is with Spatial Analyst extension which is fine.  The result goal would be having a feature class that would have polygon features of different vegetation levels based on the original raster image.  Basically I don't want to have to hand draw my own polygon features by using the raster image as a base layer.  Steps and tools involved would be appreciated.


texts: ArcGIS Server: "MapServer is not supported with the current license."

texts:
I am at a complete loss... I have a Server 10.0 license on my machine but the following code fails:

if (ESRI.ArcGIS.RuntimeManager.Bind(ESRI.ArcGIS.ProductCode.Server) == false)
    throw new Exception("License Failed");

MapServerClass mapServer = new MapServerClass();
mapServer.Connect(pathToMap); // Fails!

ComException was unhandled

MapServer is not supported with the current license.


texts: Managing a big dataset. OSM Data. Spliting dataset and removing selected OSM tags

texts:
I have some prexisting data in dbf format for a very large area (Australia sized plus much larger, around 2.8 GiB in size) (can be converted quite easily to xml or shapefile)

I want to download and retain openstreetmap data and remove the dbf data when it overlaps selected tags for ways, nodes and relations. This can be done quite easily in JOSM and the re-exported. But JOSM does not like large files certainly not 2.8 GiB ones.

Is there any way to remove unnecessary tags and data from the downloaded OSM file and then split the two files, my dataset and the OSM downloaded dataset into roughly equally sized (in area) regions enough that JOSM could handle (with 1.2 GiB of RAM the software limit on my PC for JOSM). I was thinking of doing something with QGIS, as it seems the most powerful and user friendly. I'm no good at non GUI software but am open to suggestions.

A further issue when splitting files is what happens when one part of a relation or way is on one side of the split and another on the other side


texts: Spatial Rendering using ArcGIS Restful APIs

texts:
Always when I read the documentation, I always hear the term Restful APIs and ArcGIS Server using Restful Service to render the mxd hosted on the server.

I am a bit unclear about what exactly does Restful API mean?

Also how does Servers like Geoservers and ArcGIS Server, render these spatial data? What is it that is different about these servers from normal servers we have?

I know they are able to render spatial data, unlike normal servers, but what makes them have this capabilities and is it or not, related to Restful APIs?


texts:
Given a set of coordinates of landmarks to a specific time how could one accommodate for the change of those coordinates over time via pyproj. I found that Pyproj recommends using the time component when transforming time-based coordinate reference systems. But I dont quite grasp ho to perform a transformation along the time axis within the same System.

lat = 52.296191503
lon = 10.459750464
alt = 130238.877
transformer_Wgs84_Itrf2014 = pyproj.Transformer.from_crs(4326, 7789)
print(f">ITRF2014.2010: {transformer_Wgs84_Itrf2014.transform(lat, lon, alt, 2010.00)}")
print(f">ITRF2014.2020: {transformer_Wgs84_Itrf2014.transform(lat, lon, alt, 2020.00)}")

The code above always gives the same coordinates for both times.


texts: QGIS as Spatial Database RAD or Hierarchical Attribute Viewer/Editor?

texts:
I have designed a geological observational spatial database in PostgreSQL/PostGIS to manage geochemical samples, QAQC and geological map objects.  Now is the not so fun/easy part of designing a front end to manage all the 1:1 and 1:Many related tables.  I have extensive experience with MS Access database forms design but besides that my GUI programing is limited.

I am looking for a multi-platform database RAD (Windows/Linux/IOS/etc) so I am leaning towards something with python.  I was looking at Dabo  (http://dabodev.com/) at first but it seems to be quite a slow to stagnate development.

So what are the opinions of using QGIS as the spatial database attributes front end manager and of course spatial display & editing?  How difficult will it be to design a relatively complicated database application in QGIS?

On another hand one really nice feature of ArcGIS is its hierarchical attribute information & editor tool for dealing with multiple 1:1 & 1:many related tables.  Does QGIS have anything similar?  That would be nice to begin the database model testing.


texts: How to Add New Freehand Shapes and Data in QGIS?

texts:
I'm new to QGIS. Can anyone either direct me to a good tutorial or explain? I want to draw freehand new shape layers on to Google Earth to map vegetation types and embedded data for each feature. I am able to draw a shapes as a layer on the map, but I don't understand if or  how to customise the attribute table for that layer and every time I try to draw a new shape for that layer it comes up with window saying id. or should I be using one of the different database functions?

Thanks for your time.

paddy


texts:
I have a CSV, encoded in utf-8, that I'm trying to geocode:

When I run the MMQGIS geocoder, it doesn't encode anything. It doesn't give me an error-- it just says "Geocoded 0 of 49".

How can I figure out what is causing this plugin to fail?


texts: Importing shapefiles to PostGIS on QGIS1.8

texts:
I am trying to import a shapefile into PostGIS from within QGIS 1.8.

The QGIS is based on a server that is not managed by myself. I have requested an upgrade to QGIS 2.0... but this may take some time so in the meantime I am working with 1.8.

I am using SPIT to import shapefiles to PostGIS in QGIS.

The error message I am returned is:

Problems inserting features from file: filepath/charcoal.shp

Error while executing the SQL:

SELECT
f_table_name FROM geometry_columns WHERE
f_table_name='charcoal' AND
f_table_schema='GIS'

 The database said: ERROR: permission denied for relationship geometry_columns


texts: Can I extract embedded Google maps data from this webpage?

texts:
I need the coordinates and data of the points marked on this embedded google maps page:

(The information is public)

link to webpage

maybe there is a way to view the data in google earth, and extract a kmz file?
or inspect the page with firefox/chrome inspection tool and find the data file?
or some hack...


texts: Clipping raster layer coming from ArcGIS Server

texts:
I am loading this map that in QGIS coming from an ArcGIS Server.
https://calfire-forestry.maps.arcgis.com/home/item.html?id=b7ec5d68d8114b1fb2bfbf4665989eb3
Whenever I try to clip it with a mask it does not work. It also happens with the XYZ Tiles maps. Also It doesn't allow me to export the raster layer as a TIFF.
Is someone having the same problem?


texts: Help with formatting ArcGIS text elements with Python

texts:
I'm struggling with a formatting issue that comes from inserting text into a Text Element object in ArcGIS using Python. I want to print a table of values of which all but the last column are numbers. My python script loops through a list and applies formatting to each element like this:

#Text element is referenced:
tableTextQuad1 = arcpy.mapping.ListLayoutElements(mxd, "TEXT_ELEMENT", "tableTextQuad1")[0]
#All of the work occurs within a function that takes the table, x postion, y position, and text element reference (txtBox1) as its arguments)
#A clone of the element is created and used by the newCellText
newCellText = txtBox1.clone("_clone")
#A for loop is used to loop through lines in a table, and each line is formatted like so:
reformat1 = '{:>3}      {:>6.2f}      {:>3}      {:>7.2f}      {:>7.2f}     {:<10}'.format(t[0], t[1], t[2], t[3], t[4], t[5])
myList.append(reformat1)
myList.append('\n')
#To get rid of commas I do the following:
alpha = "', '".join(myList).replace("', '", "")
#Then the alpha string is sent to the cloned text object
newCellText.text = '{:}'.format(alpha)
newCellText.elementPositionX = x1
newCellText.elementPositionY = y1

When I don't include the last element (t[5]) the table looks great...like this:

But as soon as I try adding the string t[5] (which are directions like North, South...) to the line everything in the line gets shifted and seems to ignore the width and character spacing allocation I set in .format(). The result looks like this:

I've tried many different formatting parameters for t[5] but nothing seems to work the way I want it.  Can anyone tell me why all the numbers would adhere to formatting rules like right/left justify and width but the inclusion of letters on the same line messes it all up?
What is the correct formatting I should use?
Many thanks in advance for help!

*Update - I have also tried adding a carriage return to the \n, so that '\r\n' is appended to each line, but this does not fix my problem. Could it be a bug?


texts: Least Cost Path Distance to nearest polygon using ArcGIS Desktop?

texts:
I have multiple polygons (destinations) and an elevation raster. For each raster cell in my study area, I need to calculate the distance to the nearest destination polygon. If I use the 'as crow flies' distances, that's easy (I can convert my polygons to raster, and then use the Raster\Analysis\Proximity in QGIS or raster - euclidean distance in ArcGIS).

In my application I need to get a 3D distance on the terrain surface. So, an "as crow flies" distance of 10 km would be bigger if there is a big hill or deep valley between them.

Is there any ArcGIS function similar to the "raster proximity" or "raster euclidean distance" that takes into account elevation change?

I'm looking for something like least cost path distance, but not just for two points but for every grid cell.


texts: Using getmapasync() function instead of getmap() function in Android to plot GeoJSON file?

texts:
This is the code that I have used to plot GeoJSON file in Google Maps in Android:

    mMap = googleMap;
    SupportMapFragment mapFragment = (SupportMapFragment) getSupportFragmentManager()
            .findFragmentById(R.id.map);
    GeoJsonLayer cul_els = new GeoJsonLayer(getMap(), R.raw.cultural_elements,
            getApplicationContext());
    cul_els.addLayerToMap();

I know since getMap() has been deprecated, we need to use getMapAsync() but how? When I replace the line

GeoJsonLayer cul_els = new GeoJsonLayer (getMap(),R.raw.cultural_elements,getApplicationContext());

with

SupportMapFragment mapFragment = (SupportMapFragment) getSupportFragmentManager().findFragmentById(R.id.map);

GeoJsonLayer cul_els = new GeoJsonLayer(mapFragment.getMapAsync(this), R.raw.cultural_elements,getApplicationContext());

I get an error like this:

Unhandled exceptions: java.io.IOException, org.json.JSONException

How can I make this work?


texts:
I have two layers and they just won't line up. I am a novice and tried a variety of things but I can't get it right.

My layers are in:

GRS_1980_Transverse_Mercator
ETRS_1989_LAEA

These are CORINE and Copernicus EUDEM layers, or layers derieved from them.

What should I do, and more importantly - how?


texts: Two maps using Carto and Leaflet with same events (zoom, pan, etc)

texts:
I need a HTML page to compare two maps from Carto using Leaflet with same events, i.e. a Pan (or Zoom In/Out) event in Map1 aplicate the same in Map2.

I saw this example (Two cartodb visualization on the same html page) that show how can I use two maps at the same pages. But I need aplicate same events in both maps.


texts: Giving different colours to two different polygon symbols in same shape layer?

texts:
I made a new shapefile and then in ArcMap, with editor, made a new polygon and gave it a color by clicking the little color square in the Table of contents(TOC). Later on I saw that I needed to make another symbol inside the polygon I drew. So I drew a small circle inside the polygon(still using editor under the same layer). But I wanted the circle to be a different colour than the polygon. But I can't seem to find a way to change its colour (I don't want to have to create a separate shapefile).

I clicked the 'construct polygon' button to give the circle a solid colour since I don't want it to just be a circular ring inside my polygon. I tried playing around with some of the options under the symbology tab but no luck. And I can't seem to understand the solutions posted by other people in other forums.

The small islands in the picture are not drawn by me but are part of another shapefile.


texts:
I have a GML layer representing an hexagonal grid that I would like to include in some maps. In QGIS (version 2.14.2) I applied a graduated style and completely removed the polygon border:

However, in the map canvas the borders are still being portrayed:

Zooming in one can see the border around each polygon, it is thin, but it is still there:

Suspecting this was an issue with the map canvas itself, I tried to produce some maps with the Print Composer. Even in vector format the polygon borders are portrayed. Please check these files:

PDF
SVG

Is there any way to force QGIS to remove these borders?


texts: Creating polyline between points using ArcGIS Desktop?

texts:
Using ArcGIS Desktop, I am trying to create a frontline of a battle from WW2. I have known points, and want a polyline to run between both sides. There is 87 days of combat, so every day there is a new frontline as units move.

The image below is an example of one day.

I originally tried using Thiessen polygons, but it's to inaccurate, especially when you have an outlier that juts out.

Do you have any ideas or thoughts?
Dataset

Thieseen Polygons. Its not to bad, but there is that jut in the top right area with the purple polygon.

Concave Hull example. I need a tighter fit and the red concave to not overlap any yellow points.


texts: Modifying placement properties for labels using ArcPy?

texts:
Does anyone know how to modify the location of a label programmatically?

I'd like to make the labels sit directly below the symbol!


texts:
I'm trying to visualise a specific ski route. The sample is taken with a gps tracker in Obergurgl & Hochgurgl, Austria. I am using QGIS for this assignment. I could insert the trace using vector lines in QGIS.
But now I want to add some background data, like streets, heights, buildings for instance. Does anyone know how to do so or where to find the appropriate data?


texts: Generate additional files with map meta information using QGIS3 Atlas

texts:
I am using QGIS3 Atlas/Layouts to generate thousands of PDFs from a coverage layer. In addition to the PDFs, I want to save meta information (place names, dates, coordinates, custom IDs, etc) alongside each PDF that is generated, for example inside markdown or JSON files.

Is this possible within the QGIS3 GUI?


texts: ArcToolbox 9.3 converted to ArcGIS 10 not working in ArcMap 9.3?

texts:
I added a custom toolbox created for 9.3.1 to a ArcGIS Desktop 10 ArcMap.  Now it seemed to have disappeared.  I can't add it to ArcMap 9.3.1.

Is there a way to convert it back if that is even the issue?  Or is there something else going on?


texts: Using arcpy.CopyFeatures_management results in a 000210 using a database connection that does not contain saved credentials

texts:
Currently have a problem running CopyFeatures_management in ESRI's ArcGIS 10.1

The following shows two Enterprise Geodatabase connection files. One includes the username and password and the other one doesn't. While still at 10.0 (SP5) running this script would result in the Database Connection prompt appearing. Since installing 10.1 (SP1 + Quality Patch) it no longer does and simply fails with error 000210.

It works fine if I switch the script to use the connection file with the credentials saved into it.

So far tested on XP and Server 2008.

Please see the script below:

import os, sys
import arceditor, arcpy

# Define the source
source_fc_full_path = r'C:\_SCRATCH\DB_work\test_upload_data.gdb\ut_random_pts_10_gdb'

# Two connection files - one with the user credentials saved to it
# the other without. Under 10.0 (SP5) using the connection string without
# the credentials would result in a Database Connection box appearing. At 10.1
# this no longer happens.
# Works fine if I switch the workspace.
# NOTE - one of them is commented out for obvious reasons.
target_wkspace = r'C:\_SCRATCH\DB_work\user_pass_not_saved.sde'
#target_wkspace = r'C:\_SCRATCH\DB_work\user_pass_saved.sde'

target_fc = r'<DB_NAME>.<SCHEMA_NAME>.UT_RANDOM_PTS_10_GDB'

# Define the full target path
target_fc_full_path = os.path.join(target_wkspace, target_fc)

# Run the command that now fails at 10.1 with a 000210 if the connection string does not include user credentials saved into it...
arcpy.CopyFeatures_management(source_fc_full_path,target_fc_full_path,"","0","0","0")


texts: Receiving ERROR 000732 from ArcPy that raster does not exist or isn't supported?

texts:
I am running this script to perform simple raster algebra on the pycharm interpretor...

    import arcpy
arcpy.env.overwriteOutput = True
from arcpy.sa import *

# Specify the input raster
inRaster = "C:/user/dark7/desktop/lesson1/USGS_NED_one_meter_x47y367_CA_SanDiegoQL2_2014_IMG_2016.img"
cutoffElevation = 200

# Check out the Spatial Analyst extension
arcpy.CheckOutExtension("Spatial")

# Make a map algebra expression and save the resulting raster
outRaster = Raster(inRaster) > cutoffElevation
outRaster.save("C:/user/dark7/desktop/lesson1/SD_hiev")

# Check in the Spatial Analyst extension
arcpy.CheckInExtension("Spatial")

I receive this error...

Traceback (most recent call last):
  File "C:/Users/dark7/PycharmProjects/untitled/practice script.py", line 16, in <module>
    outRaster = Raster(inRaster) > cutoffElevation
RuntimeError: ERROR 000732: Input Raster: Dataset C:/user/dark7/desktop/lesson1/USGS_NED_one_meter_x47y367_CA_SanDiegoQL2_2014_IMG_2016.img does not exist or is not supported

Process finished with exit code 1

I have already checked to make sure that the spatial analyst extension is enabled in my copy of arc and the data I want to use is not opened in any applications when I ran the script. Does anyone know how to fix this problem? I looked into other peoples questions and modified a few things but I keep receiving the error.


texts: Some text-sizes of labels are not working in TileMill

texts:
I am using TileMill to create some offline tiles. Currently I have problem that some of the text sizes are not working and they are displayed as weird signs. Do you have any idea what could be wrong?

  #waterways {
  line-smooth: 1;
  line-join: round;
  line-cap: round;
  //label styling and placement
  text-name: [name];
  text-face-name: 'Calibri Italic';
  text-fill: @water_labels;
  text-placement: line;
  text-halo-fill: fadeout(white, 0%);
  text-halo-radius: 1.8;
  [type = 'river'] {line-color: @water; line-width:12;
    [zoom=15] {text-size: 15;}
    [zoom=16] {text-size: 16;}
    [zoom=17] {text-size: 17;}
    [zoom=18] {text-size: 18;}
    [zoom=19] {text-size: 19;}
  }
}

Picture a) text-size: 18

Picture b) text-size: 17


texts: rasterio reprojection produces no visible changes

texts:
I've been trying to perform translation of a raster using the reproject function from rasterio.warp.
I've calculated the translation amount in X and Y from a series of "control points" placed manually on a shapefile. I'm using these values to update the affine transform of the source raster and keep everything else the same. Both input and output should be in UTM Zone 23S (EPSG:32723), same GSD, width and height.
Here's my code:
import rasterio
from rasterio.transform import Affine
from rasterio.warp import reproject, Resampling
from pathlib import Path

input_raster_path = Path('path/to/raster.tif')
output_raster_path = input_raster_path.parent / (input_raster_path.stem + '_translated.tif')

with rasterio.open(input_raster_path, 'r') as src:

    dx, dy = -13.02168809006301, -2.439212051903208  # Values in meters, calculated earlier
    translation = Affine(1, 0, dx, 0, 1, dy)
    new_transform = translation * src.transform
    print(dx, dy)
    print(src.transform)
    print(new_transform)  # Making sure the new transform values make sense

    profile = src.profile.copy()
    profile.update(transform=new_transform)

    with rasterio.open(output_raster_path, 'w', **profile) as out:

        for i in range(1, src.count + 1):
            reproject(
                source=rasterio.band(src, i),
                destination=rasterio.band(out, i),
                src_transform=src.transform,
                src_crs=src.crs,
                dst_transform=new_transform,
                dst_crs=src.crs,
                resampling=Resampling.nearest)

The above code results in a slight difference in the raster visually (probably due to rounding in the GSD and nearest resampling), but with no perceivable translation in relation to the original. I've also tried to multiply dx and dy by 10 to see if the values were just too small to notice, but the exact same output was created.
Note: The metadata on the new raster seems correct, I can inspect it on QGIS and get the correct extent and transform, but the pixels are not translated at all.
EDIT 1: I was unaware of the function Affine.translation but it produces the same translation matrix I've created directly by providing coefficients to the Affine constructor.


texts: Completely filling polygons with text labels on per-feature basis?

texts:
I would like to create a map of regions, where each region is completely filled with its specific chunks of text. Think a map of Wordles in the shape of regions that are assembled together into a map.

This is an example (not mine) for the UK but where all UK is one region instead of divided into counties.

Either approach – web map (using e.g. D3 or cartodb) or traditional offline map (made e.g. in QGIS) – would be fine.

I suspect this is actually quite a hard problem (fitting text inside polygon, collision detection, automatic placement, ...).


texts: Coordinate System correctly renders both decimal Long/Lat and some number in the billions

texts: I am new to ArcObjects and I have been creating an application which will (among other things) be reading data in from a sister program and plotting it on the map.I have found out that I can enter the coordinates as both decimal long/lat, or by using a pair of numbers close to a billion. Both of these methods will draw a point somewhere on the map. My question is: why? How is it possible that this works, and which one is correct?


texts:
I am an R user and have a .dwg file of city buildings that I wish to transform into a RasterLayer using the heights as elevation data.

The metadata for the DXF file states:

DXF File Metadata: Projection - MTM 3 Degree Zone 10 NAD27, WGS84 Latitude/Longitude

What is the recommended workflow to do this? I am on a Mac if that is helpful.

Since .dwg is proprietary I converted it to .dxf using ODAFileConverter.app

Still, it's not clear to me as to how to read the file.

Is there geolocation type data in the DXF file? Can that become part of the RasterLayer?

QGIS 3.6 crashes if I try Project > Import/Export > Import Layers from DWG/DXF with the DWG file. If I try the DXF file it just creates a single line. I know the file is good because I can view it OK with Autodesk's Online Viewer.

library(rgdal)
file = "50G_SOUTH2.dxf"
ogrListLayers(file)

[1] "entities"
attr(,"driver")
[1] "DXF"
attr(,"nlayers")
[1] 1

ogrInfo(file)
Error in ogrInfo(file) : Multiple # dimensions: 2:3

35 MB DWG file is here

278MB DXF file is here


texts: Inputs for building composite address locator from address locators created in for loop of Python script tool?

texts:
I'm building a script tool that creates up to 3 address locators and then uses the output address locators as inputs to the final output composite address locator. The tool executed perfectly prior to adding the code to build the comp address locator. As the tool builds the input address locators in a for loop, I cannot hardcode their names as the first argument for the create composite locator. Instead, I made a list that is populated as the tool loops to make the input address locators:

alNames =[]
for ref in refData:
    baseName = os.path.basename(ref)
    outName = os.path.join(outPath,baseName) #this is the final argument for the create address locator tool

    ...all the code to make the address locator....

    alNames.append(outName)

arcpy.CreateCompositeAddressLocator_geocoding("alNames[0],alNames[1],alNames[2]","Street 'Street or Intersection' true true true 100 Text 0 0 ,First,#,alNames[0],Street,0,0,alNames[1],Street,0,0,alNames[2],Street,0,0;ZIP 'ZIP Code' true true false 10 Text 0 0 ,First,#,alNames[0],ZIP,0,0,alNames[1],ZIP,0,0,alNames[2],ZIP,0,0",outCompAdd)

I'm getting the following error when I run the tool:

Traceback (most recent call last):
  File "N:\Python\Completed scripts\Create_Address_Locators.py", line 34, in <module>
    arcpy.CreateCompositeAddressLocator_geocoding("alNames[0],alNames[1],alNames[2]","Street 'Street or Intersection' true true true 100 Text 0 0 ,First,#,alNames[0],Street,0,0,alNames[1],Street,0,0,alNames[2],Street,0,0;ZIP 'ZIP Code' true true false 10 Text 0 0 ,First,#,alNames[0],ZIP,0,0,alNames[1],ZIP,0,0,alNames[2],ZIP,0,0",outCompAdd)
  File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\geocoding.py", line 138, in CreateCompositeAddressLocator
    raise e
ExecuteError: ERROR 000582: Error occurred during execution.

When I run the tool without the quotes around the items from alNames[] I get an error message that the tool only takes up to 4 arguments and I provided 5.


texts: How to install the latest build of QGIS?

texts:
On Dec. 18, Radim Blazek developed the 'Improved raster singleband pseudocolor classification GUI'. Being new at QGIS, I have no idea how to go about updating to this version.

Could someone possibly assist me with this?


texts:
I'm trying to transform a JTS geometry from EPSG 3035 to 4326 with the code attached below. However, when I'm just reading the geometry from a WKT, the results are different from the expected value (should be long: 48°16'17.626", lat: 14°16'55.125", according to epsg.io, but is POINT (61.90... -19.77...)).
However, when I switch the coordinate order in the WKT I get the expected results. Is there any way to tell the WKTReader or JTS.transform to switch up the coordinate order internally?
final WKTReader reader = new WKTReader();
final Geometry geom = reader.read("POINT (4638804.944501147 2804557.565404966)");
final CoordinateReferenceSystem crs3035 = CRS.decode("EPSG:3035");
final CoordinateReferenceSystem crs4326 = CRS.decode("EPSG:4326");

final MathTransform metersToDeg = CRS.findMathTransform(crs3035, crs4326);
final Geometry transformed = JTS.transform(geom, metersToDeg);
System.out.println(transformed);


texts: How to prepare a multi-colored vector layer?

texts:
I need to present a multi-colored vector layer and something similar to below:

I need to prepare the vector layer by making use with the data set available in my database.

Inside my database, I have geo coordinate data and color data

Long            Lat         ColorCode
121.4698        40.8417     FF6600
121.4698        40.8325     FF6600
.
.
.
121.0344        40.4658     FFCC00
121.0344        40.4567     FFCC00

I am beginner in web GIS. Kindly point me some direction. What would be the usual way to do this?

I would guess I should put the data into GeoJSON format. But how do I prepare the polygon information?


texts: I want to, on right-click on a feature in a layer, have an action execute. I need to know 1 thing: What layer was right-clicked. Does anybody know how I can get this functionality? The API doesn't officially support it.


texts: remote access to virtual machine can't open qgis

texts:
I'm currently running a virtual machine on amazon EC2 and planning to do some web-gis service through it. I installed the QGIS remotely but apparently I can't run it from my local machine through ssh, below is the message I got:

QGIS starting in non-interactive mode not supported.
You are seeing this message most likely because you have no DISPLAY environment variable set.

Anyone could show me a way to work around it?


texts:
I have a raster where null values are stored as -9999. I want to change these to 0.
Googling suggests this can be done in the raster calculator, but e.g. (layer name = -9999) * 0 doesn't work. And indeed other pages suggest that any formula including a null will return a null. I've also tried r.reclass, reclassify by table and by layer, but none are giving me what I need - which is simply to change -9999 values to 0.


texts: merging layers of raster data of the same format

texts:
My map consists of several different grid-layers lying right next to each other.

I want to merge them to one single layer so that i can analyse my whole map at once.

How can i do that?


texts:
I'm using GeoExt2 (alpha) + Extjs 4.1 now to implement a map application. The thing is sometimes when I select a feature on the map, two popups are displayed. one at the bottom of the screen which has correct info and one empty in the right place. it doesn't go even I close it. I wonder if this is a bug ?

EDIT

myLayer.events.on({
 featureselected: function(e) {
 createPopup(e.feature);
 },
  featureunselected: function(){
  popup.destroy();
 }
});

function createPopup(feature) {

    popup = Ext.create('GeoExt.Popup', {
    id: 'popup',
        title: title,
        location: feature,
        });

         popup.on({
            close: function() {
                if(OpenLayers.Util.indexOf(myLayer.selectedFeatures,
                                           this.feature) > -1) {
                    selectControl.unselect(this.feature);
                }
            }
        });

    PopupTab = Ext.create('Ext.tab.Panel', {
    id: 'PopupTabs',
        activeTab:2,

    items: [
        {
            title: 'Supervisor',
            itemId: 'tab1',
        },
        {
            title: 'student',
            itemId: 'tab2',

            items: [
                {
                xtype: 'label',
                id: 't',
                html: content,
                layout: 'fit',
                                cls:'tabStyle'
                }
            ]
        },

    ],
    listeners: {
        tabchange: function(panel, tab) {
            if (tab.popup !== undefined) { // show window after tab change
                tab.popup.show();
            }
        }
    }
});

        popup.add(PopupTabs);

        popup.show();

    }


texts: Why does KMZ to GPX reverse the objectid?

texts:
I am working on KMZ to GPX conversion and every time I use the data interoperability extension and quick export it seems to reverse the objectid, now my 1st waypoint is the last placemark point of the KMZ file that was used to convert it.

I am using ArcGIS desktop advanced license 10.2.2.

Does anyone know why this would be happening?


texts: In MapBox Studio Classic (cartocss) is it possible to style a #waterway to show up at zoom levels below 8

texts:
I'm working with Mapbox studio classic, using Mapbox Streets V6 as the vector tile source. I'm working on a project specifically related to waterways, and only larger bodies of water (#water in cartocss) show up when not zoomed in.

Is this a limitation of using this specific vector tile source?

Any ideas how to make them show up at lower zoom levels?


texts: Calculating Area of Raster Classes using ArcGIS Desktop?

texts:
I have a raster in a GRID format that was created by Image Classification. The GRID is projected in StatePlane meters, but I would like the area in square feet. I'm assuming I will need to use the Field Calculator for this, but I'm not sure what to input.

I've already created a new field int he GRID's attribute table for area. I'm running ArcGIS Desktop 10.1.


texts: What epoch does Proj4 for EPSG:4326 assume? NMEA stream provides Lat Lon at measurement epoch

texts:
I get a NMEA stream exported from Applanix PosPac in the epoch the measurements took place (2019). These coordinates go into a software, that interprets the NMEA Lat Lon as EPSG:4326 with Proj4 library. From there, I export georederenced point clouds into another coordinate system, the software does the conversion from EPSG:4326 into the desired system, e.g. UTM ETRS1989 EPSG:25832, using Proj4. If I understand correctly, Proj4 must implicitly assume an epoch for the WGS84/EPSG:4326 system.

Is this epoch 1984? Or has there been an update for the WGS84 standard epoch? I can export lat lon at any epoch, so I just need to know which one is correct.


texts: Union multiple shapefiles with overlapping shapes


texts: Summarizing table based on 2 columns using ArcMap

texts:
I got a shapefile that has the landuse and the area of every single piece of ground near a specific road. Like this:

I want to summarize all landuse areas of near each road in one row. Like this:

How can I do that?


texts: How to compute LST every 3rd day for 19 years (Earth Engine)


texts: How to convert distance in meters(EPSG:28406) to EPSG:900913 with OpenLayers?

texts:
For point I use OpenLayers and transform():

 numZona = Math.ceil(parseFloat(lon)/6));
 Proj4js.defs["EPSG:28406"] = '+proj=tmerc +lat_0=0 +lon_0='(parseInt(numZona)*6-3)+' +k=1.000000 +x_0='+numZona+'500000 +y_0=0 +ellps=krass +units=m +no_defs;
 centerPoint = new OpenLayers.Geometry.Point(lon, lat).transform(new OpenLayers.Projection("EPSG:4284"), new OpenLayers.Projection("EPSG:900913"));

But what do with distance?
I have longitude and latitude in EPSG:4284, distanse in meters and a map with EPSG:900913 projection.


texts: Failed to install Potree on Ubuntu 18.04 Bionic

texts:
I am trying to install Potree on my computer and I am stuck. I am following these instructions:

$ sudo apt-get install python-software-properties git
$ sudo apt-get install build-essential cmake g++
$ sudo apt-get install libboost-all-dev
$ sudo apt-get install cmake-curses-gui
$ sudo apt-get install gcc

LAStools:

$ git clone https://github.com/m-schuetz/LAStools.git
$ cd LAStools/LASzip
$ mkdir build && cd build
$ cmake -DCMAKE_BUILD_TYPE=Release ..
$ make

Potree Converter:

$ git clone https://github.com/potree/PotreeConverter.git
$ cd PotreeConverter
$ mkdir build && cd build
$ sudo cmake -DCMAKE_BUILD_TYPE=Release -DLASZIP_INCLUDE_DIRS=/home/opengeo/LAStools/LASzip/dll -DLASZIP_LIBRARY=/home/opengeo/LAStools/LASzip/build/src/liblaszip.so ..
**$ sudo make && sudo make install**
$ sudo ln -s ~/LAStools/LASzip/build/src/liblaszip.so /usr/lib
$ PotreeConverter -h

Anyway, I installed LAStools and I have problem with Potree. When I run command:

**$ sudo make && sudo make install**

I get:

Scanning dependencies of target PotreeConverter
 [  8%] Building CXX object
PotreeConverter/CMakeFiles/PotreeConverter.dir/src/BINPointReader.cpp.o
[ 16%] Building CXX object PotreeConverter/CMakeFiles/PotreeConverter.dir/src/GridCell.cpp.o
[ 25%] Building CXX object
 PotreeConverter/CMakeFiles/PotreeConverter.dir/src/LASPointReader.cpp.o

 /home/user/LAStools/LASzip/build/PotreeConverter/PotreeConverter/src/LASPointReader.cpp:8:10:
  fatal error: laszip_api.h: No such file or directory
   #include "laszip_api.h"
       ^~~~~~~~~~~~~~
   compilation terminated.
   PotreeConverter/CMakeFiles/PotreeConverter.dir/build.make:110: recipe for target
   'PotreeConverter/CMakeFiles/PotreeConverter.dir/src/LASPointReader.cpp.o' failed
   make[2]: *** [PotreeConverter/CMakeFiles/PotreeConverter.dir/src/LASPointReader.cpp.o] Error 1
CMakeFiles/Makefile2:85: recipe for target 'PotreeConverter/CMakeFiles/PotreeConverter.dir/all' failed
make[1]: *** [PotreeConverter/CMakeFiles/PotreeConverter.dir/all] Error 2
Makefile:129: recipe for target 'all' failed
make: *** [all] Error 2

But I have laszip_api.h in LAStools/LASzip/dll

I tried to manually copy it in /LAStools/LASzip/build/PotreeConverter/build but without success.


texts: Trying to build a model to get all layers(same name, different folders and different geodatabase) into one

texts:
I have over 3000 folders, each folders have a geodatabase and each geodatabase consist of a layer name called "lot".

I want to merge the all the "lot" layers into one layer shapefile, my gis knowledge is very limited and would like to ask some insights or tools i can use in this situation? I am thinking of these tools, and thinking how to plug each tool inside modelbuilder :

Iterate Feature classes (find the name of "lot")?,Parse path,Rename


texts: Breakline detection algorithms for LiDAR dataset?

texts:
I'm searching for algorithms or open source tools I could use to detect breaklines from a LiDAR dataset; more specifically, from the terrain points of the dataset. At the moment the only thing I've found are some articles based on edge detection for buildings and roads.

I suppose there are some algorithms based on point clouds, or maybe even for digital elevation models I could use.


texts: Adding ArcGIS Mapserver layer - query returned no layers

texts:
I am attempting to connect to an ArcGIS Mapserver that has worked without any problems in the past and now for some reason when trying to connect to the service it indicates "query returned no layers". I have contacted the administrator and the url I was using now redirects to the one listed below but other than that it works on his end with ESRI products.

Can someone verify the url and check to see if it works?

https://nsgiwa.novascotia.ca/arcgis/rest/services/BASE/BASE_NSODB_10k_WM84/MapServer


texts: Error in function to display images from Landsat 5

texts:
I have created a function that suppose to take images (which stored in a list) and display them, but I get all the time the next error:

Invalid argument specified for ee.Number(): function standin(_0) {
       return newF.apply(this, arguments);   }

This is my code:

/**
 * Function to mask clouds based on the pixel_qa band of Landsat SR data.
 * @param {ee.Image} image Input Landsat SR image
 * @return {ee.Image} Cloudmasked Landsat image
 */
var cloudMaskL457 = function(image) {
  var qa = image.select('pixel_qa');
  // If the cloud bit (5) is set and the cloud confidence (7) is high
  // or the cloud shadow bit is set (3), then it's a bad pixel.
  var cloud = qa.bitwiseAnd(1 << 5)
                  .and(qa.bitwiseAnd(1 << 7))
                  .or(qa.bitwiseAnd(1 << 3));
  // Remove edge pixels that don't occur in all bands
  var mask2 = image.mask().reduce(ee.Reducer.min());
  return image.updateMask(cloud.not()).updateMask(mask2);
};

var dataset = ee.ImageCollection('LANDSAT/LT05/C01/T1_SR')
                  .filterDate('1985-01-01', '2012-04-30')
                  .filterBounds(geometry)
                  .map(cloudMaskL457);

var visParams = {
  bands: ['B3', 'B2', 'B1'],
  min: 0,
  max: 3000,
  gamma: 1.4,
};

//clip the dataset according to the geometry
var clippedCol=dataset.map(function(im){
  return im.clip(geometry);
});

var RGBlist=clippedCol.toList(clippedCol.size());
for(var i in RGBlist){
  var imageRGB=ee.Image(RGBlist.get(RGBlist[i]));
  Map.addLayer(imageRGB,visParams,'i');
}

My end goal is to display all the images from the given date range in RGB colors, and to give each image a name automatically.


texts: Selecting max values from list of raster layer and attaching raster source of max value using ArcGIS Desktop?

texts:
I have three raster layers (a,b,c) and I am wondering if I can extract the maximum values AND attach the limiting raster(s) that contribute to the maximum value as illustrated. What I can do so far is only obtain the maximum values using Cell Statistics, but I have no idea which raster(s) make the maximum values of the output (symbolised as alphabets in the illustration).

I am using ArcGIS Desktop 10.3.


texts:
I am looking to create a city directory web app, and the site will need to be able to calculate distances between two geospatial points (like the distance between the user and a restaurant, or the distance between two restaurants).

I am a newbie to geospatial function, and recently started using PostGIS.  I have been having a heck of a time installing pgRouting into my PostGIS 1.4/PostgreSQL 8.4 server, so am thinking about giving it up for now until I feel like I need it.  I have already spent several hours trying to install pgRouting on my OSX 10.6 Snow Leopard machine with little success.

With that said, what exactly am I giving up?  It seems like ST_Distance will satisfy most of my needs in the short term and things like the Travelling Salesman Problem won't really apply to webapp (at least not for a while, if ever).  Is there something else that I am giving up?  Another reason to use pgRouting?

(As a side note, if you know of a place that makes installing pgRouting easy, please point me in that direction, as I have already tried about 3 pages worth of several google results for tutorials/instructions).


texts: Zoom level lost in public visualization?

texts:
I've got a visualization made where in the back-end it looks great. zoom level = 5.  Then any method of publishing sets the zoom level to 3.
Can this be forced to remain 5?

strangely, this other simple test map doesn't even have a zoom parameter passed to the url. This was the embed url I picked up on the day I was messing with it.
http://highrank.robh71.com/map1/index.php


texts: arcpy.CopyFeatures_management results in empty feature class

texts:
I have the function:

def copyToNewGDB(workspace,eventdataset):
    EventDataset_copy = os.path.join(workspace, "eventdatasetCopy")
    arcpy.CopyFeatures_management(eventdataset, str(workspace) + "/EventDatasetCopy" )
    eventdataset = str(workspace) + "/EventDatasetCopy"

    return eventdataset

That is used to copy features (a point dataset containg events) from one workspace (gdb) to another. I have used it many times. But when I use it on a particular dataset, the gdb that receives the copy contains an empty feature class, while it the feature class should not be empty. When I use the exact same code on another dataset there are no problems.

Ergo, the problem must be in my dataset, right? Both (the working and the non-working) point feature classes are in the same gdb. I have tried to manually copy it (using copy -data management-), that did not result in any problems. How can this function result in an empty feature class for one dataset, and run without trouble for another?


texts: ArcGIS -Sectioning a polygon shapefile from info in a different shapefile

texts:
Not sure if I've given my problem the right title. By my problem is as follows;

I have a shapefile containing info from a vegetation survey, which is a 50m wide corridor divided into separate polygons by vegetation type and condition. The other shapefile represents a construction corridor, which follows the same alignment as the survey but is only 10m wide.

What I want to do is divide the construction corridor into vegetation types as per the info in the survey shapefile. Is there a function I can use to do this automatically? Or will I have to split this myself using editor and cut polygon tool? It's 150km long so this is going to take a long time to do manually.


texts: Problems with NA values when reading .DEM file with R 'raster' package in Windows

texts:
I am trying to read a raster file in a .DEM format on windows using the 'raster' package in R.

I get problems with NA values, when loading the data into R in Windows 7, but I do not have the problem on a Mac with OSX Lion. On windows, the NA values do not seem to be read correctly. The question is why this happens?

The raster file used was downloaded from USGS with the following R code:

download.file('http://edcftp.cr.usgs.gov/pub/data/gtopo30/global/e020n90.tar.gz', 'e020n90.tar.gz')
untar('e020n90.tar.gz')

Then I read the raster into R using the 'raster' package. In OSX Lion and R64 version 2.13.1,
the NA values are recognized:

> onMac <- raster('E020N90.DEM')
> onMac
class       : RasterLayer
dimensions  : 6000, 4800, 28800000  (nrow, ncol, ncell)
resolution  : 0.008333333, 0.008333333  (x, y)
extent      : 20, 60, 40, 90  (xmin, xmax, ymin, ymax)
coord. ref. : +proj=longlat +ellps=WGS84 +towgs84=0,0,0,0,0,0,0 +no_defs
values      : /Users/Tam/Desktop/E020N90.DEM
min value   : -9999
max value   : 5483

> summary(values(onMac))
Min.  1st Qu.   Median     Mean  3rd Qu.     Max.     NA's
-137       85      148      213      213     5483 13046160

But on Windows 7 (64Bit, same R version) it converts the cell values that should be NA's into numbers:

> onWindows <- raster('E020N90.DEM')
> onWindows
class       : RasterLayer
dimensions  : 6000, 4800, 28800000  (nrow, ncol, ncell)
resolution  : 0.008333333, 0.008333333  (x, y)
extent      : 20, 60, 40, 90  (xmin, xmax, ymin, ymax)
coord. ref. : +proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs +towgs84=0,0,0
values      : E:/WorldDegreeDays/gsoddata/gtopo/E020N90.DEM
min value   : -9999
max value   : 5483

> summary(values(onWindows))
Min. 1st Qu.  Median    Mean 3rd Qu.    Max.
  1     150     946   27190   55540   65540

Why are there no NA values in the raster when I read it on Windows? How could I work around it? My guess is it has to do with the way numbers are stored, a lot of the NA values are converted to 55540.

Info from Windows (after loading raster):

SessionInfo()
R version 2.13.1 (2011-07-08)
Platform: x86_64-pc-mingw32/x64 (64-bit)

locale:
[1] LC_COLLATE=English_United States.1252
[2] LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.1252

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base

other attached packages:
[1] rgdal_0.7-1   raster_1.9-12 sp_0.9-88

loaded via a namespace (and not attached):
[1] grid_2.13.1     lattice_0.19-30

Info from OSX (after loading raster):

R version 2.13.1 (2011-07-08)
Platform: x86_64-apple-darwin9.8.0/x86_64 (64-bit)

locale:
[1] en_US.UTF-8/en_US.UTF-8/C/C/en_US.UTF-8/en_US.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods
[7] base

other attached packages:
[1] rgdal_0.6-33  raster_1.9-12 sp_0.9-88

loaded via a namespace (and not attached):
[1] grid_2.13.1     lattice_0.19-33


texts: What does the variable "tmmx" in the TerraClimate dataset stand for?

texts:
I'm working with TerraClimate and want to display the mean temperature for different decades in relation to the long term trend. I'm just wondering what exactly the variable "tmmx" is.  Is it the accumulated max. Temperature for 1 year?
Because when you research they say the dataset contains montly average values.
And the shown temperatures are around 300 °C. So when you divide it by 12 (Month) the numbers get more reasonable.


texts: How to install GRASS Add-On after migration from SVN to Github?

texts:
I'm new to GRASS and in the past I have had no issue installing add-ons. Recently I tried to install "r.stream.order" and got the following error:

g.extension extension="r.stream.order"

  Extension r.stream.order not found

I have tried installing the add-on both through the shell and the GRASS GUI. I have also downloaded the zipped file and tried to use the url option with the g.extension tool to install the add-on, but I get the same error. Although, this may have failed because the url option is supported only on Linux or Mac.

g.extension extension="r.stream.order" url=C:\Downloads\r.stream.order.zip

I read that the add-ons are installed by default from the GRASS SVN repository, which has recently been migrated to github and the svn repo now has read-only access.

Has anyone run into this error recently? If read only access to the SVN is causing the error, does anyone have any recommendations for how to resolve this issue and install the add-on?

Note: I have GRASS 7.6 installed on a Windows computer.

UPDATE: The add-on installs correctly on my personal computer with version 7.2 of GRASS. However, installing this same version on my desktop still produces the error. Additionally, installing newer versions of GRASS on my personal computer also produces the "extension not found error".


texts: Missing postgis function "ST_Buffer(geography g1, float radius_of_buffer, text buffer_style_parameters)"

texts:
I have following st_buffer functions:

st_buffer(geography, double precision)
st_buffer(geometry, double precision, text)
st_buffer(text, double precision)
st_buffer(geometry, double precision, integer)
st_buffer(geometry, double precision)

Any suggestions? (I want to use endcap=flat.. on my geography) my postgis version is 2.2.1

The function that I aim for is on postgis.net/docs/ST_Buffer.html hence not on postgis.org/docs/ST_Buffer.html


texts: How to check Polyline Hierarchy in QGIS?

texts:
I want to check polyline Ascending order hierarchy for road network in QGIS, For example
Grade 1 road must start from Grade 0,
Grade 2 road must start from Grade 1,
Grade 3 road must start from Grade 2

If not tool should mark an error. Is there any plugin or extension available for what I want exactly?


texts: QGIS Copy Attribute Table To Excel - where does the new lines come from?

texts:
I have an attribute table with 3100 lines.

I selected the whole table and pressed the button 'copy selected rows to clipboard', afterwards I pasted them into an excel-table.

Now I have 27 lines more. There are no attributes in these lines, only information in the wkt_geom row. In some lines are only numbers not even starting with PolygonZ. Where does these lines come from?


texts: How to get geometry in GeoJSON format using ST_GeomFromGeoJSON


texts: I have been sent some shapefiles, gathered using the Fulcrum app. However, when I load them into my project on QGIS 2.2, they wont display. They will display if I go to 'Zoom to Layer Extent" but under no other circumstances - even if I remove all other layers in the project.


texts: Can JQuery Mobile UI provide a user-created attribute table for a user-created point feature?

texts:
I'm looking into using the JQuery Mobile UI, and I would like the user of the app to be able to create their own point on the map and add a few short attributes. Any idea if this is possible?
Thanks in advance.


texts: QGIS error in merging large point shapefiles

texts:
While trying to merge 2 large point shapefiles using the merge shapefiles tool under the data management.

These point files have over 20Gb and have the same coordinate system.

Problem is, that the resulting shapefile had a huge lapse of data, basically a hole without any kind of points populating the location.

Is QGIS unable to process properly very large files or is there a more efficient way of doing this?

The merge is needed in order to run a query on the data (points in polygon would be useful)


texts:
I would like to have (almost) real-time synchronization between CARTO and a data source that is connected through an API (excuse any wrong terminology, I am very new to these things).

In CARTO documentation it says that sync time must be >= 900sec = 15 minutes. Why is that? Is there no way to attain smaller synchronization intervals?


texts: Using Multiple Where Clauses in ArcGIS Field Calculator?

texts:
Using ArcGIS Desktop 10.4, how can I pass Where clause and calculate  Field L_STATE based on Values on another field called L_ST_CODE.

What I have in 4 Unique values of 135, 138 , 148, 136

if (L_ST_CODE == 135){
   L_STATE = "Item_1"
}
if (L_ST_CODE == 136){
   L_STATE = "Item_2"
}
if (L_ST_CODE == 138){
   L_STATE = "Item_3"
}
if (L_ST_CODE == 148){
   L_STATE = "Item_4"
}


texts:
After performing pgRouting's "pgr_analyzeGraph" algorithm, over an Open Street Map dump uploaded to my PostGIS DB, I get this output, by I can't figure out what "ring geometries" are. Does somebod knows?

NOTICE:  PROCESSING:
NOTICE:  pgr_analyzeGraph(ejes_osm_noded',5,'geom','id','source','target','true')
NOTICE:  Performing checks, please wait ...
NOTICE:  Analyzing for dead ends. Please wait...
NOTICE:  Analyzing for gaps. Please wait...
NOTICE:  Analyzing for isolated edges. Please wait...
NOTICE:  Analyzing for ring geometries. Please wait...
NOTICE:  Analyzing for intersections. Please wait...
NOTICE:              ANALYSIS RESULTS FOR SELECTED EDGES:
NOTICE:                    Isolated segments: 0
NOTICE:                            Dead ends: 16381
NOTICE:  Potential gaps found near dead ends: 265
NOTICE:               Intersections detected: 14412
NOTICE:                      Ring geometries: 20

Total query runtime: 01:23 minutes
1 fila recuperada.


texts:
I created a new gdb by

arcpy.CreateFileGDB_management('e:/Rstack', 'new.gdb')
arcpy.env.workspace = 'e:/Rstack/new.gdb'

But how to set this new gdb as my default gdb by arcpy, without opening ArcGIS desktop? Setting env workspace does not seem to work here.


texts: TableToTable gives unexpected character after line continuation character?

texts:
I'm working on updating a python script from arcmap 9.3.1 to 10.2.1 and im getting an error for "unexpected character after line continuation character" and im unable to diagnose the character.

arcpy.TableToTable_conversion(sde_parcel_base_temp, sde, "parcel_base", "", "pin \"PIN\" true true false 10 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",PIN,-1,-1;pwd \"PWD\" true true false 13 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",PWD,-1,-1;add_num \"Address Number\" true true false 10 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",add_num,-1,-1;add_prefix \"Address Prefix\" true true false 1 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",add_prefix,-1,-1;add_strt \"Address Street\" true true false 50 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",add_strt,-1,-1;add_type \"Address Type\" true true false 10 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",add_type,-1,-1;add_sdir \"Address Suffix\" true true false 2 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",add_sdir,-1,-1;add_munic \"Address Municipality\" true true false 50 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",prop_city,-1,-1;add_zip \"Address ZIP\" true true false 10 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",prop_zip,-1,-1;add_full \"Full Street Address\" true true false 50 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",prop_street,-1,-1;ownr_name1 \"Owner Name 1\" true true false 50 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",owner1,0,49;ownr_name2 \"Owner Name 2\" true true false 50 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",owner2,0,49;ownr_addr \"Owner Address\" true true false 50 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",own_street,-1,-1;ownr_city \"Owner City\" true true false 50 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",own_city,-1,-1;ownr_state \"Owner State\" true true false 2 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",own_state,-1,-1;ownr_zip \"Owner Zip\" true true false 10 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",own_zip,-1,-1;acres "\Legal Acreage\" true true false 50 Double 0 0 ,First,#,"+ sde_parcel_base_temp +",legal_acreage,-1,-1;prop_code \"Property Class Code\" true true false 10 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",property_class,-1,-1;nghbr_code \"Neighborhood Code\" true true false 10 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",neighborhood,-1,-1;lgl1 \"Legal Line 1\" true true false 80 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",lrsn,-1,-1;lgl2 \"Legal Line 2\" true true false 80 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",lrsn,-1,-1;lgl3 \"Legal Line 3\" true true false 80 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",lrsn,-1,-1;lgl4 \"Legal Line 4\" true true false 80 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",lrsn,-1,-1;lgl5 \"Legal Line 5\" true true false 80 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",lrsn,-1,-1;lgl6 \"Legal Line 6\" true true false 80 Text 0 0 ,First,#,"+ sde_parcel_base_temp +",lrsn,-1,-1;lrsn \"Proval LRSN\" true true false 50 Long 0 0 ,First,#,"+ sde_parcel_base_temp +",lrsn,-1,-1;updated \"Last Update\" true true false 50 Date 0 0 ,First,#,"+ sde_parcel_base_temp +",last_update,-1,-1", "")

Above is the part of the script giving me problems.  Anybody with a trained eye able to point out my problem for me?


texts: Python - GDAL : Polygon to point shapefile

texts:
I want to read all the points in a polygon shapefile and use their coordinates to make a new point shapefile, then find the min and max of the X coordinates. So here is the code I wrote for the first part (polygon to point) and it makes the point shapefile but the attribute table is just has the ID field.

from osgeo import gdal
from osgeo import ogr
from osgeo import gdal_array
from osgeo import gdalconst
from osgeo.gdalconst import *
import os
os.chdir('C:\Fcounty')
driver = ogr.GetDriverByName("ESRI Shapefile")
fname = 'PolygonFC.shp'
vector = driver.Open(fname, 0)
layer = vector.GetLayer(0)
ofname = 'PointFC.shp'
if os.path.exists(ofname):
         driver.DeleteDataSource(ofname)

ovector = driver.CreateDataSource(ofname)
olayer = ovector.CreateLayer('points', geom_type=ogr.wkbPoint)
fieldDefn = ogr.FieldDefn('id', ogr.OFTInteger)
olayer.CreateField(fieldDefn)
featureDefn = olayer.GetLayerDefn()
point = ogr.Geometry(ogr.wkbPoint)
k = 0
f = layer.GetNextFeature()
while f:
    geom = f.GetGeometryRef()
    ring = geom.GetGeometryRef(0)
    np = ring.GetPointCount()
    for j in range(np):
        p = ring.GetPoint(j)
        ofeature = ogr.Feature(featureDefn)
        point.AddPoint(p[0], p[1])
        ofeature.SetGeometry(point)
        ofeature.SetField('id', k)
        olayer.CreateFeature(ofeature)
        ofeature.Destroy()
        k += 1
   f.Destroy()
   f = layer.GetNextFeature()
vector.Destroy()
ovector.Destroy()

As I mentioned this part is not giving me any error (I know it does not mean it works). So my questions are:

Is this the right code? why there is no other fields beside 'ID' in attribute table?
How can I do the second part of it? (the coordinates for lowest and highest X) I want to get it from the point shapefile, not the polygon.


texts: PostGIS query with external bounding box

texts:
I am editing a shapefile as wide as an island. The data are stored in a Postgres/PostGIS database. I want to display only features from my defined bounding box. The bounding box itself is a custom layer that i made myself and it is not stored in the database.

How can this be achieved?

Update: the PostGIS manual has this particular example

SELECT
  m.name,
  sum(ST_Length(r.the_geom))/1000 as roads_km
FROM
  bc_roads AS r,
  bc_municipality AS m
WHERE
  ST_Contains(m.the_geom,r.the_geom)
GROUP BY m.name
ORDER BY roads_km;

Since I dont have the bounding box geometry in the database, is there another way to mimic the bounding box geometry?
It would be something like this

SELECT
 layer,
 (x1,y1), (x1,y2), (x2,y2), (x2, y1) AS bbox
FROM
 layer
WHERE
 ST_Contains(layer.the_geom, bbox);


texts: Using FeatureClassToFeatureClass_conversion to convert tab files?

texts:
I'm trying to use FeatureClassToFeatureClass_conversion() to convert tab files to shapefiles. When I run the code below, the error says

  C:/temp1\Overlays\Character_Places\Historic_Misc_Heritage.TAB Failed
  to execute. Parameters are not valid. ERROR 000732: Input Features:
  Dataset C:/temp1\Overlays\Character_Places\Historic_Misc_Heritage.TAB
  does not exist or is not supported. Failed to execute
  (FeatureClassToFeatureClass).

import arcpy
from arcpy import env
import os

path = "C:/temp1"
for root, dirs, files in os.walk(path,topdown=False):
   for file in files:
      if file.endswith(".TAB"):
         tabFile = os.path.join(root, file)
         print(tabFile)

         outLocation = "C:/temp3/results.gdb"
         outFeatureClass = "shapefiles"
         arcpy.FeatureClassToFeatureClass_conversio(tabFile,outLocation, outFeatureClass)

When I comment out the FeatureClassToFeatureClass code and print(tabFile) tabFile's contents are printed as..

C:/temp1\Overlays\Character_Places\Historic_Misc_Heritage.TAB
C:/temp1\Overlays\Character_Places\Identified_Places_Heritage.TAB
C:/temp1\Overlays\Character_Places\places_of_history.TAB
C:/temp1\Overlays\Character_Places\places_of_culture.TAB
etc
etc

I'm unsure why its saying the dataset doesn't exist and why tabFile isn't the correct input parameter for FeatureClassToFeatureClass() to work


texts:
I am using geolocate to zoom to the users location. Afterwards I am trying to get the bbox of that area. However the geolocate function is for some reason always executed last, so I don't get any results (I only get null).

var vector = new OpenLayers.Layer.Vector('vector');
var geolocate = new OpenLayers.Control.Geolocate();
map.addControl(geolocate);

geolocate.events.register("locationupdated",geolocate,function(e) {
    var circle = new OpenLayers.Feature.Vector(
        OpenLayers.Geometry.Polygon.createRegularPolygon(
            new OpenLayers.Geometry.Point(e.point.x, e.point.y),
            e.position.coords.accuracy,
            40,
            0
        )
    );
    vector.addFeatures([circle]);
    map.zoomToExtent(vector.getDataExtent());
});
geolocate.activate();

var bounds = vector.getDataExtent();
var coords = bounds.toBBOX();
console.log(coords);


texts: Cannot access row[1] using arcpy.da.SearchCursor

texts:
My code creates a dissolved feature class with 2 rows. For some reason I am unable to access the 2nd row using the following code:

fcCount = arcpy.GetCount_management(fc)
print(fc) #2
def getrowValues():
    with arcpy.da.SearchCursor(fc, "Field") as cursor:
        for row in cursor:
            print(row[0]) #Prints value
            print(row[1]) #IndexError: tuple index out of range
rowValues = getrowValues()

I looked at the examples here, but I was unable to find the source of error.

Edit: This accomplished what i was trying to achieve:

def getrowValues():
    val =[]
    rows = arcpy.SearchCursor(fc, fields= "Field")
    for row in rows:
        val.append(row.getValue("Field"))
    if val[0] == val[1]:
        return val[0]
    else:
        return ' & '.join(val)


texts:
I'm trying to resolve the inability to load a raster MBTiles map on a GPS that added support for the format.
Maps created using QGIS or CalTopo will work. The SQLite database only contains two tables-tiles and metadata. There are no indices or views.
Maps created using Tilemill won't work. The SQLite database has 6 tables, 6 indices and 3 views (one of which are the tiles).  Some of the additional objects are use for the interactivity layer supported by Tilemill.
I suspect that differences in the database schema are the source of the incompatibility.
Is there any way to make Tilemill generate an MBTiles file in the using the two table database schema?
Is there any way to convert MBTiles schemas?
Are there any other methods to render MBTiles files from ESRI and CartoCSS?


texts:
I'm making a map for school GIS course coursework.
We must use cartodiagram/chart for map and I have an idea to make a map, that shows lighthouses and their light sectors as pie chart.
I have managed to extract data from large pdf and import it into QGis as csv.

In that table, I have described light sectors as (5+1)*8=48 values per lighthouse (5 colors + no light, for maximum of 8 sectors). Data starts from north and continues clockwise. In QGis, I can set that pie chart starts from up (north), but it lists sectors on chart counterclockwise and changes something else(?), so I need to flip all pie charts horizontally.

Other question, is it possible to add transparency/alpha channel to pie chart color. If it is possible, how could I achieve that, if not, what is then workaround? Currently, I'm using simply black as placeholder.

Final, but not important problem, how could I bring other layers front of charts? Setting diagram priority nor layer ordering didn't work.

P.S I'm non-native english using non-english QGis and computer, so some exact names of functions/objects might be wrong.

Clarifying questions:

How to add transparency to pie chart pie?

2. How to transform (flip) all charts at time?

3. How to change chart rendering order?

Edited to remove other questions. Pie transparency is most important for me currently.


texts: Viewshed analysis adding polygon mitigation in QGIS?

texts:
I am looking at a DSM layer in QGIS and have created a binary viewshed using the viewshed analysis plugin. I want to add a polygon layer with heights to add on top of the dsm layer to indicated mitigation and location of buildings before rerunning the viewshed analysis.

Does anyone know how to add polygons with height relative to the DSM and then complete the viewshed analysis to include them?


texts: Earth Engine convert list with coordinates and values into a feature collection for export

texts:
I need to create a feature collection from a list containing coordinates and band values.  These are extracted from a landsat image as shown in this linked script.

Extract complete pixel values inside a geometry

I'm unable to find a solution in creating a feature collection.  Here is the tail end code.

var valuesList = joinedImage.reduceRegion({
  reducer: ee.Reducer.toList(4),
  geometry: myGeometry
}).values().get(0);

var feature = ee.Feature(null, valuesList);

// Wrap the Feature in a FeatureCollection for export.
var myFeatures = ee.FeatureCollection([feature]);

// Export the image, specifying scale and region.
Export.table.toDrive(myFeatures,
"data",
"myData",
"B4-B5",
"CSV");

This doesn't work, because it is clearly the wrong way to create the feature collection.  I've tried to create it similar to Rodrigo E. Principe's solution of mapping a Feature Collection but I can't seem to create the initial feature collection to start with.


texts: Distinguishing shapefiles from geodatabase feature class with arcpy.Describe() method?

texts:
I have a list of layers (.ListLayers()) taken from a dataframe
. In my case the layers can have two types of data source either shapefile or GDB. I want to start different actions depending on the source type. What I thought of so far: it would be possible to compare the 'desc.name[-4:]' with '".shp"' like:

import arcpy

mxd = arcpy.mapping.MapDocument("CURRENT")
df = arcpy.mapping.ListDataFrames(mxd, "")[0]
lyrlist = arcpy.mapping.ListLayers(mxd, "", df)

for lyr in lyrlist:
    desc = arcpy.Describe(lyr)

    if (desc.name[-4:] == ".shp"):
        #do something with the shapefile
    else:
        #do something with the GDB feature class)

I still believe this option must be hidden somewhere in the describe method.

Is it possible to distinguish shapefiles from geodatabase feature class with the arcpy describe() method?


texts: Unicode Characters in GRASS ps.map instructions file

texts:
I am trying to put text on a ps.map generated map and the text contains the degrees symbol. I can insert the symbol into the instructions file, and it looks fine, but when I generate the map, the result is Â°

Here's the instruction:
text 99% 63% 60 °N
  fontsize 16
  ref left
end

Does anyone have advice on how to get unicode symbols to display correctly with ps.map?


texts: R: How to get latitudes and longitudes from a RasterLayer?

texts:
I am an absolute beginner of geographic data, so please, forgive me if the question is not appropriate.

I downloaded data from NCDC NARR and managed to load into R using the raster package. I would like to get a list with latitude, longitude and value. I understand that rasterToPoints() should do exactly what I want, however, my latitude and longitude values look strange:

r <- raster(myfile)
data_matrix <- rasterToPoints(r)
head(data_matrix)
            x       y value
[1,] -5405401 4347242    70
[2,] -5372938 4347242    88
[3,] -5340475 4347242    76
[4,] -5308012 4347242    85
[5,] -5275549 4347242    87
[6,] -5243086 4347242    88

I suppose I should do something with the projection which is currently Lambert Conformal Conic (LCC). Here are further info about the raster.

> r
class       : RasterLayer
dimensions  : 277, 349, 96673  (nrow, ncol, ncell)
resolution  : 32463, 32463  (x, y)
extent      : -5648874, 5680713, -4628777, 4363474  (xmin, xmax, ymin, ymax)
coord. ref. : +proj=lcc +lat_1=50 +lat_2=50 +lat_0=50 +lon_0=-107 +x_0=0 +y_0=0 +a=6371200 +b=6371200 +units=m +no_defs
data source : mypath-to-file
names       : value

What shall I do to get real US latitude and longitude values?


texts: ArcGIS Pro Creating Scale dependent Symbology by modifying the .lyrx file

texts:
In ArcGIS Pro, there is the option to symbolize a feature dependent on scale. I have several maps I am looking to convert and want to modify the .lyrx file (is JSON format) to accept these alternate symbols.
With an open JSON and a simple dataset I found the alternateSymbols list in
data['layerDefinitions'][0]['renderer']['groups'][0]['classes']**['alternateSymbols']**

When i try to import my other symbols with minScale and maxScale Values, i get nothing.
If I just dump them into 'classes' they DO show in ArcPro, but are not scale dependenent.
This is the function I am using a the moment
def outload_into_one_file(detail, normal):

detail = detail
normal = normal
out_file = os.path.splitext(normal)[0] + "_COMBINED.lyrx"

with open (detail , "r") as jsonFile:
    detail_data = json.load(jsonFile)

with open (normal , "r") as jsonFile:
    normal_data =   json.load(jsonFile)

detail_base = detail_data['layerDefinitions'][0]
detail_classes = detail_base['renderer']['groups'][0]['classes']
normal_base = normal_data['layerDefinitions'][0]
normal_classes = normal_base['renderer']['groups'][0]['classes']
detail_classes_dict = {}
for x in detail_classes:
    detail_classes_dict.update({x["label"]: x})
for k, v in detail_classes_dict.items():
    print(k)
#detail_classes[0]['alternateSymbols'] = []
count = 0
for x in normal_classes:
    x['maxScale'] = 251
    x['minScale']= 3000
for x in normal_classes:
    cls = detail_classes_dict.get(x['label'])
    cls['maxScale']=250
    cls['alternateSymbols'] = []

    cls['alternateSymbols'].append(x)

with open(out_file, "w") as jsonFile:
    json.dump(detail_data, jsonFile)


texts: Seeking algorithm that can re-locate vertices on linestring so that line does not intersect land polygons

texts:
I'm currently working with GPS data gathered from boats. The data has low temporal resolution (every 5 minutes) which causes the linestrings that display the boat's trajectory to be jagged. An example is shown below:

As you can see, this interpolated linestring intersects the land, but the points that were used to construct it all lie inside water.

Is there any way I can smooth this line out to avoid land?


texts: I have a table of crimes by precinct. There is a field with the precinct number (I.E. 1, 2, 3, 4...) I also have a field each for Burglaries, Assault, Arsons with a count of how many in each precinct. Is there a way to summarize the precinct field so that each of the three crime type fields are ranked from highest count value to lowest (I.E. 1,2,3,4... instead of the current count 45,35,43...)


texts: Getting lat/lon of maximum value in raster using PostGIS?

texts:
I can get the max value from a raster column using PostGIS and

SELECT max(ST_SummaryStats(rast, TRUE))."max") FROM schema.table;

How do I take that value and get its coordinate(s)?


texts: How to view an MSSQL layer/table with mixed geometry types using QGIS (2.18)?

texts:
I have a connection to data in an MSSQL database. The key (spatial) table records points, polygons, and lines all within the one table. Is there a more graceful way to handle this data on QGIS - which is more advanced than setting up three separate filtered views on the database, one for lines, one for polygons and one for points?

....

The following are details which may or may not be relevant:
- QGIS 2.18
- MSSQL / SQL Server 2014 (12)
- there are no multi-polygons/multi-lines/multi-points
- The database administrator has successfully set me up with filtered views (I don't have direct database access, but close communication)
- I'd actually like to be able to filter the raw data myself using tools at the QGIS end of this connection.
- QGIS seems to decide on one of the three geometry types (I'm guessing based on something like the first entry in the table) and I can't find any way to change this, so from the raw data I can render only lines.
- I tried some basic edits with a text file to the QGIS project to see if I could force QGIS to recognise the layer as being points/polygons but failed.

I note that there are a selection of somewhat similar questions already asked, but these are I think either very old (referring to old versions of QGIS) or unanswered.


texts: How can I add a pdf as hyperlink for a point in QGIS? Can I do the same in GVSIG?

texts:
I am working on a project for which I would have to make a map displaying all archaeological sites of the city; it will later be used and accessed by my office's stuff only. In the end, when clicking on each site, the user should be able to see all the site's information displayed in a dialogue box, but also he should be able to see and have access to the site's relative documents (one pdf for each site). Till now, they have been using gvsig, and some of them insist that we continue working with it, although I have the possibility to choose between that and Qgis. In any case, I know neither to that level (i am a beginner in qgis and never worked with gvsig) so would you please indicate me which of the two programs is better for what I want? And then, could anyone please tell me a simple and easy way to do it (details would be highly appreciated)?

Thanks a lot!

Eva


texts: Where do I find additional instructions for QGIS print composer?

texts:
QGIS Print Composer has numerous complex interacting features. Scale vs paper size vs map extent vs QGIS main window map extent - locked layers - resolution - map rendering level (i.e. the scale used to determine the map rendering), WMS tile zoom level choice, and so on. Things seem often not to work as expected.

Is there a source of full instructions explaining how these interact? The main documentation explains the basics fine, but not these complicated interactions.


texts: Getting parameter defined in one tool to another tool in same Python Toolbox?

texts:
This is what I am looking for:

Create two tools in Python Toolbox: Tool1 and Tool2 (I am able to do that)
I want to define a parameter in Tool2 whose value depends on parameter entered by user in Tool1.

How can I do that? Can Tool1 be called in Tool2 and automatically Tool2 gets the value of parameter entered by user in Tool1? I want to use the value of parameter entered by user in Tool1 to define a workspace in def getParameterInfo(self): in Tool2.


texts: Strange things are afoot with the "Eliminate Polygon Parts' tool

texts:
I am working with a polygon that is the result of a buffer and has a bunch of internal doughnut holes:
 What I want is this:

I am using arcpy.EliminatePolygonParts_management() to fill in the holes but have a question about how this tool functions.

When I run the tool using the "PERCENT" condition I cannot get the holes to fill in.  Initially I set the percent to 99 thinking that it would delete any part that was smaller than 99 percent of the total area of the polygon.  That didn't work.  Thinking that perhaps I had my logic backwards I set the percent to 1, that didn't work either.

I did get it to work, and produce a polygon that is just the outer boundary but to do so I had to switch to the AREA condition and set the number ridiculously (for my purposes) high, to 1 billion square meters.

I am quite confused by this...  Can anyone offer an explanation to help clarify my understanding of how this tool works and why I can't get the "PERCENT" condition, which seems to be the more appropriate choice, to work?


texts:
I'm using QGIS 3.4 for this, and am creating a map that will see quite a lot of use. It will show plant species, and the area of the plants in question.

For this, we have a main "plant" table. This contains all the plants, their species, and their area. Which sounds easy enough.

However, we are going to be filtering on the "plant" table to generate specific maps (eg "Plantation"=31). There are also 50+ species of plants, so what I'd ideally like is to have a legend which will update itself as to what species are being shown, along with their symbology, and also their summed area.

Any idea how best to go about this? I've tried using virtual layers but keep running into issues. Maybe using an Atlas? Or if there's a way to "carry over" the symbology into a table on the layout (that one would make it sooo much easier).


texts: gdal_rasterize incorrect values scale after rasterization

texts:
I am trying to rasterize a .shp file (in particular it is made up by several Polygon) into .tif one by using python and the gdal_rasterize command.
According to the gdal_rasterize function, I was able to set the options:

a (the attribute that I want to be mirrored within the raster)
tr (since I know the width and heigth pixel of each polygon)
te (also in this case I have the     boundary of the .shp)

The conversion is correctly in terms of positions within the map. But the range of values is different w.r.t the .shp file.
The command called was:
 import subprocess

 def rasterize(source_shape_file, layer_name, attribute, dest_file,
               width, height, xmin, ymin, xmax, ymax, dest_file):

   subprocess.check_output("gdal_rasterize -a " + str(attribute) + " -l " + str(layer_name) + " -tr "
                           + str(width) + " " +  str(height) +  "-a_nodata -1.0 -te " + str(xmin) + "
                           " + str(ymin) + " " + str(xmax) + " " + str(ymax) + " -of GTiff " + "'" +
                           str(source_shape_file) + "'"+ " " +str(dest_file) + "")

By executing this, within QGIS I was able to saw the result:

The raster value with some blue transparency completely overlap the vector layer as expected.
However the data range:

As it is possible to see, is different between the two layer.
I mean for the max and min value.
Am I doing something wrong during the execution of the command?
Or is there some option that I have ignored?
I would like to know if there is some way to obtain the same values of the vector layer inside the raster one.


texts: Computing View Distance in One Direction from Point on Elevation Raster in PostGIS?

texts:
I'm a software developer just getting into GIS, so please forgive me if I don't use proper lingo, or if I use proper lingo incorrectly!

I have a raster of elevation data. For a given point in the raster, I'd like to compute how far one can "see" from that point in each of the 4 cardinal directions.

I'm assuming that all obstructions are accounted for in the elevation data, that the Earth is flat, and that the whole region I care about is represented in the raster. Also, let's assume the viewer is 5 feet tall. So, we can reduce this to a problem of "How many squares in the raster can I 'see' before I either (a) hit a square that has elevation>=myelevation+5ft, or (b) leave the rasterized region?"

If I simply had to write a program to compute this, I'd do a simple traversal in each direction until I hit a square that matched my criteria. Or, if I wanted the 360° view, I could use a "flood fill"-style algorithm to do that, too. However, I have no idea how to do this in a "GIS-y" way!

Based on what I've read, it feels like there should be a ST_MapAlgebra solution, but I haven't been able to put my finger on it.

If I could get a "visible region" that looks out in 360° -- so all the continguous raster squares I can see from the given square -- that would be even better!


texts: List all Points within Polygon using QGIS?

texts:
Complete newbie to QGIS and can't seem to find how to do this.

I have created a map with 84 different polygons.  Then I've imported approx. 8000 points.

What I want to do is now query my map and get it to tell me the polygon each Point is in and then be able to extract this into a text or CSV file.

Can anyone help?


texts: programmatically populating the QGIS Legend

texts:
So I have a function in a utility class that creates my Legend for the composer. It looks something like this:

def addLegend(self, c, r, L, tree_root):
    L.model().setLayerSetAndGroups(tree_root)
    c.addComposerLegend(L)

where:

L is an QgsComposerLegend
c is the QgsComposition
r is the iface.mapCanvas().mapRenderer()
tree_root is an arbitrary group in the tree of layers and groups originating from QgsProject.instance().layerTreeRoot()

it works but my requirements bring up these issues:

The legend should display a colored box for the groups
The layers should not show up in the legend even though they do in the map


texts:
After years working with Linux and Windows I had to move to MacOS. So far I succeeded in installing QGIS from the QGIS website. But I can't find ogr2ogr - I'm pretty sure it is installed on my system.
Can anybody help?


texts: Where does the snapshot command take its pixel samples from?

texts:
I'm using the snapshot command in QGIS with a horizontal extent from 0 units to 24 units to create an image with a horizontal resolution of 4 pixels. Are the output pixels located at 3,9,15,21 (seamless tiling) or at 0,8,16,24 (overlapping)?

Edit: Tried to do some tests on this in 2.14.3 Essen and wow, snapshot is so broken. See for yourself...

512x256 has a white 2-pixel bar on the right border:

256x128 has the same problem, also 2 pixels wide:

128x64 has the same problem, also 2 pixels wide:

64x32 has the same problem, still 2 pixels wide:

32x16 is all black:

16x8 is all white:

8x4 is all white:

4x2 is all black again:

Seriously, what is going on here?


texts: Map does not appear upon opening print composer in QGIS

texts:
When I open my print project in print composer, my map is not there upon opening. There is only a little note that says "your map will print here".

What is going on here?


texts: What is the C# Arcobject I must use in order to set programatically the SQL Query of an LYR file?

texts:
I would like to change programatically the SQL Query of a LYR file. I'm developping in C# using ArcObject.

Actually I'm able to get an instance of IWorkspaceFactory from an opened layer with this code :

  IDataLayer dataLayer = (IDataLayer)lyrFile.Layer;
  IDatasetName datasetName = (IDatasetName)dataLayer.DataSourceName;
  IWorkspaceFactory wsFactory = datasetName.WorkspaceName.WorkspaceFactory;

But from here I'm stuck. I don't know how to access to the SQL Query. I've read that with ISQLWorkspace I could maybe do something. But, really I'm not sure at all.

The goal here is to create multiple copies of a layer file (lyr), changing only the SQL Query slightly. I need to do so because I do not have enough functionnalities within the "Definition Query" tab to implements different variations of my SQL query.


texts: MapsForge render theme with coloured hiking trail

texts:
I am looking for mapsforge render theme which displays hiking trails colours based on their waymarks colours (for example like on this server www.freemap.sk). I have found a lot of themes that displays this based on some kind of Alpine classification or based on local vs regional route (elevate theme does this) but none of them colours the trails based on waymark colour. Even locus on Android does this and it displays it correctly.

Any ideas on this?


texts: Legend inconsistent in QGIS map print layout

texts:
After I did styling my vector data set to be classified by graduated circle and categorized by type, it appears beautifully consistent in the map canvas as shown below:

But when I create a print map layout and after adding the map, I add the legend and it come out ugly inconsistent like this:

So, I would like to ask for help to make the legend in the map print layout consistent as the legend shown in layer panel.
I use the latest version QGIS 3.10.2 64bit.


texts: Can I use external map data with cartojs library?

texts: I am receiving data from another source apart from cartodb and I would like to use the data for carto maps.


texts: Measuring length through a polyline in QGIS.

texts:
I'm working on a fiber optic project. I want to measure the length through a fiber optic cable (polyline) from a point. Does anyone have an idea to help me?

For example, I'm at the point 082 CTO and want to measure 20 meters from this point through the T081 cable.


texts: Does QGIS perform better when using a materialized view or a standard view from PostGIS

texts: My PostGIS views in QGIS are significantly slower then other standard PostGIS tables and I have struggled to enhance their performance any good amount. If using materialized views in QGIS would I expect performance to increase?


texts: Connect points based on underlying road network in QGIS

texts:
I have a road network layer. I also have the latitude and longitude of the bus stops in that road network. I want to connect a series of these stops but not using straight lines but via the underlying road network.

Is there a way to do this in QGIS?


texts: Toggling from MapView(2D) to SceneView(3D) using ArcGIS API for JavaScript 4.0?

texts: I am currently working on a 3D map. I am wondering if it is possible to create a drop down list to toggle between 2D to 3D map.


texts:
I don't know how to install LAStools in QGIS 3.0. In QGIS 2.18, you can incorporate it as a provider in Processing -> Options-> Tools for LiDAR data (for example: Installing LAStools in QGIS 2.4?).

But in the QGIS 3.0, you can only find GRASS, GDAL and SAGA in the same place.

Does anyone knows how to install LAStools in QGIS 3.0?


texts:
I have two issues, one related to saving edits on a vector layer, the other related to the visibility of layers, and I'm assuming they have the same root cause, so I'm posting it as a single question. I think the issue arises at the project level, rather than the specific layer.
I have a complex QGIS 3 project with many layers. Recently I was editing a small hand-drawn vector path shapefile [EDIT: Actually it's a KML] (called Scouting_and_plans) and when I went to save edits I got this error:
Could not commit changes to layer Scouting_and_plans

Errors: ERROR: 1 geometries not changed.

  Provider errors:
      OGR error setting feature 41

I haven't found an explanation by Googling OGR error 41. I do seem to be able to edit some other vector layers in the project and save them normally.
As an attempted work-around, I exported the layer as a new layer. I tried both going to a new shapefile and a new geojson. In either case, I get what appears to be a layer with the appropriate data (attributes table works fine - also I can use the field calculator to get reasonable results), but there is no visible path. The path is not visible in the layers view on the left, nor on the actual map view, however if I edit the properties of the layer, all the settings appear normal - 100% opacity, some colored line with a reasonable stroke width.
I can still select paths normally, and the yellow selection color is applied - so the path is visible if selected. I can copy and paste a path to a new layer, and it is similarly selectable, highlightable, but not normally visible in the new layer.
If I create an empty project and add either the layer with the original issue, or the newly made layers, it functions normally, including for editing.
I have also opened the geojson file and looked at it in a text editor, and it appears normal.
I've re-loaded the project and restarted QGIS and the problem persists.

The feature I can edit but which returns an error when I save is in red (I moused over it with the vector editing tool for this screenshot to make it obvious.)


texts: Python in ArcGIS Pro: Backing Up All Layers in a Map

texts:
I am having a bit of trouble with Python.  I am trying to create a script (hard-coded for now, but eventually soft-coded to make a script tool) that allows the user to back up layers of a given map in ArcGIS Pro by creating local feature classes in a new file geodatabase named with today's date.  Here is my script:
import arcpy

arcpy.env.overwriteOutput = True

Project = r"P:\Projects\MyProject.aprx"outPath = r"P:\Projects"
myProj = arcpy.mp.ArcGISProject(Project)
myMap = myProj.listMaps("Map")[0]

today = datetime.date.today()
date = today.strftime("%Y%m%d")
name = "Backup_" + str(date) + ".gdb"
arcpy.CreateFileGDB_management(outPath, name)
GDB = outPath + "\\" + name

for layer in myMap.listLayers():
    arcpy.CopyFeatures_management(layer,GDB)

My script keeps failing in the Python console, and I get the message: "arcgisscripting.ExecuteError: Failed to execute. Parameters are not valid. ERROR 000840: The value is not a Feature Layer. Failed to execute (CopyFeatures)."
My understanding is that listLayers creates a layer object, but to use Copy Features I need a feature layer.  I've tried re-writing the 'for' loop to make a feature layer as follows:
for layer in myMap.listLayers():
    Feat = arcpy.MakeFeatureLayer_management(layer,"Templayer")
    arcpy.CopyFeatures_management(Feat,GDB)

However, I get the same error.
My layers are all web-hosted, although I don't know if this is the cause of my problem.  I really want a script that allows me to select a map within ArcGIS Pro, loop through all layers in the map, and copy them into a new FGDB.
How can I get my script to work?
Is there a way to convert a layer object into a feature layer?
Am I using the wrong approach?


texts: SAS Planet cache map (.sqlitedb) in QGIS

texts:
I want to use SAS Planet map format in QGIS application.

SAS Planet has a file system like this and each zoom layer has their own subfolders. Eventually there is a SQLite DB to store the images like this.

Is there any way that I can use maps in my QGIS application (I am using QGIS C++ API). I have tried using SpatialLite but couldn't succeed.


texts: How to add a Timeline tool to Time Lapse in GEE?

texts:
I have been struggling to add a timeline tool to a time-lapse video I put together on GEE... The last part of my code is:
var polygon = ee.Geometry.Rectangle([-XX,-XX,-XX,-XX]); //xMin, yMin, xMax, yMax.

var videoArgs = {
  collection: collection,
  description: 'VideoExample',
  dimensions: 600,
  framesPerSecond: 10,
  region: polygon
};

print(collection.getVideoThumbURL(videoArgs));

How would it be possible to add a timeline tool to the video representing the changes over time for my collection? How can I pass the date of each image to the timeline tool and then to the video?


texts:
I and my colleagues are running into a very frustrating Python import error while using the OSGeo4W Shell. Any time we attempt to use gdal_calc in a Python script, we get the following error message:

Traceback (most recent call last):
  File "C:\OSGEO4~1\apps\Python27\Scripts\gdal_calc.py", line 51, in <module>
    import numpy
  File "C:\OSGEO4~1\apps\Python27\lib\site-packages\numpy\__init__.py", line 142, in <module>
    from . import add_newdocs
  File "C:\OSGEO4~1\apps\Python27\lib\site-packages\numpy\add_newdocs.py", line 13, in <module>
    from numpy.lib import add_newdoc
  File "C:\OSGEO4~1\apps\Python27\lib\site-packages\numpy\lib\__init__.py", line 8, in <module>
    from .type_check import *
  File "C:\OSGEO4~1\apps\Python27\lib\site-packages\numpy\lib\type_check.py", line 11, in <module>
    import numpy.core.numeric as _nx
  File "C:\OSGEO4~1\apps\Python27\lib\site-packages\numpy\core\__init__.py", line 26, in <module>
    raise ImportError(msg)
ImportError:
Importing the multiarray numpy extension module failed.  Most
likely you are trying to import a failed build of numpy.
If you're working with a numpy git repo, try `git clean -xdf` (removes all
files not under version control).  Otherwise reinstall numpy.

Original error was: DLL load failed: %1 is not a valid Win32 application.

The script we're using works fine in Cygwin on multiple machines, so we know that it's not the script itself, but rather something to do with our OSGEO installations. I have installed and uninstalled numpy in my OSGEO4W64 Python2.7 installation numerous times, both using

pip install --update

and using Gohlke's pre-compiled Numpy+MKL binary wheel. My numpy and scipy package installations have all been the correct bit type for my Python installation (64 bit).
Oddly enough, I can import numpy without issue when I call it directly in the OSGeo4W shell.

While I've seen numerous potential solutions for this error online, they almost universally apply to Anaconda installations, and I have no idea how to apply them to OSGEO4W.

A few things about my system:
I'm running Win10 64bit, with the Python2.7 installation that came with OSGEO. My OSGEO and QGIS installs are up to date. For reasons beyond my control, I cannot switch to using Python 3.x, and I do not have Administrative access to my computer without a call to the company Helpdesk, so I generally cannot set my own Python environment paths. There is also another installation of Python2.7 on my computer courtesy of ArcGIS.