Monthly Archives: March 2014

Quantarctica – Free GIS Data for QGIS

A QGIS specific free GIS dataset is available for downloading from the Quantarctica site (QGIS + Antarctica).  The GIS data contains geography, glaciology and geophysics data originally developed for in-house use at the the Norwegian Polar Institute.  Quantarctica was first released for public consumption in July of 2013 and there are plans to expand the data offerings with contributions from the research community.  The data is free for noncommercial use.

Users can download a base package which is 7GB in size.  The base package includes GIS base map vector and raster data, and scientific data covering geophysics and glaciology.  Geography data includes place name, facility, grounded ice, ice shelf, and outcrops.  Glaciology data includes ice thickness, ice-flow speed, and subglacial lakes.  Geophysics data includes geoid heights, and magnetic anomalies.  The data is available at a range of scales from continental to local.

QGIS 1.8 is also bundled in the package. Those users that want to individually download Quantarctica’s datasets can do so via the Quantarctica FTP server.  Also available from thedownload page are high resolution imagery datasets such as Landsat MOS and RADARSAT images.

quanarctica-GIS

Users can sign up at the bottom of the home page with their email addresses to receive updates to the Quantarctica site.

Advertisements

Extract Multi-band Raster Values from Points using R

rasStack <- stack(“D:/Dropbox/Research/Data/Mesonet/KKF/kkf01.tif”)

pointCoordinates=read.csv(“D:/Dropbox/Research/Data/Mesonet/ok_stations_coordinates.csv”)
coordinates(pointCoordinates)= ~ LONGITUDE+ LATITUDE
rasValue=extract(rasStack, pointCoordinates)

write.csv(rasValue,”D:/Dropbox/Research/Data/Mesonet/combinedPointValue.csv”)
combinePointValue=cbind(pointCoordinates@data,rasValue)
write.csv(combinePointValue,”D:/Dropbox/Research/Data/Mesonet/combinedPointValue.csv”)

Extract Raster Values from Points using R

The R blog article encourages me to write this solution to extract Raster values from points in R.
In geospatial analysis, extracting the raster value of a point is a common task. If you have few raster files or few points; you can extract the raster value by overlaying a point on the top of the raster using ArcGIS. What will you do, if you have hundreds of raster files and thousands of points? The easy solution is use loop in Python and ArcGIS. Is loop efficient to use? No. Can loop be avoided? Yes.
Then how?
Follow the steps:
Step 1: Create a Raster stack or Raster brick of your raster files using “raster” package in R.
For example:
rasStack = stack(raster1, raster2,raster3 …rasterN)
Step 2:  Read point data, and convert them into spatial points data frame.
Sample: pointfile.csv
Point_ID
LONGITUDE
LATITUDE
1
48.765863
-94.745194
2
48.820552
-122.485318
3
48.233939
-107.857685
4
48.705964
-99.817363
For example:
pointCoordinates=read.csv(“pointfile.csv”)
coordinates(pointCoordinates)= ~ LONGITUDE+ LATITUDE
Step 3: Extract raster value by points
For example:
rasValue=extract(rasStack, pointCoordinates)
Step 4:  Combine raster values with point and save as a CSV file.
For example:
combinePointValue=cbind(pointCoordinates,rasValue)
write.table(combinePointValue,file=“combinedPointValue.csv”, append=FALSE, sep= “,”, row.names = FALSE, col.names=TRUE)
Step 5: You should get the results as following table.
Result: combinedPointValue.csv
Point_ID
LONGITUDE
LATITUDE
raster1
raster2
raster3
1
48.765863
-94.745194
200
500
-100
2
48.820552
-122.485318
178.94
18.90
10.94
3
48.233939
-107.857685
-30.74
-30.74
-0. 4
4
48.705964
-99.817363
0
110
-0.7

 

Test Matrix Multiplication on MathNet.Numerics

Imports MathNet.Numerics

Public Class Form1

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

End Sub

Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click

Dim startTime As DateTime = DateTime.Now
Dim a As MathNet.Numerics.LinearAlgebra.Double.Matrix

