While working as a GIS Specialist, there were times when I needed to know the GPS locations of a lot of places based on their physical address. The fastest and easiest way I found to do this was to use Google Maps.
Here is how:
Go to maps.google.com
Type in the address that you are interested in. Here I put the Department of Geology and Geophysics at the University of Utah (my alma mater).
Then if you look at the actual web address you will notice there are two GPS localities listed. The blue circle (on the left) is the GPS address of the center of the page. If you shift the map, this will change accordingly. It is not necessarily the GPS address of the point you input, if the page loads with your location off center (as often happens). The red circled address (at the end of the web address) is the actual address of the point you input. To show you where you can use that, you can take the numbers and put them in ArcMap as seen below.
In the default toolbar, there is a button called "Go to XY". Click on it.
A box will pop up with Longitude and Latitude boxes.
Type in the second number first, this is your longitude. Include the negative sign if applicable. Then type the first number in the second box. This is your latitude. When you hit "Enter", a flash will appear on the map where your point is. It also converts the Decimal Degrees of Google Maps to Degrees Minutes Seconds. You can click on the "Add Point" above the coordinates to put a green dot in that spot. Then you have to zoom in manually.
And if you put in the second GPS coordinates, you will get a dot precisely where Google Maps puts the address, which is more often than not, correct. Although there are instances where this isn't always the case.
Showing posts with label GIS Tips. Show all posts
Showing posts with label GIS Tips. Show all posts
Wednesday, November 30, 2016
Thursday, November 10, 2016
GIS "Pro" Tips - Creating watersheds from a DEM
To create the watersheds for a specific area on a DEM, first you will want to create or use a set of streamlines (previous streamline creation is detailed HERE). Obviously, as with anything else, this method is not perfect. You may find that other methods work better for you. As I do with all my GIS stuff, take what works for you and change it to fit your needs.
Watershed Area:
With the creation of streamlines that are better than the DEM valued streams (as described previously)- do the following to obtain watersheds, and Longest Flow Paths.
There may be better ways within Archydro to perform the following watershed tools. Perhaps by using the Catchment tool, which is essentially the Watershed tool under Spatial Analyst/Hydrology. Thinking about it, the Catchment tool may be the way to go but I haven't figured out a good way to do it, so here is my method.
There is sometimes other things that you may want to do with watersheds after they have been created. Here are the most common ones I have done:
Create Longest Flow Path for all watersheds:
Create the Stream 10-85 Slope (the slope of the stream from 10% to 85% of the stream's length):
Calculate Precipitation averages or centroid values:
Other ArcHydro Tools of Note:
Watershed Area:
With the creation of streamlines that are better than the DEM valued streams (as described previously)- do the following to obtain watersheds, and Longest Flow Paths.
- Simplify stream lines, especially if the vertex density is high on the streams. This will speed up the burning process. I think a simplified line with a Point Removal variance of 5 ft should be fine.
- Assign HydroID’s to the lines.
- Convert streams to ArcHydro Drainage Lines using “Create Drainage Line Structures”
- I often get an error running this tool, even though the “DrainageLine” file that is created is complete. Check the DrainageLine file to make sure the number of streams is the same as the original file. If it is, you should be fine.
- Use those Drainage Line Structures to burn into a DEM using “DEM Reconditioning”.
- Leave values as default except set “Sharp drop/raise” = 100
- Run “Fill Sinks” tool on burned DEM
- Fill all
- Run “Flow Direction” tool
- Run “Flow Accumulation” tool
There may be better ways within Archydro to perform the following watershed tools. Perhaps by using the Catchment tool, which is essentially the Watershed tool under Spatial Analyst/Hydrology. Thinking about it, the Catchment tool may be the way to go but I haven't figured out a good way to do it, so here is my method.
- Using new point file, place points on Accumulation raster, just upstream of confluences for each stream segment.
- Give each point a unique ID (=FID+1)
- Run Snap Pour Point tool
- Run Watershed tool
- Convert Watershed Raster to polygon
- This will create a "catchment area" file. The watersheds that are delineated are really just the isolated sections that is being drained between confluences.
- To create a file with the actual watersheds you are going to need to do some work. Starting with the furthest upstream catchments, this is what I do:
- Adjust watersheds so they actually go to the end of the streamlines to confluence and make sure they represent the actual watershed area.
- Sometimes roads, culverts, and other diversion structures don't show up on the DEM and LiDAR data so the watersheds form incorrectly. You may need to adjust the watersheds individually to match what actually should be the water drainage area.
- If the watershed is the most upstream for that particular line segment, then the watershed should then be complete. Moving down to the next confluence you should have a three catchments that make up one watershed, the two watersheds at the end of the streamlines and the area between the first confluence and the next one. What I do to maintain the proper number of watersheds is I select the two end watersheds. Then I copy and paste them into the watershed file. The copy and paste would leave those two new ones selected. Then, while still holding down select I select the third watershed (the stream segment that runs into the confluence I am interested in) and I select "merge" and merge the three streams together into one large watershed.
- I continue through the entire watershed area until all the subwatersheds have been adjusted and built properly.
-------------------------------------------------------------------------------------------------------------------
There is sometimes other things that you may want to do with watersheds after they have been created. Here are the most common ones I have done:
Create Longest Flow Path for all watersheds:
- Take the Watershed shapefile and the Flow Direction file and run the “Longest Flow Path” tool.
- HydroID may need to be run on the watersheds first.
Create the Stream 10-85 Slope (the slope of the stream from 10% to 85% of the stream's length):
- ArcHydro:
- Watershed Processing --> Flow Path Parameters --> Flow Path Parameters from 2D Line
- Input:
- Longest Flow Path
- Burned DEM (See above)
- Output will be in same location as mxd.
- In the output file:
- Verify lengths. If incorrect, recalculate.
- Verify Elevations, should be correct.
- Recalculate out Slope1085: “([ElevUP]-[ElevDS])/(0.75* [LengthMi])”
- Zero out other slopes.
Calculate Precipitation averages or centroid values:
- ArcHydro: Attribute Tools --> Compute Local Parameters
- Deselect all --> Select PRECIPIN (For average values) or PRECIP (for centroid values)
- Select the Watershed File
- Select Precipitation File (in same coordinate system as watershed file)
Other ArcHydro Tools of Note:
- Watershed Processing --> Basin Length Points
- This creates a point shapefile for the beginning and ending of each streamline. Good for determining total slope when the slope tool isn’t working right.
Wednesday, November 09, 2016
GIS "Pro" Tips - Creating Streamlines from a DEM
One of the things I needed to do a few times for my GIS job was to create streamlines and watersheds for a specific area using DEM and LiDAR data. Below is my workflow for creating streamlines from a DEM using ArcHydro (a free and very useful toolbar from ESRI).
Creating streamlines:
Within the ArcHydro tool set do the following processes:
Creating streamlines:
Within the ArcHydro tool set do the following processes:
- Identify all dams and lakes within the area which are going to affect water flow.
- Create lines across the dams to simulate where the water will flow if the dam were not damming the water.
- Take the Dam line file and Assign HydroID’s to the lines.
- Convert the dams lines to ArcHydro Drainage Lines using “Create Drainage Line Structures”
- I often get an error running this tool, even though the “DrainageLine” file that is created is complete. Check the DrainageLine file to make sure the number of streams is the same as the original file. If it is, you should be fine.
- Take a DEM and run the following Terrain Preprocessing tools in order to condition the DEM:
- DEM Manipulation --> DEM Reconditioning:
- Use the new “DrainageLine”/Dam lines as the AGREE Stream
- Leave values as default except set “Sharp drop/raise” = 100
- This creates an AgreeDEM
- Take the AgreeDEM and Fill the sinks: DEM Manipulation Fill Sinks
- Use default values for everything
- Take the Fill grid and run the “Flow Direction”
- Take the Flow Direction grid and run “Flow Accumulation”
- Take the Flow Accumulation grid (“Fac” if you left the defaults) and change the Symbology. Change it to Classified with 2 classes. Then change the division of the two classes to around 5,000 or 10,000. The lower the number the more streams you are going to have. Play around with it until you get something that is useful and not overwhelming. Then make the 0 – 10,000 (or whatever) range no color, and the other range black (or whatever color you want to visualize it in).
- When you find a value that you like, run the “Stream Definition” tool. Set the Flow Accumulation Grid, the under Number of Cells, put the number you figured out in the previous step.
- Take the resulting Stream grid, and run the “Raster to Polyline” tool in arcmap (not in ArcHydro unless I missed it somewhere).
- Input Raster is the Str grid
- Field will be “Value”
- Background value is “NODATA”
- And check the simplify polylines option
- Your output will be a Polyline shapefile of your stream network. You will want to take these streams and “fix” them to better match the DEM and aerial for the area you are working on. Bridges, dams, and other culverts mess up where the water should actually flow so these will need to be readjusted to what their flow patterns should actually be. Once all of the streams have been adjusted as they should be move on to calculating out the watersheds for each area.
Friday, November 04, 2016
GIS "Pro" Tips - Merging Rasters
Often in GIS you come across situations where you need to merge together rasters in order to have one file to work off of (Digital Elevation Models (DEMs), aerial images, etc.). I have found that it gets a bit tricky sometimes to merge those together and get everything to align properly and/or not have any issues. Below is a list of suggested guidelines to follow while merging together multiple rasters. This was started and expanded upon from advice by a co-worker while I was working my GIS job and I figured I would share it since I could never find anything on the internet that was as clear and concise.
Tool: In the search field type in “Mosaic to New Raster”
In the Mosaic to New Raster Tool:
Input rasters: Bring them in any order, doesn't matter.
Output location: Save them to a different folder from the one they're in. It just seems to help thing from crashing. Assign it to the C Drive.
Raster Dataset name with extension: Short name (13 characters or less), no spaces. Do not give it an extension.
Spatial reference: Blank. It'll revert to whatever the projection of the source rasters is, which is what you want.
Pixel Type: 32-bit float
Cellsize: Blank. It'll default to the sources' cell size.
Number of Bands: 1
Mosaic operator: Last…unless they don't overlap and/or your data comes from multiple sources.
Mosaic Colormap Mode: Default.
The important part:
Click on the Environments button then click on Processing Extent. Pick one of your input rasters as your Snap Raster. This makes sure that your new cell edges match up with the original and that nothing shifts over. This is real important with datasets that have large cell sizes, but you want your data to line up regardless.
This is one of those tools that doesn't work sometimes for no good reason. If that happens, just try again.
When merging 2 overlapping rasters of different tile size
Sometimes you may want to combine rasters with two different tile sizes. This may be you have a DEM and you want to incorporate areas with higher resolution data like LiDAR within the DEM area. To do this within the Mosaic to New Raster tool:
Some useful information and websites
The USGS has a nationwide ~10 meter DEM map available for download for free.
The information is located at the National Elevation Dataset (NED): http://viewer.nationalmap.gov/basic/
You can find lots of free information available for various areas across the nation (DEMs, aerials, watersheds, etc.) and if you zoom into your area of interest you can find what information is available. The 10m DEM is referred to as the “1/3 arc-second DEM”. This means that it is approximately 1/3rd of a degree of latitude and longitude. The 1/3rd arc-second equals approximately a 10m DEM (A 10m DEM is a DEM where each pixel is 10 meters by 10 meters), while the 1/9th arc-second DEMs equal approximately a 3m DEM.
You can also find where freely available LiDAR data is located here:
http://earthexplorer.usgs.gov/
Tool: In the search field type in “Mosaic to New Raster”
In the Mosaic to New Raster Tool:
Input rasters: Bring them in any order, doesn't matter.
Output location: Save them to a different folder from the one they're in. It just seems to help thing from crashing. Assign it to the C Drive.
Raster Dataset name with extension: Short name (13 characters or less), no spaces. Do not give it an extension.
Spatial reference: Blank. It'll revert to whatever the projection of the source rasters is, which is what you want.
Pixel Type: 32-bit float
Cellsize: Blank. It'll default to the sources' cell size.
Number of Bands: 1
Mosaic operator: Last…unless they don't overlap and/or your data comes from multiple sources.
Mosaic Colormap Mode: Default.
The important part:
Click on the Environments button then click on Processing Extent. Pick one of your input rasters as your Snap Raster. This makes sure that your new cell edges match up with the original and that nothing shifts over. This is real important with datasets that have large cell sizes, but you want your data to line up regardless.
This is one of those tools that doesn't work sometimes for no good reason. If that happens, just try again.
When merging 2 overlapping rasters of different tile size
Sometimes you may want to combine rasters with two different tile sizes. This may be you have a DEM and you want to incorporate areas with higher resolution data like LiDAR within the DEM area. To do this within the Mosaic to New Raster tool:
- Give the LIDAR DEM (or whatever the higher resolution data is) the mosaic operator highest priority.
- Set cell size as the same as the LiDAR DEM (or whatever the higher resolution data is).
- In environments:
- Set the raster analysis to min of inputs cell size.
- Use the LiDAR DEM as snap raster
Some useful information and websites
The USGS has a nationwide ~10 meter DEM map available for download for free.
The information is located at the National Elevation Dataset (NED): http://viewer.nationalmap.gov/basic/
You can find lots of free information available for various areas across the nation (DEMs, aerials, watersheds, etc.) and if you zoom into your area of interest you can find what information is available. The 10m DEM is referred to as the “1/3 arc-second DEM”. This means that it is approximately 1/3rd of a degree of latitude and longitude. The 1/3rd arc-second equals approximately a 10m DEM (A 10m DEM is a DEM where each pixel is 10 meters by 10 meters), while the 1/9th arc-second DEMs equal approximately a 3m DEM.
You can also find where freely available LiDAR data is located here:
http://earthexplorer.usgs.gov/
Subscribe to:
Posts (Atom)
