Difference between revisions of "XPSWMM Conversion Export SWMM Pipe Network Data"

From Tuflow
Jump to navigation Jump to search
 
(7 intermediate revisions by 2 users not shown)
Line 6: Line 6:
 
[[File: XPSWMM_to_TUFLOW_toolbar_hydraulics_mode_01a.png|700px]]
 
[[File: XPSWMM_to_TUFLOW_toolbar_hydraulics_mode_01a.png|700px]]
 
<br>
 
<br>
<li> From the XPSWMM top dropdown menu, select '''File > Import/Export Data > Export to EPASWMM5'''. The exported file will have a .inp extension and will be saved with the same name and in the same folder location as the XPSWMM .xp project file.  
+
<li> From the XPSWMM top dropdown menu, select File > Import/Export Data > Export to EPASWMM5. The exported file will have a .inp extension and will be saved with the same name and in the same folder location as the XPSWMM .xp project file.  
 
<li> When prompted to save changes, select 'Yes'.  
 
<li> When prompted to save changes, select 'Yes'.  
 
<li> In Windows File Explorer, navigate to the folder containing the XPSWMM project folder and rename the exported INP file by adding 'HDR' to the file name. For example, '''1D2D_Urban_001.inp''' becomes '''1D2D_Urban_HDR_001.inp'''.  
 
<li> In Windows File Explorer, navigate to the folder containing the XPSWMM project folder and rename the exported INP file by adding 'HDR' to the file name. For example, '''1D2D_Urban_001.inp''' becomes '''1D2D_Urban_HDR_001.inp'''.  
Line 15: Line 15:
 
<li> Click 'Run'. After the tool is finished, click 'Close'.
 
<li> Click 'Run'. After the tool is finished, click 'Close'.
 
<li> A dialog will appear. Select 'Add Layers' to open all vectors within the newly created SWMM GeoPackage file. By default, all items in the available list should have been selected. Within the "Options" section, make sure "Add layers to group" is selected.
 
<li> A dialog will appear. Select 'Add Layers' to open all vectors within the newly created SWMM GeoPackage file. By default, all items in the available list should have been selected. Within the "Options" section, make sure "Add layers to group" is selected.
<li> In the QGIS Layers panel, move the SWMM GeoPackage file to the top of the list. This will ensure the data within this database file is displayed above all other layers in the project.
+
<li> In the QGIS Layers panel, move the SWMM HDR GeoPackage files to the top of the list. This will ensure the data within this database file is displayed above all other layers in the project.
 
<li> Inspect the layer objects and associated attributes in the GeoPackage database to familiarize yourself with the data.
 
<li> Inspect the layer objects and associated attributes in the GeoPackage database to familiarize yourself with the data.
 
<br><br>
 
<br><br>
Line 22: Line 22:
 
</ol>
 
</ol>
  
The process above has created a '''Nodes--Junctions''' layer containing all the model nodes. During the previous <u>[[XPSWMM_Conversion_TUFLOW_Structure |Convert XPSWMM Model to Recommended TUFLOW Structure]]</u> section, an improperly formatted layer of the same nodes was generated from XPSWMM. To prevent future errors or confusion, this layer should be removed from the QGIS workspace and deleted from its GeoPackage.  
+
The process above has created a '''Nodes--Junctions''' layer containing all the model nodes. During the previous <u>[[XPSWMM_Conversion_TUFLOW_Structure_Archive |Convert XPSWMM Model to Recommended TUFLOW Structure]]</u> section, an improperly formatted layer of the same nodes was generated from XPSWMM. To prevent future errors or confusion, this layer should be removed from the QGIS workspace and deleted from its GeoPackage.  
 
<ol>
 
<ol>
<li> In the QGIS Layers panel, open the tbc group (e.g. '''1D2D_Urban_001.tbc'''). Right click the 2d_bc points layer and select 'Remove Layer...'.
+
<li> In QGIS, from the top dropdown menu options, select View > Panels. Tick on 'Browser Panel'.
<li> From the top dropdown menu options, select View > Panels. Tick on 'Browser Panel'.
+
<li> In the QGIS Browser panel, navigate to the '''TUFLOW\model\gis''' folder and open the GeoPackage layer tree (e.g. '''1D2D_Urban_001.gpkg''').<br>
<li> In the QGIS Browser panel, navigate to the '''TUFLOW\model\gis''' folder and open the GeoPackage layer tree.<br>
 
 
''Note: Within the QGIS Browser panel, there is a dropdown directory called 'Project Home'. This directory is a shortcut to the location where the QGIS workspace is saved. If you have not saved the QGIS project before now, this option will not be available. However, you can achieve the same result by expanding the file path tree in the Browser Panel.''  
 