a = MathNet.Numerics.LinearAlgebra.Double.DenseMatrix.Create(3000, 3000, 2.0)

Dim b As MathNet.Numerics.LinearAlgebra.Double.Matrix

b = MathNet.Numerics.LinearAlgebra.Double.DenseMatrix.Create(3000, 3000, 1.5)

Dim c As MathNet.Numerics.LinearAlgebra.Double.Matrix

c = a.Multiply(b)

Dim endTime As DateTime = DateTime.Now

Dim runTime As TimeSpan = endTime.Subtract(startTime)

MessageBox.Show(“Start Time: ” & startTime & vbNewLine & “End Time: ” & endTime & vbNewLine & “Run Time: ” & runTime.Minutes & ” minutes, ” & runTime.Seconds & ” seconds”, “Time used”)

MessageBox.Show(c.ToString)
End Sub
End Class

Installing ImageIO-Ext on GeoServer

ImageIO-Ext is a bit different than other GeoServer extension, as the pure the ImageIO-Ext library files are built into GeoServer by default. However, in order for GeoServer to leverage these libraries, the ImageIO-Ext native libraries must be installed through your host system’s OS. Once those libraries are installed, GeoServer will be able to recognize GDAL data types (this will require a Tomcat restart).

  1. Navigate to the imageio-ext download page.
  2. Select the most recent stable binary release.
  3. Select “native”.
  4. Select “gdal”.
  5. Download and extract the GDAL CRS definitions:
    • Click on the “gdal_data.zip” to download the CRS definitions archive.
    • Extract this archive on disk and place it in a proper directory on your system.

    Note

    Make sure to set a GDAL_DATA environment variable to the folder where you have extracted this file.

  6. Select the folder related to your OS.
  7. Download and extract/install the correct version for your OS:
    • Assuming you are on a 64 bits Linux Operating System, click on the “gdal1.7.3-linux64-base-gcc43.tar.gz” to download the native libraries archive (If the OS is Windows check the end of the page).
    • Extract the archive on disk and place it in a proper directory on your system.

    Warning

    If you are on Windows, make sure that the GDAL DLL files are on your PATH. If you are on Linux, be sure to set the LD_LIBRARY_PATH environment variable to refer to the folder where the SOs are extracted.

    Note

    The native libraries contains the GDAL gdalinfo utility which can be used to test whether or not the libs are corrupted. This can be done by browsing to the directory where the libs have been extracted and performing a gdalinfo command with the formats options that shows all the formats supported. Moreover the package contains also a Java versions of the gdalinfo utility to check also the Java bindings correct functioning (you can see a .bat script for Windows and .sh for Linux).

Extra Steps for Windows Platforms

There are a few things to be careful with as well as some extra steps if you are deploying on Windows.

First of all, you’ll notice that we have multiple versions like MSVC2005, MSVC2008 and so on macthing the Microsoft Visual C++ Redistributables. Depending on the version of the underlying operating system you’ll have to pick up the right one. You can google around for the one you need.

That said, we have DLLs for both 32 bits as well as 64 bits Operating Systems. Again, pick the one that matches your infrastructure.

Adding support for ECW and MrSID on Windows

If you are on Windows and you want to add support for ECW and MrSID there is an extra step to perform.

In the Windows packaging ECW and MrSID are built as plugins hence they are not loaded by default but we need to place their DLLs in a location that is pointed by the GDAL_DRIVER_PATHenvironmental variable. GDAL uses internally this env variable to look up additional drivers (notice that there are a few default places where GDAL will look anyway). For additional information, please, check this link.

Final Result

Once the previous steps have been completed, restart GeoServer. If all the steps have been performed correctly, new data formats will be in the Raster Data Sources list when creating a new data store as shown here below.

../_images/gdalcreate.pngGDAL image formats in the list of raster data stores

If you use a GDAL (Base drivers + MrSID and ECW support) native libraries, all the data formats will be in the Raster Data Sources list are the following:

../_images/gdalcreate1.pngGDAL image formats in the list of raster data stores with ECW support

Warning

