|
| 1 | +=== Floodplains |
| 2 | + |
| 3 | +This section explains how to extract floodplains across the DEM. We have provided some example datasets which you can use in order to test the floodplain extraction. If you are using the vagrant distribution, we recommend that you create a new directory in the `Topographic_projects` directory for each field site that you analyse. Navigate to the `Topographic_projects` directory using the `cd` command: |
| 4 | + |
| 5 | +[source,console] |
| 6 | +---- |
| 7 | +$ pwd |
| 8 | +/LSDTopoTools/Git_projects/ |
| 9 | +$ cd .. |
| 10 | +$ cd Topographic_projects/ |
| 11 | +---- |
| 12 | + |
| 13 | +In this tutorial we will work using a LiDAR dataset from Mid Bailey Run, Ohio. You should make a new directory for the Mid Bailey Run DEM in the `Topographic_projects` directory: |
| 14 | + |
| 15 | +[source,console] |
| 16 | +---- |
| 17 | +$ mkdir Mid_Bailey_Run/ |
| 18 | +$ cd Mid_Bailey_Run/ |
| 19 | +---- |
| 20 | + |
| 21 | +You can get the DEM for Mid Bailey Run from our ExampleTopoDatasets repository using `wget`: |
| 22 | + |
| 23 | +[source,console] |
| 24 | +---- |
| 25 | +$ wget https://github.com/LSDtopotools/ExampleTopoDatasets/raw/master/Bailey_DEM.bil |
| 26 | +$ wget https://github.com/LSDtopotools/ExampleTopoDatasets/raw/master/Bailey_DEM.hdr |
| 27 | +---- |
| 28 | + |
| 29 | +This dataset is already in the preferred format for use with LSDTopoTools (the ENVI `bil` format). The figure below shows a shaded relief map of part of the South Fork Eel River DEM which will be used in these examples. |
| 30 | + |
| 31 | +.Shaded relief image of Mid Bailey Run, OH, USA, UTM Zone 17N |
| 32 | +image::images/Bailey_map.png[Shaded relief map of Mid Bailey Run, Ohio, 500, 600, align='center'] |
| 33 | + |
| 34 | +==== Get the example parameter files |
| 35 | + |
| 36 | +We have also provided some examples parameter files that are used to run the floodplain delineation. You can get the example floodplain driver using `wget`: |
| 37 | + |
| 38 | +[source,console] |
| 39 | +---- |
| 40 | +$ wget https://github.com/LSDtopotools/ExampleTopoDatasets/tree/master/example_parameter_files/ExampleFiles_FloodplainTerraceExtraction/LSDTT_floodplains.param |
| 41 | +---- |
| 42 | +This should be placed in the same folder as your DEM and the channel heads `csv` file. The example from Mid Bailey Run is called `LSDTT_floodplains.param` and should look like this: |
| 43 | + |
| 44 | +[source,paramfile] |
| 45 | +---- |
| 46 | +# This is a driver file for LSDTopoTools |
| 47 | +# Any lines with the # symbol in the first row will be ignored |
| 48 | +
|
| 49 | +# File information |
| 50 | +dem read extension: bil |
| 51 | +dem write extension: bil |
| 52 | +read path: /LSDTopoTools/Topographic_projects/Mid_Bailey_Run/ |
| 53 | +read fname: Bailey_DEM |
| 54 | +write fname: Bailey_DEM |
| 55 | +CHeads_file: Bailey_DEM_Wsources |
| 56 | +
|
| 57 | +# Parameters for floodplain extraction |
| 58 | +Filter topography: true |
| 59 | +Min slope filling: 0.0001 |
| 60 | +surface_fitting_window_radius: 6 |
| 61 | +Threshold_SO: 3 |
| 62 | +Relief lower percentile: 25 |
| 63 | +Relief upper percentile: 75 |
| 64 | +Slope lower percentile: 25 |
| 65 | +Slope upper percentile: 75 |
| 66 | +QQ threshold: 0.005 |
| 67 | +Min patch size: 1000 |
| 68 | +---- |
| 69 | +You can run the analysis on the Mid Bailey Run DEM using the example parameter file, and modify it as you wish for your own DEM. |
| 70 | + |
| 71 | +WARNING: You must make sure the description of the parameter in your file matches EXACTLY to the example, or the code will not recognise the parameter properly. If in doubt, check your spelling. |
| 72 | + |
| 73 | +The table below explains the function of each of these parameters: |
| 74 | + |
| 75 | +[cols="1,1,2", options="header"] |
| 76 | +.Explanation of the parameters used for terrace extraction |
| 77 | +|=== |
| 78 | +|Parameter name |
| 79 | +|Data type |
| 80 | +|Description |
| 81 | + |
| 82 | +|dem read extension |
| 83 | +|String |
| 84 | +|The file extension of your input DEM |
| 85 | + |
| 86 | +|dem write extension |
| 87 | +|String |
| 88 | +|The file extension of the output rasters |
| 89 | + |
| 90 | +|read path |
| 91 | +|String |
| 92 | +|The path to your DEM and parameter file |
| 93 | + |
| 94 | +|read fname |
| 95 | +|String |
| 96 | +|The name of your DEM *without extension* |
| 97 | + |
| 98 | +|CHeads_file |
| 99 | +|String |
| 100 | +|The name of the channel heads csv file *without extension* |
| 101 | + |
| 102 | +|Filter topography |
| 103 | +|Boolean |
| 104 | +|Switch to run the filtering and filling of the DEM. Only set to false if you want to re-run the analysis (to save time). |
| 105 | + |
| 106 | +|Min slope filling |
| 107 | +|float |
| 108 | +|Minimum slope for filling the DEM, suggested to be 0.0001 |
| 109 | + |
| 110 | +|surface_fitting_window_radius |
| 111 | +|float |
| 112 | +|Window radius for calculating slope, should be calculated using the window size routines |
| 113 | + |
| 114 | +|Threshold_SO |
| 115 | +|integer |
| 116 | +|Threshold Strahler stream order for the nearest channel. A value of 3 should work in most landscapes. |
| 117 | + |
| 118 | +|Relief lower percentile |
| 119 | +|integer |
| 120 | +|Lower percentile for fitting Gaussian distribution to relief from quantile-quantile . Leave as 25 unless you have a weird quantile-quantile plot for the landscape. |
| 121 | + |
| 122 | +|Relief upper percentile |
| 123 | +|integer |
| 124 | +|Upper percentile for fitting Gaussian distribution to relief from quantile-quantile plots. Leave as 75 unless you have a weird quantile-quantile plot for the landscape. |
| 125 | + |
| 126 | +|Slope lower percentile |
| 127 | +|integer |
| 128 | +|Lower percentile for fitting Gaussian distribution to slope from quantile-quantile plots. Leave as 25 unless you have a weird quantile-quantile plot for the landscape. |
| 129 | + |
| 130 | +|Slope upper percentile |
| 131 | +|integer |
| 132 | +|Upper percentile for fitting Gaussian distribution to rslope from quantile-quantile plots. Leave as 75 unless you have a weird quantile-quantile plot for the landscape. |
| 133 | + |
| 134 | +|QQ threshold |
| 135 | +|float |
| 136 | +|Threshold for calculating difference between the real and Gaussian distributions from the quantile-quantile plots. Leave as 0.005 unless you have a weird quantile-quantile plot for the landscape. |
| 137 | + |
| 138 | +|Min patch size |
| 139 | +|integer |
| 140 | +|Minimum number of pixels for each floodplain patch, can use to remove very small patches which may be due to noise. |
| 141 | + |
| 142 | +|=== |
| 143 | + |
| 144 | +==== Compiling the code |
| 145 | + |
| 146 | +Before the code can be run, you must compile it. To do this you need to go to the `driver_functions_Floodplains-Terraces` directory in the folder `LSDTopoTools_FloodplainTerraceExtraction`. Navigate to the folder using the command: |
| 147 | + |
| 148 | +[source,console] |
| 149 | +---- |
| 150 | +$ cd /LSDTopoTools/Git_projects/LSDTopoTools_FloodplainTerraceExtraction/driver_functions_Floodplains-Terraces/ |
| 151 | +---- |
| 152 | + |
| 153 | +and compile the code with: |
| 154 | + |
| 155 | +[source,console] |
| 156 | +---- |
| 157 | +$ make -f get_floodplains.make |
| 158 | +---- |
| 159 | + |
| 160 | +This may come up with some warnings, but should create the file `get_floodplains.out`. You can then run the program with: |
| 161 | + |
| 162 | +[source,console] |
| 163 | +---- |
| 164 | +$ ./get_floodplains.out /path/to/DEM/location/ name_of_parameter_file.param |
| 165 | +---- |
| 166 | + |
| 167 | +For our example, the command would be: |
| 168 | + |
| 169 | +[source,console] |
| 170 | +---- |
| 171 | +$ ./get_floodplains.out /LSDTopoTools/Topographic_projects/Eel_River/ LSDTT_floodplains.param |
| 172 | +---- |
| 173 | + |
| 174 | +The program should take between 10 - 40 minutes to run, depending on the size of your DEM and your processing power. Once it is completed, you will have a number of `bil` files which you can open in a GIS of your choice. These files will include: |
| 175 | + |
| 176 | +. *DEM_name_filtered.bil and .hdr*: The original DEM after Perona-Malik filtering |
| 177 | +. *DEM_name_channel_relief.bil and .hdr*: A raster of elevations compared to the nearest channel |
| 178 | +. *DEM_name_slope.bil and .hdr*: A raster of local gradient |
| 179 | +. *DEM_name_qq_relief.txt and _qq_slope.txt*: Text files with the quantile-quantile plot information. This can be plotted in our python script to check whether the thresholds selected were appropriate. |
| 180 | +. *DEM_name_FP.bil and .hdr*: A raster of floodplain locations. |
| 181 | + |
| 182 | +An example of the floodplains extracted from the Mid Bailey Run catchment is shown below. You should be able to get a raster similar to this by opening the file `Bailey_DEM_FP.bil` in a GIS of your choice. |
| 183 | + |
| 184 | +.Floodplains extracted for the Mid Bailey Run catchment, Ohio. |
| 185 | +image::images/Bailey_FP.png[Mid Bailey Run floodplains, align='center'] |
0 commit comments