''Note: Within the QGIS Browser panel, there is a dropdown directory called 'Project Home'. This directory is a shortcut to the location where the QGIS workspace is saved. If you have not saved the QGIS project before now, this option will not be available. However, you can achieve the same result by expanding the file path tree in the Browser Panel.''  
 
<li> Right click the 2d_bc points layer (e.g.'''1D2D_Urban_001_2d_bc_P''') and select Manage > Delete Layer.
 
<li> Right click the 2d_bc points layer (e.g.'''1D2D_Urban_001_2d_bc_P''') and select Manage > Delete Layer.
 +
<li> This will delete the 2d_bc points layer from the GeoPackage, and remove the layer from the QGIS workspace.
 
<br><br>
 
<br><br>
{{Video|name=Animation_XPtoTUFLOW_1D_model_02d.mp4|width=1350}}
+
{{Video|name=Animation_XPtoTUFLOW_1D_model_02e.mp4|width=1350}}
 
<br>
 
<br>
 
</ol>
 
</ol>

Latest revision as of 09:56, 20 August 2024

Export 1D EPA SWMM Pipe Network Data from XPSWMM

We will now export 1D XPSWMM hydraulics features into an EPA SWMM 5 INP file format and configure the dataset for TUFLOW:

  1. In XPSWMM, select 'Hydraulics Mode' from the toolbar.

    XPSWMM to TUFLOW toolbar hydraulics mode 01a.png
  2. From the XPSWMM top dropdown menu, select File > Import/Export Data > Export to EPASWMM5. The exported file will have a .inp extension and will be saved with the same name and in the same folder location as the XPSWMM .xp project file.
  3. When prompted to save changes, select 'Yes'.
  4. In Windows File Explorer, navigate to the folder containing the XPSWMM project folder and rename the exported INP file by adding 'HDR' to the file name. For example, 1D2D_Urban_001.inp becomes 1D2D_Urban_HDR_001.inp.
  5. Copy the renamed INP file into the TUFLOW\model\swmm folder. From this folder, drag and drop the .inp file into QGIS. This will open the 'GeoPackage - Create from SWMM inp ' tool from the QGIS Processing Toolbox.
    • SWMM Input File (inp): Pre-populated
    • CRS for GeoPackage: Select the appropriate Coordinate Reference System (CRS) for the model.
    • GeoPackage output filename: This field should be prefilled to save the output GeoPackage file using the same name and in the same folder location as the SWMM input file.
  6. Click 'Run'. After the tool is finished, click 'Close'.
  7. A dialog will appear. Select 'Add Layers' to open all vectors within the newly created SWMM GeoPackage file. By default, all items in the available list should have been selected. Within the "Options" section, make sure "Add layers to group" is selected.
  8. In the QGIS Layers panel, move the SWMM HDR GeoPackage files to the top of the list. This will ensure the data within this database file is displayed above all other layers in the project.
  9. Inspect the layer objects and associated attributes in the GeoPackage database to familiarize yourself with the data.


The process above has created a Nodes--Junctions layer containing all the model nodes. During the previous Convert XPSWMM Model to Recommended TUFLOW Structure section, an improperly formatted layer of the same nodes was generated from XPSWMM. To prevent future errors or confusion, this layer should be removed from the QGIS workspace and deleted from its GeoPackage.

  1. In QGIS, from the top dropdown menu options, select View > Panels. Tick on 'Browser Panel'.
  2. In the QGIS Browser panel, navigate to the TUFLOW\model\gis folder and open the GeoPackage layer tree (e.g. 1D2D_Urban_001.gpkg).
    Note: Within the QGIS Browser panel, there is a dropdown directory called 'Project Home'. This directory is a shortcut to the location where the QGIS workspace is saved. If you have not saved the QGIS project before now, this option will not be available. However, you can achieve the same result by expanding the file path tree in the Browser Panel.
  3. Right click the 2d_bc points layer (e.g.1D2D_Urban_001_2d_bc_P) and select Manage > Delete Layer.
  4. This will delete the 2d_bc points layer from the GeoPackage, and remove the layer from the QGIS workspace.



Up
Go-up.png Continue to Next Step: "Configure 1D EPA SWMM Pipe Network Data"
Up
Go-up.png Back to Main XPSWMM to TUFLOW Conversion Page