Native libraries: GDAL (Base drivers + MrSID and ECW support). Only download it if you have read _README_FIRST_ and you have agreed with the ECW EULA. Note that these binaries are not meant to be used freely in server side apps, consult the ECW license for details.

GDAL Image Formats on GeoServer

GeoServer can leverage the ImageI/O-Ext GDAL libraries to read selected coverage formats. GDAL is able to read many formats, but for the moment GeoServer supports only a few general interest formats and those that can be legally redistributed and operated in an open source server.

The following image formats can be read by GeoServer using GDAL:

Installing GDAL extension

From GeoServer version 2.2.x, GDAL must be installed as an extension. To install it:

  1. Navigate to the GeoServer download page
  2. Find the page that matches the version of the running GeoServer.

    Warning

    Be sure to match the version of the extension with that of GeoServer, otherwise errors will occur.

  3. Download the GDAL extension. The download link for GDAL will be in the Extensions section underCoverage Store.
  4. Extract the files in this archive to the WEB-INF/lib directory of your GeoServer installation.

Moreover, in order for GeoServer to leverage these libraries, the GDAL (binary) libraries must be installed through your host system’s OS. Once they are installed, GeoServer will be able to recognize GDAL data types. See bloe for more information.

Installing GDAL native libraries

The ImageIO-Ext GDAL plugin for geoserver master uses ImageIO-Ext 1.1.7 whose artifacts can be downloaded from here.

Browse to the native and then gdal directory for the link. Now you should see a list of artifacts that can be downloaded. We need to download two things now:

  1. The CRS definitions
  2. The native libraries matching the target operating system

Let’s now install the CRS definitions.

  • Click on the “gdal_data.zip” to download the CRS definitions archive.
  • Extract this archive on disk and place it in a proper directory on your system.
  • Create a GDAL_DATA environment variable to the folder where you have extracted this file. Make also sure that this directory is reachable and readable by the application server process’s user.

We now have to install the native libraries.

  • Assuming you are on a 64 bits Ubuntu 11 Linux Operating System (as an instance), click on the linux folder and then on “gdal192-Ubuntu11-gcc4.5.2-x86_64.tar.gz” to download the native libraries archive (Before doing this, make sure to read and agree with the ECWEULA if you intend to use ECW).
  • Extract the archive on disk and place it in a proper directory on your system.

    Warning

    If you are on Windows, make sure that the GDAL DLL files are on your PATH. If you are on Linux, be sure to set the LD_LIBRARY_PATH environment variable to refer to the folder where the SOs are extracted.

    Note

    The native libraries contains the GDAL gdalinfo utility which can be used to test whether or not the libs are corrupted. This can be done by browsing to the directory where the libs have been extracted and performing a gdalinfo command with the formats options that shows all the formats supported. Moreover the package contains also a Java versions of the gdalinfo utility to check also the Java bindings correct functioning (you can see a .bat script for Windows and .sh for Linux).

Once these steps have been completed, restart GeoServer. If all the steps have been performed correctly, new data formats will be in the Raster Data Sources list when creating a new data store as shown here below.

../../_images/gdalcreate.pngGDAL image formats in the list of raster data stores

If instead now new formats appear in the GUI and in the logs the following messages is shown:

it.geosolutions.imageio.gdalframework.GDALUtilities loadGDAL WARNING: Native library load failed.java.lang.UnsatisfiedLinkError: no gdaljni in java.library.path

that means that the installations failed for some reason.

Extra Steps for Windows Platforms

There are a few things to be careful with as well as some extra steps if you are deploying on Windows.

First of all, you’ll notice that we have multiple versions like MSVC2005, MSVC2008 and so on macthing the Microsoft Visual C++ Redistributables. Depending on the version of the underlying operating system you’ll have to pick up the right one. You can google around for the one you need.

That said, we have DLLs for both 32 bits as well as 64 bits Operating Systems. Again, pick the one that matches your infrastructure.

Note on running GeoServer as a Service on Windows

