Difference between revisions of "Tutorial M03 GIS Inputs QGIS GPKG"

From Tuflow
Jump to navigation Jump to search
(Created page with "= Introduction = QGIS is used to create, import and view input data.<br> <br> = TUFLOW Project Re-Configuration = Re-configure the TUFLOW project to use and save empty files...")
 
 
(11 intermediate revisions by the same user not shown)
Line 11: Line 11:
 
<li>Click 'OK' and save the workspace by selecting Project > Save As.<br>
 
<li>Click 'OK' and save the workspace by selecting Project > Save As.<br>
 
<br>
 
<br>
[[File:M03_SHP_ConfigureProject.PNG]]<br><br>
+
[[File:M03_GPKG_ConfigureProject.PNG]]<br><br>
 
<li>Set the workspace projection to EPSG:32760, see <u>[[Tutorial_Site_Familiarisation_QGIS#Set_the_Projection | Set the Projection]]</u>.
 
<li>Set the workspace projection to EPSG:32760, see <u>[[Tutorial_Site_Familiarisation_QGIS#Set_the_Projection | Set the Projection]]</u>.
 
</ol>
 
</ol>
Line 17: Line 17:
  
 
= Method =  
 
= Method =  
Navigate to the '''Module_03\Tutorial_Data''' folder. Copy and save all the below layers into the '''Module_03\TUFLOW\model\gis''' folder:
+
Set up the GeoPackage Database:
:*1d_nwk_M03_culverts_001_L
+
<ol>
:*2d_bc_M03_culverts_001_L
+
<li>Navigate to the '''Module_03\TUFLOW\model\gis''' folder. Save a copy of '''M02_001.gpkg''' as '''M03_001.gpkg'''.
:*2d_bc_M03_culverts_001_R
+
<li>Within the QGIS Browser Panel, right click on 'Favorites' and select 'Add a Directory...'.
 +
<li>Navigate to the '''Module_03''' folder and select it.
 +
</ol>
 +
Within the QGIS Browser Panel, navigate to the '''Module_03\Tutorial_Data''' folder. Drag and drop the following layers into the '''M03_001.gpkg''':
 +
:*'''1d_nwk_M03_culverts_001_L'''
 +
:*'''2d_bc_M03_culverts_001_L'''
 +
:*'''2d_bc_M03_culverts_001_R'''
  
 
Investigate the supplied files:
 
Investigate the supplied files:
 
<ol>
 
<ol>
<li>Open the files, either: <br>
+
<li>Open the files, either:
:*Drag and drop the .shp files into the QGIS workspace; or
+
:*Within the QGIS Browser Panel, navigate to '''M03_001.gpkg''' and double click the layers, or
:*Select Layer > Add layer > Add Vector Layer and navigate to the '''Module_03\TUFLOW\model\gis''' folder.  
+
:*In File Explorer, drag and drop the '''M03_001.gpkg''' into the QGIS workspace and select the layers (hold Ctrl to select multiple).
:*Select ‘Apply TUFLOW Styles to Open Layers’.
+
<li>Use the ‘Apply TUFLOW Styles to Open Layers’.
:*Right click on the '''1d_nwk_M03_culverts_001_L''' layer and turn on 'Show Labels'.
+
<li>Left click the '''1d_nwk_M03_culverts_001_L''' layer and select 'Apply Label to Current Layer'.
 
<li>The 1d_nwk layer represents culverts placed under the road embankments crossing the flow paths.  See Table 5-3 of the <u>[https://downloads.tuflow.com/_archive/TUFLOW/Releases/2018-03/TUFLOW%20Manual.2018-03.pdf 2018 TUFLOW Manual]</u> for more information on the attributes.<br>
 
<li>The 1d_nwk layer represents culverts placed under the road embankments crossing the flow paths.  See Table 5-3 of the <u>[https://downloads.tuflow.com/_archive/TUFLOW/Releases/2018-03/TUFLOW%20Manual.2018-03.pdf 2018 TUFLOW Manual]</u> for more information on the attributes.<br>
 
<br>
 
<br>
[[File:Animation M03 GIS 01.gif]]<br>
+
{{Video|name=Animation_M03_GPKG_GIS_01a.mp4|width=1279}}<br>
 
<br>
 
<br>
  
Line 38: Line 44:
  
 
<br>
 
<br>
[[File:Animation_M03_GIS_02a.gif]]<br>
+
{{Video|name=Animation_M03_GPKG_GIS_02.mp4|width=1279}}<br>
 
<br>
 
<br>
 
</ol>
 
</ol>
Line 47: Line 53:
 
<li>Select '2d_bc' from the Empty Type list.
 
<li>Select '2d_bc' from the Empty Type list.
 
<li>In the Run ID box write: 'M03_culverts_001'.
 
<li>In the Run ID box write: 'M03_culverts_001'.
<li>Tick the 'Points' Geometry Type and hit 'OK'. The 2d_bc appears in the Layers panel.
+
<li>Tick the 'Points' Geometry Type.
<li> Zoom to the unconnected 1D culvert. <br>
+
<li>In the Spatial Database Options, select 'All to one'. Navigate to the '''Module_03/TUFLOW/model/gis''' folder and select '''M03_001.gpkg'''. Click Save and hit 'OK'.
 +
<li>The '''2d_bc_M03_culverts_001_P''' appears in the Layers panel.
 +
<li>Zoom to the unconnected 1D culvert. <br>
 
<li>Enable snapping, it is important the points are snapped to the network line.
 
<li>Enable snapping, it is important the points are snapped to the network line.
 
:*Right click anywhere in the Toolbar panel and tick on the Snapping Toolbar.  
 
:*Right click anywhere in the Toolbar panel and tick on the Snapping Toolbar.  
Line 61: Line 69:
  
 
<br>
 
<br>
[[File:Animation M03 GIS 03A.gif]]<br>
+
{{Video|name=Animation_M03_GPKG_GIS_03.mp4|width=1279}}<br>
 
<br>
 
<br>
 
</ol>
 
</ol>

Latest revision as of 12:34, 14 August 2023

Introduction

QGIS is used to create, import and view input data.

TUFLOW Project Re-Configuration

Re-configure the TUFLOW project to use and save empty files to the correct folder:

  1. Go to Plugins > TUFLOW > Editing > Configure / Create TUFLOW Project.
  2. Change the folder which contains TUFLOW to the Module_03 folder. This is the only change required, the model folder structure and template empty files are supplied from previous model.
    Note: The 'results' and 'check' folder get automatically created when the TUFLOW model is run.
  3. Click 'OK' and save the workspace by selecting Project > Save As.

    M03 GPKG ConfigureProject.PNG

  4. Set the workspace projection to EPSG:32760, see Set the Projection.


Method

Set up the GeoPackage Database:

  1. Navigate to the Module_03\TUFLOW\model\gis folder. Save a copy of M02_001.gpkg as M03_001.gpkg.
  2. Within the QGIS Browser Panel, right click on 'Favorites' and select 'Add a Directory...'.
  3. Navigate to the Module_03 folder and select it.

Within the QGIS Browser Panel, navigate to the Module_03\Tutorial_Data folder. Drag and drop the following layers into the M03_001.gpkg:

  • 1d_nwk_M03_culverts_001_L
  • 2d_bc_M03_culverts_001_L
  • 2d_bc_M03_culverts_001_R

Investigate the supplied files:

  1. Open the files, either:
    • Within the QGIS Browser Panel, navigate to M03_001.gpkg and double click the layers, or
    • In File Explorer, drag and drop the M03_001.gpkg into the QGIS workspace and select the layers (hold Ctrl to select multiple).
  2. Use the ‘Apply TUFLOW Styles to Open Layers’.
  3. Left click the 1d_nwk_M03_culverts_001_L layer and select 'Apply Label to Current Layer'.
  4. The 1d_nwk layer represents culverts placed under the road embankments crossing the flow paths. See Table 5-3 of the 2018 TUFLOW Manual for more information on the attributes.




  5. The 2d_bc layers use SX type connection to embed 1D networks into the 2D domain. It removes water out of the upstream cell(s) and deposits water back at the downstream cell(s). Both region and line SX links need a CN (connection) line snapped from the upstream and downstream vertex of the 1D network line to the SX boundary.



Connect the last 1D network culvert to 2D domain:

  1. Click on the ‘Import Empty File’ tool from the TUFLOW plugin toolbar.
  2. Select '2d_bc' from the Empty Type list.
  3. In the Run ID box write: 'M03_culverts_001'.
  4. Tick the 'Points' Geometry Type.
  5. In the Spatial Database Options, select 'All to one'. Navigate to the Module_03/TUFLOW/model/gis folder and select M03_001.gpkg. Click Save and hit 'OK'.
  6. The 2d_bc_M03_culverts_001_P appears in the Layers panel.
  7. Zoom to the unconnected 1D culvert.
  8. Enable snapping, it is important the points are snapped to the network line.
    • Right click anywhere in the Toolbar panel and tick on the Snapping Toolbar.
    • Select the magnet icon 'Enable Snapping' and 'All Layers > Advanced Configuration', an eye icon appears.
    • Select the eye icon 'Edit Advanced Configuration' and tick the 1d_nwk_M03_culverts_001_L.
  9. Right click on the 2d_bc_M03_culverts_001_P and toggle on editing.
  10. Select 'Add Point Feature'.
  11. Digitise a point snapped to upstream end and downstream end of the 1d_nwk layer.
  12. When terminating each point, an attributes dialog is displayed. Enter Type as 'SX'.
  13. Turn off editing to save the edits.
  14. The point SX connection selects a single cell at the upstream and downstream of the 1d_nwk layer.



Conclusion

  • 1D network culverts were set up and connected to the 2D domain with 1D/2D links.


Up
Go-up.png Back to Module 3 Main Page