Simply deploying the GDAL ImageI/O-Ext native libraries in a location referred by the PATH environment variable (like, as an instance, the JDK/bin folder) doesn’t allow GeoServer to leverage on GDAL, when run as a service. As a result, during the service startup, GeoServer log reports this worrysome message:

it.geosolutions.imageio.gdalframework.GDALUtilities loadGDAL WARNING: Native library load failed.java.lang.UnsatisfiedLinkError: no gdaljni in java.library.path

Taking a look at the wrapper.conf configuration file available inside the GeoServer installation (at bin/wrapper/wrapper.conf), there is this useful entry:

# Java Library Path (location of Wrapper.DLL or libwrapper.so) wrapper.java.library.path.1=bin/wrapper/lib

To allow the GDAL native DLLs getting loaded, you have 2 possible ways:

  1. Move the native DLLs on the referred path (bin/wrapper/lib)
  2. Add a wrapper.java.library.path.2=path/where/you/deployed/nativelibs entry just after the wrapper.java.library.path1=bin/wrapper/lib line.

Adding support for ECW and MrSID on Windows

If you are on Windows and you want to add support for ECW and MrSID there is an extra step to perform.

In the Windows packaging ECW and MrSID are built as plugins hence they are not loaded by default but we need to place their DLLs in a location that is pointed by the GDAL_DRIVER_PATH environmental variable. GDAL uses internally this env variable to look up additional drivers (notice that there are a few default places where GDAL will look anyway). For additional information, please, check this link.

Configuring a DTED data store

../../_images/gdaldtedconfigure.pngConfiguring a DTED data store

Configuring a EHdr data store

../../_images/gdalehdrconfigure.pngConfiguring a EHdr data store

Configuring a ERDASImg data store

../../_images/gdalerdasimgconfigure.pngConfiguring a ERDASImg data store

Configuring a JP2MrSID data store

../../_images/gdaljp2mrsidconfigure.pngConfiguring a JP2MrSID data store

Configuring a NITF data store

../../_images/gdalnitfconfigure.pngConfiguring a NITF data store

Lynda.com – Up and Running with ArcGIS

Lynda.com – Up and Running with ArcGIS

110429072427383025.jpg

3h 13m | Beginner | Mar 11, 2014

Get up and running with ArcGIS, a true geographic information system (GIS) that allows you to dig into highly accurate geospatial data in a way other mapping applications can’t compete with. It’s great creating maps, analyzing data for land use studies and other reports, and preparing data for use in an application or database. Let Adam Wilbert show you how to display, analyze, and illustrate geospatial data with ArcGIS. He explores how to import data from multiple sources, manage it with the ArcGIS catalog, and then start making maps. Learn how to lay out your data in the ArcMap component; add symbols, scale bars, and legends; and get your maps out of ArcGIS and into the real world, whether it’s for printing or export to another application.

Topics include:

  • Understanding vector vs. raster data
  • Modifying metadata
  • Adding data to a map
  • Importing data from online providers
  • Labeling features
  • Joining data
  • Clipping data to a study area
  • Working with map layouts
  • Creating a legend
  • Printing and exporting the map to a file

Home Page:  http://www.lynda.com/ArcGIS-tutorials/Up-Running-ArcGIS/147014-2.html

Remote Sensing Curriculum and Exercises

The lab exercises linked below were developed by AmericaView members using ERDAS IMAGINE version 10 and eCognition version 8.  They are offered freely and ‘as is’ for the use of educators and can be adapted to meet educational purposes.  AmericaView does not endorse any specific software and has no official ties to ERDAS or eCognition or any of their affiliates. The exercises were developed for undergraduate and graduate students and focus on specific geoprocessing techniques and geographic regions but can be adapted to support educational needs at a variety of levels and using other types of data, depending on the lab and associated processing technique(s).  They all come with public domain datasets, but data of other areas can be downloaded and substituted for those provided. Our primary purpose is to help our partners and others who are teaching or would like to teach remote sensing science.

We would gladly welcome feedback and suggestions for making these resources more useful. Please let us know what you think (emailJohn McGee or Rick Landenberger).

Level:  Intermediate / Advanced
Topic:  Exercise 1:  Digital Image Processing
Software:  ERDAS Imagine ver. 10.
Data:  Landsat:  Download here (132 MB, .zip file)
Level:  Intermediate / Advanced
Topic:  Exercise 2:  Digital Image Processing
Tasks / Skills:  Radiometric Correction, Part I (editable MS Word file)
Software:  ERDAS Imagine ver. 10.
Data:  Landsat: Download here (Landsat TM Scene, 160 MB, .zip file) and  Download other data here (other data, 37 MB, .zip file).
Level:  Intermediate / Advanced
Topic:  Exercise 3:  Digital Image Processing
Tasks / Skills:  Radiometric Correction, Part II (editable MS Word file)
Software:  ERDAS Imagine ver. 10.
Data:  Landsat:  Download here (140 MB, .zip file)
Level:  Intermediate / Advanced
Topic:  Exercise 4:  Digital Image Processing
Tasks / Skills: Geometric Correction (editable MS Word file)
Software: ERDAS Imagine ver. 10.
Data:  Landsat:  Download here (66 MB, .zip file)
Level:  Intermediate / Advanced
Topic:  Exercise 5:  Digital Image Processing
Tasks / Skills:  Histogram Strectching and Spatial Filters (editable MS Word file)
Software: ERDAS Imagine ver. 10.
Data:  Landsat:  Download here (38 MB, .zip file)
Level:  Intermediate / Advanced
Topic:  Exercise 6:  Digital Image Processing
Tasks / Skills:   Principal Components Analysis: Part I (editable MS Word file)
Software: ERDAS Imagine ver. 10.  Other remote sensing software can also be used.
Data:  Landsat:  Download here (150 MB, .zip file)
Level:  Intermediate / Advanced
Topic:  Exercise 7:  Digital Image Processing
Tasks / Skills:  Supervised Classification (editable MS Word file)
Software: ERDAS Imagine ver. 10.
Data:  Landsat:  Download here (330 MB, .zip file)
Level:  Intermediate / Advanced
Topic:  Exercise 8:  Digital Image Processing
Tasks / Skills:  Unsupervised Classification (editable MS Word file)
Software: ERDAS Imagine ver. 10.
Data:  Landsat:  Download here (210 MB, .zip file)
Level:  Advanced
Topic:  Exercise 9:  Digital Image Processing
Tasks / Skills:   Change Detection (editable MS Word file)
Software: ERDAS Imagine ver. 10.
Data:  Landsat:  Download here (33 MB, .zip file)
Level:  Advanced
Topic:  Exercise 10:  Digital Image Processing
Tasks / Skills:   Object-Based Classification and e-Cognition Software (editable MS Word file)
Software: eCognition ver. 8.
Data:  Landsat:  Download here (360 MB, .zip file)
Level:  Advanced
Topic:  Exercise 11:  Digital Image Processing (extra credit!)
Tasks/Skills:  Multi-Date Image Normalization Using Regression (editable MS Word file)
Software: ERDAS Imagine ver. 10.
Data:  Landsat: Spreadsheet download here and Image download here (360 MB, .zip file)
Level:  Introductory
Topic:  Introduction to ERDAS Imagine
Software: ERDAS Imagine ver. 10.
Data:  Landsat, DEM and ALOS:  Download here
Level:  Introductory
Topic: Lab 1 – Digital Image Processing:  Loading remote sensing data
Tasks / Skills: Creating an Image Data File from Binary (Byte) Data  (editable MS Word file  | .pdf version available)
Software: ERDAS Imagine ver. 10.
Data:  There are two parts to this exercise.  To complete both parts, you will need to download both Lab 1, Part 1 (69 MB) and Lab 1, Part 2 (142 MB).
Level: Introductory / Intermediate
Topic: Lab 2 – Virtual GIS
Tasks / Skills:  Explore a database using a 3-D View and analysis tool (editable MS Word file  | .pdf version available)
Software: ERDAS Imagine ver. 10.
Data:  DEM and landcover files: Download here (<1 MB).
Level:  Intermediate
Topic: Lab 3: Digital Image Processing
Tasks / Skills:  Formatting Imagery:  Creating Image Mosaics (editable MS Word file  |  .pdf version available)
Software: ERDAS Imagine ver.10.
Data:  There are 3 parts to this exercise.  To complete all 3 parts, you will need to download  Lab 3, Part 1 (<1 MB), Lab 3, Part 2 (<1 MB) and Lab 3, Part 3 (1 MB).
Level:  Introductory / Intermediate
Topic: Lab 4:  Displaying Images
Software:  Erdas Imagine ver. 10.
Data:  Landsat, 1m aerial photography, 10 m satellite image product, 15 m satellite image product, 30 m satellite image product: Download here (13 MB).
Level:  Intermediate / Advanced
Topic: Lab 5:  Supervised Classification by the Parallelepiped Method
Software: ERDAS Imaging ver.10.
Data:  Landsat:  Download here (18 MB).
Level:  Advanced
Topic: Lab 6: Profiles of DEM’s and Change Detection by Using the DEM’s
Tasks / Skills:    Change detection analysis through image subtraction  (editable MS Word file  | .pdf version available) 
Software: ERDAS Imagine ver. 10.
Data: DEM’s:  Download here (< 1 MB).
Level: Advanced
Topic:  Lab 7 – Radar Image and Edge Enhancement
Tasks / Skills: Texture analysis using synthetic aperture radar (SAR)  (editable MS Word file  | .pdf version available)
Software: ERDAS Imagine ver. 10.
Data: Data for this exercise can be Downloaded here (53 MB).

 

eCognition Tutorials

Object-Oriented Resources

Course Manual

The Object-oriented course manual covers each of the 8 online units as an Adobe PDF. The manual can be printed to serve as a useful companion when working within the Definiens software, rather than switching between windows on you computer desktop.

Object-Oriented Manual Download

Download the Object Oriented Manual (5.46 MB)

Course Data

The Object-oriented course data has been compressed for faster download. For information about how to decompress the file please see our unzipping data support page.

Object-Oriented Data Download

Download Unit 1 (~200 MB) Definiens Introduction

Download Unit 2 (~280 MB) Image Segmentation

Download Unit 3 (56 KB) Nearest Neighbour Classification

Download Unit 4 (~280 MB) Rule Based Classification

Download Unit 5 (4.0 KB) Threshold Identification

Download Unit 6 (8.0 KB) Working with Levels

Download Unit 7 (~280 MB) Putting It All Together

Download Unit 8 (210 MB) Calculating Image Thresholds

Download Unit 9 (31.3 MB) Using Fuzzy Membership Functions

– See more at: http://landmap.mimas.ac.uk/index.php/Learning-Materials/Object-oriented-Classification/Resources_OO#sthash.LYqO4UeV.dpuf

Creating WMS with GeoServer on OSGeo Live Virtual Machine

Alex Tereshenkov

Programming and managing GIS

REDD+ for the Guiana Shield

Technical Cooperation Project

LidarBlog.com

Dr. Qiusheng Wu @ SUNY Binghamton

Writing Science

How to write papers that get cited and proposals that get funded

GIS In Ecology

Providing Training, Advice And Consultation On The Use Of GIS In Ecology

metrhispanic

On cities, land, ...

GeoAcademy

Open GIS: No Bounds

Scientia Plus Conscientia

Thoughts on Science and Nature

r4hydrology

Learning hydrology with R

Karl Hennermann

GIS at the University of Manchester

GIS and Science

Applications of geospatial technology for scientific research and understanding.

GISblog.com

GIS, Mapping, Remote Sensing, Geodata, Geospatial news

Whitebox Geospatial Analysis Tools

Open-source GIS development and spatial analysis with Whitebox GAT

TopoToolbox

MATLAB-based software for topographic analysis

Anything Geospatial – AnyGeo

Dr. Qiusheng Wu @ SUNY Binghamton

GeospatialPython.com

Dr. Qiusheng Wu @ SUNY Binghamton

Another GIS Blog

Dr. Qiusheng Wu @ SUNY Binghamton