<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.tuflow.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Chris+Huxley</id>
	<title>Tuflow - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.tuflow.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Chris+Huxley"/>
	<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/Special:Contributions/Chris_Huxley"/>
	<updated>2026-06-03T09:09:27Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.8</generator>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Education_Licence_New_User_Guide&amp;diff=45890</id>
		<title>Education Licence New User Guide</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Education_Licence_New_User_Guide&amp;diff=45890"/>
		<updated>2026-05-05T05:40:17Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;There are a number of options available for University education and research purposes:&lt;br /&gt;
* Teach TUFLOW using the licence free TUFLOW tutorials.&lt;br /&gt;
* Teach TUFLOW or conduct research using your own dataset via TUFLOW&#039;s free education (demo) mode.&lt;br /&gt;
* Purchase a licence for unrestricted use. &lt;br /&gt;
&lt;br /&gt;
The following information is not applicable to commercial use of TUFLOW.&amp;lt;br&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=TUFLOW Tutorial Models=&lt;br /&gt;
Educators are welcome to use the licence free TUFLOW tutorial models and documentation as an education dataset. The benefit of this approach is that there will be no licencing complications for the students. Students will be able to run simulations on any computer at any time. Visit &amp;lt;u&amp;gt;[[Tutorial_Introduction | TUFLOW Wiki Self-teach Tutorials]].&amp;lt;/u&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Educators are welcome to create course content from this dataset. Alternatively, the TUFLOW Team have previously created 10 weeks worth of university teaching material, including 2 weeks worth of assessment, using the tutorial dataset for the guided modelling tasks. If you would like assistance creating similar teaching material please email &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=TUFLOW&#039;s Free Education (Demo) Mode=&lt;br /&gt;
&lt;br /&gt;
Universities are welcome to use TUFLOW&#039;s licence free Demo mode for research or education purposes. The free Demo option is included within the standard TUFLOW executable. It is fully enabled, will function in any geographic region, though has the following limits:&lt;br /&gt;
:*100,000 total cells and 30,000 active (potentially flooded) cells &lt;br /&gt;
:*100 1D channels&lt;br /&gt;
:*There can only be one CPU 2D domain (M2D is not supported). HPC Quadtree is supported. &lt;br /&gt;
:*A simulation time of 10 minutes.&lt;br /&gt;
:*CPU and GPU compute are supported.  &lt;br /&gt;
The free Demo mode is called using the TUFLOW Control File (TCF) command: &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Demo Model &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt;ON&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Educators who would like to teach TUFLOW can create course content that works within the limits of the Demo mode. If you would like assistance creating teaching material using this simulation mode please email &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=TUFLOW Licence=&lt;br /&gt;
To purchase a licence, please email &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt; for a quote.&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Education_Licence_New_User_Guide&amp;diff=45889</id>
		<title>Education Licence New User Guide</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Education_Licence_New_User_Guide&amp;diff=45889"/>
		<updated>2026-05-05T05:39:40Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;There are a number of options available for University education and research purposes:&lt;br /&gt;
* Teach TUFLOW using the licence free TUFLOW tutorials.&lt;br /&gt;
* Teach TUFLOW or conduct research using your own dataset via TUFLOW&#039;s free education (demo) mode.&lt;br /&gt;
* Purchase a licence. &lt;br /&gt;
&lt;br /&gt;
The following information is not applicable to commercial use of TUFLOW.&amp;lt;br&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=TUFLOW Tutorial Models=&lt;br /&gt;
Educators are welcome to use the licence free TUFLOW tutorial models and documentation as an education dataset. The benefit of this approach is that there will be no licencing complications for the students. Students will be able to run simulations on any computer at any time. Visit &amp;lt;u&amp;gt;[[Tutorial_Introduction | TUFLOW Wiki Self-teach Tutorials]].&amp;lt;/u&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Educators are welcome to create course content from this dataset. Alternatively, the TUFLOW Team have previously created 10 weeks worth of university teaching material, including 2 weeks worth of assessment, using the tutorial dataset for the guided modelling tasks. If you would like assistance creating similar teaching material please email &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=TUFLOW&#039;s Free Education (Demo) Mode=&lt;br /&gt;
&lt;br /&gt;
Universities are welcome to use TUFLOW&#039;s licence free Demo mode for research or education purposes. The free Demo option is included within the standard TUFLOW executable. It is fully enabled, will function in any geographic region, though has the following limits:&lt;br /&gt;
:*100,000 total cells and 30,000 active (potentially flooded) cells &lt;br /&gt;
:*100 1D channels&lt;br /&gt;
:*There can only be one CPU 2D domain (M2D is not supported). HPC Quadtree is supported. &lt;br /&gt;
:*A simulation time of 10 minutes.&lt;br /&gt;
:*CPU and GPU compute are supported.  &lt;br /&gt;
The free Demo mode is called using the TUFLOW Control File (TCF) command: &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Demo Model &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt;ON&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Educators who would like to teach TUFLOW can create course content that works within the limits of the Demo mode. If you would like assistance creating teaching material using this simulation mode please email &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=TUFLOW Licence=&lt;br /&gt;
To purchase a licence, please email &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt; for a quote.&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Education_Licence_New_User_Guide&amp;diff=45888</id>
		<title>Education Licence New User Guide</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Education_Licence_New_User_Guide&amp;diff=45888"/>
		<updated>2026-05-05T05:39:27Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* TUFLOW Research Licence */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;There are a number of options available for University education and research purposes:&lt;br /&gt;
* Teach TUFLOW using the licence free TUFLOW tutorials.&lt;br /&gt;
* Teach TUFLOW or conduct research using your own dataset via TUFLOW&#039;s free education (demo) mode.&lt;br /&gt;
* Purchase a research licence. &lt;br /&gt;
&lt;br /&gt;
The following information is not applicable to commercial use of TUFLOW.&amp;lt;br&amp;gt; &lt;br /&gt;
&lt;br /&gt;
=TUFLOW Tutorial Models=&lt;br /&gt;
Educators are welcome to use the licence free TUFLOW tutorial models and documentation as an education dataset. The benefit of this approach is that there will be no licencing complications for the students. Students will be able to run simulations on any computer at any time. Visit &amp;lt;u&amp;gt;[[Tutorial_Introduction | TUFLOW Wiki Self-teach Tutorials]].&amp;lt;/u&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Educators are welcome to create course content from this dataset. Alternatively, the TUFLOW Team have previously created 10 weeks worth of university teaching material, including 2 weeks worth of assessment, using the tutorial dataset for the guided modelling tasks. If you would like assistance creating similar teaching material please email &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=TUFLOW&#039;s Free Education (Demo) Mode=&lt;br /&gt;
&lt;br /&gt;
Universities are welcome to use TUFLOW&#039;s licence free Demo mode for research or education purposes. The free Demo option is included within the standard TUFLOW executable. It is fully enabled, will function in any geographic region, though has the following limits:&lt;br /&gt;
:*100,000 total cells and 30,000 active (potentially flooded) cells &lt;br /&gt;
:*100 1D channels&lt;br /&gt;
:*There can only be one CPU 2D domain (M2D is not supported). HPC Quadtree is supported. &lt;br /&gt;
:*A simulation time of 10 minutes.&lt;br /&gt;
:*CPU and GPU compute are supported.  &lt;br /&gt;
The free Demo mode is called using the TUFLOW Control File (TCF) command: &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Demo Model &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt;ON&amp;lt;/tt&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Educators who would like to teach TUFLOW can create course content that works within the limits of the Demo mode. If you would like assistance creating teaching material using this simulation mode please email &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=TUFLOW Licence=&lt;br /&gt;
To purchase a licence, please email &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt; for a quote.&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=WIBU_Software_Licence_Update_Request&amp;diff=45619</id>
		<title>WIBU Software Licence Update Request</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=WIBU_Software_Licence_Update_Request&amp;diff=45619"/>
		<updated>2026-03-17T05:41:02Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Software licences are an alternative option to hardware USB licences. Please select the license host carefully as the software based dongle will be bound to it. If over time you decide you want to move to another computer we will need to re-issue you with a new software license (which will incur a small administration fee).&lt;br /&gt;
&lt;br /&gt;
If you already have a software lock established, please skip to bullet point 4. If this is the first time you are establishing a software lock, complete all steps.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Email &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt; to request a software licence. You will be sent an empty licence container file (*.wibucmlif). &lt;br /&gt;
&amp;lt;li&amp;gt; If you do not already have Codemeter installed, install &amp;lt;u&amp;gt;[[Wibu_Dongles#Installing_CodeMeter_RunTime_Kit | Codemeter Control Centre]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open Codemeter Control Centre (from the start menu) and drag and drop the provided .wibucmlif onto it. This will import an empty licence container onto the computer (it will show with a grey icon in the licence tab).&lt;br /&gt;
&amp;lt;li&amp;gt; With the licence container selected on the left, click the “Licence Update” option, as per the image below.&amp;lt;br&amp;gt; &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Software_licence_001c.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select “Next” at the next dialogue.&amp;lt;br&amp;gt; &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Software_licence_002c.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select “Create Licence Request”.&amp;lt;br&amp;gt; &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Software_licence_003c.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Save the licence request file to your computer.&amp;lt;br&amp;gt; &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Software_licence_004c.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Email the licence request file (.WibuCmRaC) file to &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=WIBU_Configure_Network_Server&amp;diff=45407</id>
		<title>WIBU Configure Network Server</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=WIBU_Configure_Network_Server&amp;diff=45407"/>
		<updated>2026-01-15T22:51:25Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Introduction=&lt;br /&gt;
This page contains instructions for configuring a network TUFLOW licence.  It requires that you have the CodeMeter Runtime kit installed on the server, see &amp;lt;u&amp;gt;[[Wibu_Dongles#Installing_CodeMeter_RunTime_Kit |Installing CodeMeter Runtime Kit]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For the network license server, during the CodeMeter Runtime kit installation, please select the &amp;quot;Network Server&amp;quot; option. Doing so, CodeMeter will configure TCP and UDP protocols in the Windows Firewall for the server.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:CodeMeter_Network_Server_install_02.png|550px]]&lt;br /&gt;
&lt;br /&gt;
=Method=&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open the CodeMeter Control Centre.  This can be done via the icon on the taskbar:&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:CodeMeter TaskBar.jpg]]&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Or via the start menu:&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:CodeMeter ProgramFiles.jpg|200px]]&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open the &#039;&#039;&#039;WebAdmin&#039;&#039;&#039; via the button in the lower right.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Codemeter_v6.40d_control_center.JPG|400px|]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
This can also be accessed by pointing an internet browser to: [[http://localhost:22352/ http://localhost:22352/]] or [[http://localhost:22353/ http://localhost:22353/]] if you have https configured and provided CodeMeter with a certificate (Note that the port number can be adjusted by your administrator).&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The following CodeMeter webpage will appear.&lt;br /&gt;
&amp;lt;br&amp;gt; &lt;br /&gt;
[[File:Codemeter_v6.40d_WebAdmin.JPG|800px|]]&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;Configuration &amp;gt;&amp;gt; Server &amp;gt;&amp;gt; Server Access&#039;&#039;&#039; tab and enable the &#039;&#039;&#039;Network Server&#039;&#039;&#039; checkbox and hit Apply.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Codemeter_v6.40d_Network_Server.JPG|800px]]&lt;br /&gt;
&amp;lt;li&amp;gt; In CodeMeter WebAdmin navigate to the &#039;&#039;&#039;Configuration &amp;gt;&amp;gt; Basic &amp;gt;&amp;gt; Sever Search List&#039;&#039;&#039; tab:&lt;br /&gt;
&amp;lt;ol&amp;gt; &lt;br /&gt;
* Select &amp;quot;add new Server&amp;quot;&lt;br /&gt;
* Enter the code: 127.0.0.1&lt;br /&gt;
* Click Apply &amp;lt;/li&amp;gt; &lt;br /&gt;
[[File:Codemeter_Network_LocalHost.jpg|800px]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;The network licence should now be available. This can be tested on the server by double clicking the TUFLOW Executable (for example TUFLOW_iSP_w64.exe). A console window should open. Review the licence information listed. Check the licence types and numbers associated with your configuration (the licence types and numbers will be different to the example shown below).&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:TUFLOW_DOS_Test1.JPG|600px]] &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; The next install steps will involve configuring client (modelling) computers to communicate with the server. The client computer will use the IP address of the server for the communication connection. To avoid the server IP address changing due to future actions (such as the server computer being restarted), we recommend configuring the server to use a static IP address.&lt;br /&gt;
&amp;lt;li&amp;gt; Configure client (modelling) computers to communicate with the server: &amp;lt;u&amp;gt; [[WIBU_Configure_Network_Client | Configure Network Client]] &amp;lt;/u&amp;gt;.  &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Troubleshooting=&lt;br /&gt;
If your licences are not listed in the console window when you test whether the server configuration has been successful:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Check whether you have the latest version of Codemeter User Runtime installed. If you do not, update to the latest version: &amp;lt;u&amp;gt;[https://www.wibu.com/support/user/downloads-user-software.html https://www.wibu.com/support/user/downloads-user-software.html]&amp;lt;/u&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; If you are unable to change your version of Codemeter User Runtime, in CodeMeter WebAdmin navigate to the &#039;&#039;&#039;Configuration &amp;gt;&amp;gt; Basic &amp;gt;&amp;gt; Sever Search List&#039;&#039;&#039; tab and enter the server name, computer IP address, or the code: 127.0.0.1 in the &#039;&#039;&#039;Server Search&#039;&#039;&#039; list. After entering the details, click &amp;quot;Add&amp;quot; to save the change. This was a configuration requirement in some old versions of Codemeter User Runtime.&amp;lt;/li&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt; If issues persist, email &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt; &amp;lt;/ol&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=WIBU_Configure_Network_Server&amp;diff=45406</id>
		<title>WIBU Configure Network Server</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=WIBU_Configure_Network_Server&amp;diff=45406"/>
		<updated>2026-01-15T22:51:08Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Method */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Introduction=&lt;br /&gt;
This page contains instructions for configuring a network TUFLOW licence.  It requires that you have the CodeMeter Runtime kit installed on the server, see &amp;lt;u&amp;gt;[[Wibu_Dongles#Installing_CodeMeter_RunTime_Kit |Installing CodeMeter Runtime Kit]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For the network license server, during the CodeMeter Runtime kit installation, please select the &amp;quot;Network Server&amp;quot; option. Doing so, CodeMeter will configure TCP and UDP protocols in the Windows Firewall for the server.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:CodeMeter_Network_Server_install_02.png|550px]]&lt;br /&gt;
&lt;br /&gt;
=Method=&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open the CodeMeter Control Centre.  This can be done via the icon on the taskbar:&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:CodeMeter TaskBar.jpg]]&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Or via the start menu:&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:CodeMeter ProgramFiles.jpg|200px]]&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open the &#039;&#039;&#039;WebAdmin&#039;&#039;&#039; via the button in the lower right.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Codemeter_v6.40d_control_center.JPG|400px|]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
This can also be access by pointing an internet browser to: [[http://localhost:22352/ http://localhost:22352/]] or [[http://localhost:22353/ http://localhost:22353/]] if you have https configured and provided CodeMeter with a certificate (Note that the port number can be adjusted by your administrator).&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The following CodeMeter webpage will appear.&lt;br /&gt;
&amp;lt;br&amp;gt; &lt;br /&gt;
[[File:Codemeter_v6.40d_WebAdmin.JPG|800px|]]&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;Configuration &amp;gt;&amp;gt; Server &amp;gt;&amp;gt; Server Access&#039;&#039;&#039; tab and enable the &#039;&#039;&#039;Network Server&#039;&#039;&#039; checkbox and hit Apply.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Codemeter_v6.40d_Network_Server.JPG|800px]]&lt;br /&gt;
&amp;lt;li&amp;gt; In CodeMeter WebAdmin navigate to the &#039;&#039;&#039;Configuration &amp;gt;&amp;gt; Basic &amp;gt;&amp;gt; Sever Search List&#039;&#039;&#039; tab:&lt;br /&gt;
&amp;lt;ol&amp;gt; &lt;br /&gt;
* Select &amp;quot;add new Server&amp;quot;&lt;br /&gt;
* Enter the code: 127.0.0.1&lt;br /&gt;
* Click Apply &amp;lt;/li&amp;gt; &lt;br /&gt;
[[File:Codemeter_Network_LocalHost.jpg|800px]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;The network licence should now be available. This can be tested on the server by double clicking the TUFLOW Executable (for example TUFLOW_iSP_w64.exe). A console window should open. Review the licence information listed. Check the licence types and numbers associated with your configuration (the licence types and numbers will be different to the example shown below).&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:TUFLOW_DOS_Test1.JPG|600px]] &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; The next install steps will involve configuring client (modelling) computers to communicate with the server. The client computer will use the IP address of the server for the communication connection. To avoid the server IP address changing due to future actions (such as the server computer being restarted), we recommend configuring the server to use a static IP address.&lt;br /&gt;
&amp;lt;li&amp;gt; Configure client (modelling) computers to communicate with the server: &amp;lt;u&amp;gt; [[WIBU_Configure_Network_Client | Configure Network Client]] &amp;lt;/u&amp;gt;.  &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Troubleshooting=&lt;br /&gt;
If your licences are not listed in the console window when you test whether the server configuration has been successful:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Check whether you have the latest version of Codemeter User Runtime installed. If you do not, update to the latest version: &amp;lt;u&amp;gt;[https://www.wibu.com/support/user/downloads-user-software.html https://www.wibu.com/support/user/downloads-user-software.html]&amp;lt;/u&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; If you are unable to change your version of Codemeter User Runtime, in CodeMeter WebAdmin navigate to the &#039;&#039;&#039;Configuration &amp;gt;&amp;gt; Basic &amp;gt;&amp;gt; Sever Search List&#039;&#039;&#039; tab and enter the server name, computer IP address, or the code: 127.0.0.1 in the &#039;&#039;&#039;Server Search&#039;&#039;&#039; list. After entering the details, click &amp;quot;Add&amp;quot; to save the change. This was a configuration requirement in some old versions of Codemeter User Runtime.&amp;lt;/li&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt; If issues persist, email &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt; &amp;lt;/ol&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_Update_Softlock_Import&amp;diff=45398</id>
		<title>WIBU Licence Update Softlock Import</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_Update_Softlock_Import&amp;diff=45398"/>
		<updated>2026-01-09T00:40:45Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Troubleshooting */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Introduction=&lt;br /&gt;
This page describes the process for importing a licence update file for a Wibu dongle.  In order to perform the update, you will need a .WibuCmRaU file that will have been emailed to you by TUFLOW staff, this should be saved on your computer.  If you have this file you can begin the process below!&lt;br /&gt;
=Common Questions=&lt;br /&gt;
&#039;&#039;&#039;I have TUFLOW simulations running, will it stop these?&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
No, we have found that the process below should work, even if simulations are currently running.  If you are worried, simply hold off until your simulations have finished.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Do I need to update the licence on each computer that will use TUFLOW?&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
No, the update file modifies the dongle coding itself, once applied the changes will apply to all computer that use the dongle.  If you try to apply an update file more than once an error will be generated.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;If I update the Wibu licence for a new version of TUFLOW, will I still be able to use current / previous versions of TUFLOW?&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
Yes, if you update the licence for the 2015 maintenance period, you can still use previous versions of TUFLOW such as the 2013 TUFLOW release.&lt;br /&gt;
=Method=&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open the Code Meter Control Centre from the taskbar by double clicking on the following icon [[File:CM CM Stick Green.jpg|20px]].  This can also be opened from the Start Menu.  Once opened the Control Centre should look like the below:&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select the license container item from the list on the left, then Click on the &#039;&#039;&#039;Licence Update&#039;&#039;&#039; button.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update01.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;At the welcome to the CmFAS Assistant screen, bit next to proceed.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update02.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;When prompted to chose the desired action, select &#039;&#039;&#039;Import Licence Update&#039;&#039;&#039; and hit next.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update10.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the .WibuCmRaU file send to you by TUFLOW staff and select this. Click commit to process the update.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update11.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;After a few seconds, you should get a message to say that the licence update has been successful. &lt;br /&gt;
* If this update is associated with deleting a licence and sales@tuflow.com have requested a receipt from you, please click the create receipt &amp;quot;here&amp;quot; link before pressing &amp;quot;Finish&amp;quot;.&lt;br /&gt;
* Otherwise, if this is a standard update and sales@tuflow.com have not requested a receipt, press &amp;quot;Finish&amp;quot;.&lt;br /&gt;
* If you receive a pop-up message that states the licence update was not sucessful, please see the troubleshooting section below.&lt;br /&gt;
[[File:Codemeter_Licence_Update_Complete_MSG.png|800px]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Troubleshooting=&lt;br /&gt;
The following errors are based on emails we&#039;ve received, if you receive a different message or are unable to import an update please see email [mailto:support@tuflow.com support@tuflow.com].  Please include screen images of any relevant error messages.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Error 229 - Update could not be imported.  Contents of CmStick is newer than update&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
This indicates the contents of the dongle are newer than the update being applied. This could occur if:&amp;lt;br&amp;gt;&lt;br /&gt;
* The licence update has already been imported &lt;br /&gt;
* An incorrect (old) update file was applied by mistake&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_Update_Import&amp;diff=45397</id>
		<title>WIBU Licence Update Import</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_Update_Import&amp;diff=45397"/>
		<updated>2026-01-09T00:40:15Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Troubleshooting */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Introduction=&lt;br /&gt;
This page describes the process for importing a licence update file for a Wibu dongle.  In order to perform the update, you will need a .WibuCmRaU file that will have been emailed to you by TUFLOW staff, this should be saved on your computer.  If you have this file you can begin the process below!&lt;br /&gt;
=Common Questions=&lt;br /&gt;
&#039;&#039;&#039;I have TUFLOW simulations running, will it stop these?&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
No, we have found that the process below should work, even if simulations are currently running.  If you are worried, simply hold off until your simulations have finished.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Do I need to update the licence on each computer that will use TUFLOW?&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
No, the update file modifies the dongle coding itself, once applied the changes will apply to all computer that use the dongle.  If you try to apply an update file more than once an error will be generated.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;If I update the Wibu licence for a new version of TUFLOW, will I still be able to use current / previous versions of TUFLOW?&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
Yes, if you update the licence for the 2015 maintenance period, you can still use previous versions of TUFLOW such as the 2013 TUFLOW release.&lt;br /&gt;
=Method=&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; sales@tuflow.com should have emailed you a .WibuCmRaU file for your licence update. Save the file to your computer. Note down the folder location where you have saved it, you will need it to import the file into Code Meter Control Centre. &amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;With the dongle inserted into your computer.  Open the Code Meter Control Centre from the taskbar by double clicking on the following icon [[File:CM CM Stick Green.jpg|20px]].  This can also be opened from the Start Menu.  Once opened the Control Centre should look like the below:&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Click on the &#039;&#039;&#039;Licence Update&#039;&#039;&#039; button.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update01.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;At the welcome to the CmFAS Assistant screen, bit next to proceed.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update02.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;When prompted to choose the desired action, select &#039;&#039;&#039;Import Licence Update&#039;&#039;&#039; and hit next.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update10.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the .WibuCmRaU file send to you by TUFLOW staff and select this. Click commit to process the update.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update11.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;After a few seconds, you should get a message to say that the licence update has been successful. &amp;lt;/li&amp;gt;&lt;br /&gt;
* If this update is associated with deleting a licence and sales@tuflow.com have requested a receipt from you, please click the create receipt &amp;quot;here&amp;quot; link before pressing &amp;quot;Finish&amp;quot;.&lt;br /&gt;
* Otherwise, if this is a standard update and sales@tuflow.com have not requested a receipt, press &amp;quot;Finish&amp;quot;.&lt;br /&gt;
* If you receive a pop-up message that states the licence update was not sucessful, please see the troubleshooting section below.&lt;br /&gt;
[[File:Codemeter_Licence_Update_Complete_MSG.png|800px]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Troubleshooting=&lt;br /&gt;
The following errors are based on emails we&#039;ve received, if you receive a different message or are unable to import an update please see email [mailto:support@tuflow.com support@tuflow.com].  Please include screen images of any relevant error messages.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Error 229 - Update could not be imported.  Contents of CmStick is newer than update&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
This indicates the contents of the dongle are newer than the update being applied. This could occur if:&amp;lt;br&amp;gt;&lt;br /&gt;
* The licence update has already been imported &lt;br /&gt;
* An incorrect (old) update file was applied by mistake&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_for_Linux&amp;diff=45396</id>
		<title>WIBU Licence for Linux</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_for_Linux&amp;diff=45396"/>
		<updated>2026-01-09T00:39:27Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Using the installed licenses */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This article describes the process of setting up a licence container (software licence only) and installing licence updates (network and software licences) from a &amp;lt;i&amp;gt;Linux&amp;lt;/i&amp;gt; command line interface, like you would access on an SSH console.&lt;br /&gt;
&lt;br /&gt;
The Linux commands used on this wiki should work on most modern Linux distributions, but were tested on CentOS and Debian. This article assumes you have downloaded and installed an appropriate version of the [https://www.wibu.com/support/user/user-software.html CodeMeter Runtime (download)] for your Linux host and CodeMeter is running as a service. If you are uncertain, you can run &amp;lt;pre&amp;gt;systemctl | grep codemeter&amp;lt;/pre&amp;gt; and you should see both `codemeter.service` and `codemeter-webadmin.service` as `running` or `exited`. For the CodeMeter service, you can also check &amp;lt;pre&amp;gt;/etc/init.d/codemeter status&amp;lt;/pre&amp;gt; which should report &amp;quot;CodeMeter Server is running.&amp;quot;. By default, your CodeMeter Control Center web application would be hosted on [http://localhost:22350/ http://&amp;lt;your hostname&amp;gt;:22350/].&lt;br /&gt;
&lt;br /&gt;
For a basic setup of CodeMeter on Linux, refer to [[Installing_Wibu_CodeMeter_Linux | Installing Wibu CodeMeter on Linux]].&lt;br /&gt;
&lt;br /&gt;
Software licences are an alternative option to hardware USB dongle licences. Please select the licence host carefully as a software based dongle will be bound to it when it is first imported. If over time you decide you want to move to another computer we will need to re-issue you with a new software licence (which will incur a small administration fee).&lt;br /&gt;
&lt;br /&gt;
==Setting up a new licence container (software licence only)==&lt;br /&gt;
&lt;br /&gt;
Email &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt; to request a software licence. You will be sent an empty licence container file (*.WibuCmLif). &lt;br /&gt;
&lt;br /&gt;
Install the licence container file with:&lt;br /&gt;
&amp;lt;pre&amp;gt;cmu --import --file Universal_Firm_Code_CmActLicense_6000224.WibuCmLif&amp;lt;/pre&amp;gt;&lt;br /&gt;
Which should result in something like:&lt;br /&gt;
&amp;lt;pre&amp;gt;cmu - CodeMeter Universal Support Tool.&lt;br /&gt;
Version 6.60a of 2018-Feb-26 (Build 2878) for Linux&lt;br /&gt;
Copyright (C) 2007-2018 by WIBU-SYSTEMS AG. All rights reserved.&lt;br /&gt;
&lt;br /&gt;
The file contains 1 Update:&lt;br /&gt;
  CmActLtLicense binding information: FirmCode 6000224&lt;br /&gt;
&lt;br /&gt;
Execute Update ...&lt;br /&gt;
The file contains 1 Update:&lt;br /&gt;
  CmActLtLicense update: Serial number xxx-xxxxxxxxxx, FirmCode 6000224.&lt;br /&gt;
   --&amp;gt; successful&lt;br /&gt;
1 successful update done&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
After installing the licence container file, the CodeMeter WebAdmin interface may report an error if you try to check the new container (e.g. &#039;Error 407: Unknown error&#039;). This can be resolved by restarting the CodeMeter service after installing the licence container:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo systemctl restart codemeter.service&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Make a note of the serial number displayed. You can list serial numbers of installed dongles and software licence containers with the command:&lt;br /&gt;
&amp;lt;pre&amp;gt;cmu --list&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Updating licences (network and software licences)==&lt;br /&gt;
&lt;br /&gt;
Once you have an existing licence container, either from a plugged in network dongle or imported software container, you will need to create a licence update request:&lt;br /&gt;
* Network licence:&lt;br /&gt;
&amp;lt;pre&amp;gt;cmu --context 101139 --serial x-xxxxxxx --file x-xxxxxxx.WibuCmRaC&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Software licence:&lt;br /&gt;
&amp;lt;pre&amp;gt;cmu --context 6000224 --serial xxx-xxxxxxxxxx --file xxx-xxxxxxxxxx.WibuCmRaC&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Where &amp;quot;x-xxxxxxx&amp;quot; or &amp;quot;xxx-xxxxxxxxxx&amp;quot; is the serial number of your licence container.&lt;br /&gt;
&lt;br /&gt;
E-mail the created licence request file (.WibuCmRaC) file to &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Once your licence request is processed, you will receive a licence update file (.WibuCmRaU) in return, which you can install with:&lt;br /&gt;
* Network licence:&lt;br /&gt;
&amp;lt;pre&amp;gt;cmu --import --file x-xxxxxxx.WibuCmRaU&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Software licence:&lt;br /&gt;
&amp;lt;pre&amp;gt;cmu --import --file xxx-xxxxxxxxxx.WibuCmRaU&amp;lt;/pre&amp;gt;&lt;br /&gt;
Which should result in something like:&lt;br /&gt;
&amp;lt;pre&amp;gt;cmu - CodeMeter Universal Support Tool.&lt;br /&gt;
Version 6.60a of 2018-Feb-26 (Build 2878) for Linux&lt;br /&gt;
Copyright (C) 2007-2018 by WIBU-SYSTEMS AG. All rights reserved.&lt;br /&gt;
&lt;br /&gt;
The file contains 1 Updates:&lt;br /&gt;
  CmActLtLicense binding information: FirmCode 6000224&lt;br /&gt;
  CmDongle update for 130-3796453031 (FirmCode 6000224).&lt;br /&gt;
&lt;br /&gt;
Execute Update ...&lt;br /&gt;
The file contains 1 Updates:&lt;br /&gt;
  CmActLtLicense update: Serial number xxx-xxxxxxxxxx, FirmCode 6000224.&lt;br /&gt;
   --&amp;gt; successful&lt;br /&gt;
1 successful update done&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Once your licence update has been imported, you should see your installed licences in the CodeMeter WebAdmin. If they fail to show up, restart the CodeMeter Service:&lt;br /&gt;
&amp;lt;pre&amp;gt;sudo systemctl restart codemeter.service&amp;lt;/pre&amp;gt; or &amp;lt;pre&amp;gt;sudo /etc/init.d/codemeter restart&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Using the installed licenses==&lt;br /&gt;
If you are running a model on another machine and have installed the license on a remote license host, refer to &amp;lt;u&amp;gt;[[WIBU_Configure_Network_Server|Wibu Configure Network Server]]&amp;lt;/u&amp;gt; and &amp;lt;u&amp;gt;[[WIBU_Configure_Network_Client|Wibu_Configure Network Client]]&amp;lt;/u&amp;gt; to learn how to connect to it.&lt;br /&gt;
&lt;br /&gt;
If the software license container is the only license container (i.e. you have no dongle installed), you can test using the installed license by simply starting a model run that requires it (i.e. some run other than a benchmark or tutorial model). &lt;br /&gt;
&lt;br /&gt;
However, if you have both a dongle and software license container installed, you can ensure TUFLOW prefers the software license by creating a license control file (.lcf) for your model, with the line: &amp;lt;pre&amp;gt;WIBU Firm Code Search Order == 6000224 101139&amp;lt;/pre&amp;gt; This ensures that TUFLOW will prefer a software license container (6000224) over a dongle license container (101139) to obtain a license. You can learn more about where such a file can be placed and what the followed logic for obtaining a license is in the &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_Update_Request_Uncoded&amp;diff=45395</id>
		<title>WIBU Licence Update Request Uncoded</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_Update_Request_Uncoded&amp;diff=45395"/>
		<updated>2026-01-09T00:39:11Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Troubleshooting */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Introduction=&lt;br /&gt;
This page contains instructions for creating a licence update request for an uncoded or non BMT-WBM Wibu licence.  Unless instructed by TUFLOW staff, the instructions on the following page should be followed instead [[WIBU_Licence_Update_Request | WIBU Licence Update Request]].&amp;lt;br&amp;gt;&lt;br /&gt;
=Method=&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; If you do not already have Codemeter installed, install &amp;lt;u&amp;gt;[[Wibu_Dongles#Installing_CodeMeter_RunTime_Kit | Codemeter Control Centre]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;With the dongle inserted into your computer.  Open the Code Meter Control Centre from the taskbar by double clicking on the following icon [[File:CM CM Stick Green.jpg|20px]].  This can also be opened from the Start Menu.  Once opened the Control Centre should look like the below:&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Click on the &#039;&#039;&#039;Licence Update&#039;&#039;&#039; button.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update01.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;At the welcome to the CmFAS Assistant screen, bit next to proceed.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update02.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;When prompted to chose the desired action, select &#039;&#039;&#039;Create Licence Request&#039;&#039;&#039; and hit next.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update03.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;As the dongle is a new or uncoded dongle you will need to choose &#039;&#039;&#039;Add Licence of New Producer&#039;&#039;&#039; and select next.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update08.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;When prompted to &amp;quot;Enter the Firm Code&amp;quot;, enter &#039;&#039;&#039;101139&#039;&#039;&#039;.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update09.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;You will be asked to set the output file name and location.  When the licence update is processed, this will create a file which you will need to email, so please &#039;&#039;&#039;save in a location that you will remember!&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
Once you have set an output filename, select &#039;&#039;&#039;Commit&#039;&#039;&#039; to create the licence request.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update06.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;After committing, the following screen will be displayed to confirm the licence request has been created.  Select &#039;&#039;&#039;Finish&#039;&#039;&#039; to close this screen.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update07.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;The licence update request can now be emailed to TUFLOW.  Please email the created .WibuCmRaC file through to &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt;. This file will be saved in the location set in step 7.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Troubleshooting=&lt;br /&gt;
If the dongle has been previously used for TUFLOW simulations, then you do not need to add a new producer, and instead the following procedure can be used [[WIBU_Licence_Update_Request | WIBU Licence Update Request (normal)]].&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
If you have any other issues with the licence update request, please email [mailto:support@tuflow.com support@tuflow.com].  Please include screen images of any relevant error messages.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_Update_Request&amp;diff=45394</id>
		<title>WIBU Licence Update Request</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=WIBU_Licence_Update_Request&amp;diff=45394"/>
		<updated>2026-01-09T00:38:50Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Troubleshooting */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Introduction=&lt;br /&gt;
This page contains instructions for creating a licence update request for an existing TUFLOW Wibu (CodeMeter) licence. &lt;br /&gt;
=Method=&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; If you do not already have Codemeter installed, install &amp;lt;u&amp;gt;[[Wibu_Dongles#Installing_CodeMeter_RunTime_Kit | Codemeter Control Centre]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;With the dongle inserted into your computer.  Open the Code Meter Control Center from the taskbar by double clicking on the following icon [[File:CM CM Stick Green.jpg|20px]].  This can also be opened from the Start Menu (under All Programs --&amp;gt; Code Meter --&amp;gt; Code Meter Control Center).  Once opened the Control Center should look like the below:&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Click on the &#039;&#039;&#039;Licence Update&#039;&#039;&#039; button.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update01.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;At the welcome to the CmFAS Assistant screen, bit next to proceed.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update02.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;When prompted to choose the desired action, select &#039;&#039;&#039;Create Licence Request&#039;&#039;&#039; and hit next.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update03.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;Unless you have been instructed by TUFLOW staff, choose &#039;&#039;&#039;Extend Existing Licence&#039;&#039;&#039; and select next.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update04.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;When prompted to &amp;quot;Choose the producer&amp;quot;, select the &#039;&#039;&#039;BMT WBM (101139)&#039;&#039;&#039;.&amp;lt;br&amp;gt;&lt;br /&gt;
This may be the only option, however, if multiple choices are available, please uncheck all except for &#039;&#039;&#039;BMT WBM (101139)&#039;&#039;&#039;.&amp;lt;br&amp;gt;&lt;br /&gt;
If you do not see BMT WBM as a valid licence producer, this could mean that your licence is through a third party (such as Aquaveo) or that your dongle has not yet been coded.  If you are unsure please contact [mailto:support@tuflow.com support@tuflow.com].&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update05.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;You will be asked to set the output file name and location.  When the licence update is processed, this will create a file which you will need to email, so please &#039;&#039;&#039;save the file in a location that you will remember!&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
Once you have set an output filename, select &#039;&#039;&#039;Commit&#039;&#039;&#039; to create the licence request.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update06.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;After committing, the following screen will be displayed to confirm the licence request has been created.  Select &#039;&#039;&#039;Finish&#039;&#039;&#039; to close this screen.&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:CodeMeter Update07.jpg|600px]]&lt;br /&gt;
&amp;lt;li&amp;gt;The licence update request can now be emailed to TUFLOW.  Please email the created .WibuCmRaC file through to &amp;lt;u&amp;gt;[mailto:sales@tuflow.com sales@tuflow.com]&amp;lt;/u&amp;gt;. This file will be saved in the location set in step 7.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Troubleshooting=&lt;br /&gt;
It is important to note that this process needs to be followed for each update request.  If you send through an old file that has already been processed, the licence update will fail.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
If you have any other issues with the licence update request, please email [mailto:support@tuflow.com support@tuflow.com].  Please include screen images of any relevant error messages.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Installing_Wibu_CodeMeter_Linux&amp;diff=45393</id>
		<title>Installing Wibu CodeMeter Linux</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Installing_Wibu_CodeMeter_Linux&amp;diff=45393"/>
		<updated>2026-01-09T00:38:19Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This article provide a basic set of instructions to install the Wibu CodeMeter Runtime on a Linux host through the command line interface (CLI). For more information about using Wibu dongles or software licenses, refer to &amp;lt;u&amp;gt;[[Wibu_Dongles|Wibu Dongles]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The Linux commands used on this wiki should work on most modern Linux distributions, but were tested on CentOS and Debian. Note that these instructions are provided as a courtesy to users new to Linux, please ensure you understand what the commands mean before you run them and be aware of the [[Tuflow:General_disclaimer|general disclaimer]].&lt;br /&gt;
&lt;br /&gt;
==Getting the CodeMeter Runtime==&lt;br /&gt;
&lt;br /&gt;
The appropriate version of the CodeMeter Runtime can be obtained from the Wibu website at &amp;lt;u&amp;gt;[https://www.wibu.com/support/user/downloads-user-software.html https://www.wibu.com/support/user/downloads-user-software.html]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
If you are using Debian, Ubuntu, Mint or another Linux distribution in the Debian family of distributions, you should obtain a copy of the `.deb` installer for your hardware. If you are using Red Hat (RHEL), Fedora, CentOS or another Linux distribution in the Red Hat family of distributions, you should obtain a copy of the `.rpm` installer for your hardware. If your hardware supports 64-bit software (which is likely for modern systems), using that version is recommended. From here on, we&#039;ll refer to &#039;Debian&#039; or &#039;Red Hat&#039; to mean any distribution in that family.&lt;br /&gt;
&lt;br /&gt;
Depending on your level of access to the machine running Linux and whether or not it is running a graphical user interface, you may have some trouble getting the file onto your machine. You can download the file directly from the command line with: &amp;lt;pre&amp;gt;wget -O codemeter.rpm &amp;lt;direct link&amp;gt;&amp;lt;/pre&amp;gt; where &amp;quot;&amp;lt;direct link&amp;gt;&amp;quot; is the &#039;direct link&#039; provided on the Wibu download page for the version you are downloading.&lt;br /&gt;
&lt;br /&gt;
The download page also provides an MD5 checksum. You can run &amp;lt;pre&amp;gt;md5sum codemeter.rpm&amp;lt;/pre&amp;gt; and verify that the file you downloaded was downloaded correctly by comparing this checksum.&lt;br /&gt;
&lt;br /&gt;
If your Linux distribution does not provide `wget`, you can obtain a copy on Debian with `sudo apt-get install wget` and on Red Hat with `sudo yum install wget`.&lt;br /&gt;
&lt;br /&gt;
==Installing the CodeMeter Runtime==&lt;br /&gt;
&lt;br /&gt;
On Red Hat, using `yum`, you can install the CodeMeter Runtime with &amp;lt;pre&amp;gt;sudo yum localinstall codemeter.rpm&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
On Debian, using `dpkg` and `apt-get`, you can install the CodeMeter Runtime with &amp;lt;pre&amp;gt;sudo dpkg -i codemeter.deb&amp;lt;/pre&amp;gt; If that fails due to missing dependencies, you can instead attempt &amp;lt;pre&amp;gt;sudo apt-get -f codemeter.deb&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Once these commands complete (on either Debian or Red Hat), you can start, stop and restart the services with `systemctl`: &amp;lt;pre&amp;gt;sudo systemctl restart codemeter.service&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Alternatively, if `systemctl` is not available to you, you can use: &amp;lt;pre&amp;gt;sudo /etc/init.d/codemeter restart&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Configuring the CodeMeter Runtime==&lt;br /&gt;
&lt;br /&gt;
Refer to the CodeMeter manual for instructions on configuring CodeMeter. &lt;br /&gt;
&lt;br /&gt;
However, if you are installing CodeMeter as a client for network licenses, the following is an example of a section you can add to the `/etc/wibu/CodeMeter/Server.ini`: &amp;lt;pre&amp;gt;[ServerSearchList]&lt;br /&gt;
UseBroadcast=1&lt;br /&gt;
&lt;br /&gt;
[ServerSearchList\Server1]&lt;br /&gt;
Address=&amp;lt;ip number of your license host&amp;gt;&amp;lt;/pre&amp;gt;&lt;br /&gt;
You can add multiple `ServerSearchList\Server&amp;lt;n&amp;gt;` sections, one for each license host you have, with the IP address of the license host. Once you update and save the configuration file, restart the CodeMeter service and your licenses from the network server should then be available locally.&lt;br /&gt;
&lt;br /&gt;
If you are setting up a license host, which you wish to access from another machine, you will need to install the CodeMeter Runtime on that machine as well and you need to ensure the firewall allows requests to the license host on port 22350.&lt;br /&gt;
&lt;br /&gt;
On Red Hat, you can achieve this with:&amp;lt;pre&amp;gt;sudo firewall-cmd --get-active-zones&lt;br /&gt;
sudo firewall-cmd --zone=public --add-port=22350/tcp --permanent&lt;br /&gt;
sudo firewall-cmd --reload&amp;lt;/pre&amp;gt;&lt;br /&gt;
This assumes you see the `public` zone after the first command.&lt;br /&gt;
&lt;br /&gt;
On Debian, you can run:&amp;lt;pre&amp;gt;sudo iptables -A INPUT -p tcp -m tcp --dport 22350 -j ACCEPT&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Similarly, if you want users to be able to access the web admin interface for code meter on the server, you would need to ensure the firewall allows request on port 22352 (for http) and/or 22353 (for https). However, access to the web admin interface from other machines is not required for obtaining a license and in typical configurations, you would be able to access the web admin interface on the host itself (localhost) without additional firewall rules.&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Installing_Wibu_CodeMeter_Windows&amp;diff=45392</id>
		<title>Installing Wibu CodeMeter Windows</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Installing_Wibu_CodeMeter_Windows&amp;diff=45392"/>
		<updated>2026-01-09T00:37:57Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;* Download the latest CodeMeter Runtime Kit for Windows installer from: &amp;lt;u&amp;gt;[https://www.wibu.com/support/user/downloads-user-software.html https://www.wibu.com/support/user/downloads-user-software.html]&amp;lt;/u&amp;gt;&lt;br /&gt;
[[File:Installing Wibu CodMeter_001.png]]&lt;br /&gt;
* Install the software&lt;br /&gt;
:* If you are using a local licence or have a network licence and are installing CodeMeter on a network client computer (i.e. a modelling computer, not the network host/server) please use the default install settings.   &lt;br /&gt;
:* If a computer is used as a network licence server, please select the &amp;quot;Network Server&amp;quot; option during the installation. Selecting this option will configure the appropriate TCP and UDP protocols in the Windows Firewall.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Installing WibuCodMeter_002.png]]&lt;br /&gt;
&lt;br /&gt;
* Silent Install: It is possible to do a silent install of the CodeMeter Runtime kit.  CodeMeter support staff have advised that this can be done with the following parameters:&amp;lt;br&amp;gt;&lt;br /&gt;
 &amp;lt;tt&amp;gt;CodeMeterRuntime.exe /ComponentArgs &amp;quot;*&amp;quot;:&amp;quot;/qn&amp;quot;&amp;lt;/tt&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=TUFLOW_Simulation_Speed&amp;diff=45228</id>
		<title>TUFLOW Simulation Speed</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=TUFLOW_Simulation_Speed&amp;diff=45228"/>
		<updated>2025-12-10T01:19:30Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Common Questions Answered (FAQ)=&lt;br /&gt;
==How can I speed up my TUFLOW model, make it more storage efficient and reduce RAM requirements?==&lt;br /&gt;
The following tips provide advice on how to make TUFLOW models initialise, run and write results faster. Most of the suggestions will also ensure the model output size is kept to minimum, minimising required disk space.&lt;br /&gt;
* Initialisation:&lt;br /&gt;
** Use XF files to speed up the model initialisation (the default).&lt;br /&gt;
** Use TIF or FLT grids for grid inputs instead of ASC as they are faster to read. FLT files are ESRI binary (float) version of the ASC files, their size is about 1/2 to 1/5 of an ASC file. To convert ASC to FLT, use -conv switch with our &amp;lt;u&amp;gt;[[ASC_to_ASC#Convert | ASC_to_ASC utility]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
* Writing check files:&lt;br /&gt;
** Writing check files to a local solid state drive usually take less time than to a network drive.&lt;br /&gt;
** Make sure there is enough free space as drives slow down when they are nearing to being full.&lt;br /&gt;
** Suppress unnecessary check files - some check files, such as zpt, uvpt and grd check file, can take a relatively long time to write. If some check files are not changing, they can just be written once and excluded for subsequent simulations with the below command. Any check file can be excluded, example of such command is &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Write Check Files EXCLUDE&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt; zpt uvpt grd&amp;lt;/tt&amp;gt;.&lt;br /&gt;
** Use output zones to write localised check files when specific areas of a model domain are of interest.&lt;br /&gt;
* Simulation:&lt;br /&gt;
** Use single precision version of TUFLOW if double precision is not required. More information on single and double versions &amp;lt;u&amp;gt;[[TUFLOW_General_Discussion#What_is_the_difference_between_single_and_double_precision_and_when_should_I_use_them.3F | here]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
** If using TUFLOW HPC, review the &amp;lt;u&amp;gt;[[HPC_Model_Review#dt_Map_Output | minimum dt map output]]&amp;lt;/u&amp;gt; to check for locations with low timestep and whether any improvements can be applied to speed up the simulation.&lt;br /&gt;
* Writing results:&lt;br /&gt;
** Writing results to a local solid state drive usually take less time than to a network drive. This also applies to running models on a cloud. From our testing, writing outputs on a local drive of the virtual machine is noticeably faster than using network storage.&lt;br /&gt;
** Make sure there is enough free space as drives slow down when they are nearing to being full.&lt;br /&gt;
** Use output zones to write localised results when specific areas of a model domain are of interest.&lt;br /&gt;
** Use TIF or FLT for grid results instead of ASC as they are more efficient in terms of write speed and file size.&lt;br /&gt;
** Specify XMDF for temporal output instead of DAT as they are more compressed and faster to write.&lt;br /&gt;
** Use appropriate &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Map Output Interval&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; for XMDF, e.g. around 100 output increments for the whole simulation unless an animation of high temporal resolution is to be created.&lt;br /&gt;
** Output only maximum TIF or FLT grids with &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;FLT Map Output Interval &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt;0&amp;lt;/tt&amp;gt; instead of every &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Map Output Interval&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;. Keep the temporal output only as XMDF.&lt;br /&gt;
** Specify only &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Map Output Data Types &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; that are needed.&lt;br /&gt;
** For further details, see &amp;lt;u&amp;gt;[https://www.youtube.com/watch?v=-CsKKjG7jpQ&amp;amp;ab_channel=TUFLOW Output Management Advice]&amp;lt;/u&amp;gt; webinar.&lt;br /&gt;
* Hardware:&lt;br /&gt;
** Consider using multiple resources:&lt;br /&gt;
*** TUFLOW HPC is parallelised and can run on multiple devices. By default, TUFLOW HPC running on GPU uses one GPU card, to increase the number see &amp;lt;u&amp;gt;[[HPC_Running_and_Converting_Models#Running_HPC_on_Multiple_GPU_Devices | Running HPC on multiple GPU devices]]&amp;lt;/u&amp;gt;. TUFLOW HPC running on CPU uses by default four CPU threads, to increase the number see &amp;lt;u&amp;gt;[[HPC_Running_and_Converting_Models#Running_HPC_on_Multiple_CPU_Threads | Running HPC on multiple CPU threads]]&amp;lt;/u&amp;gt;. Note that model initialisation, 1D calculations and writing results are being processed on the CPU side even if GPU resources are used for the 2D simulation and currently these processes only use one CPU thread.&lt;br /&gt;
*** TUFLOW Classic isn&#039;t parallelised and only uses a single CPU thread for every simulation. Model initialisation, 1D calculations and writing results are also limited to only one CPU thread.&lt;br /&gt;
** The better the hardware, the faster TUFLOW model would run. To see how different hardware compares to each other, see &amp;lt;u&amp;gt;[[Hardware_Benchmarking_-_Results#CPU_Results | Hardware Benchmarking Results]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
** For more information on hardware specification, see &amp;lt;u&amp;gt;[[Hardware_Selection_Advice | Hardware Selection Advice]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
Reducing RAM requirements: &lt;br /&gt;
* Model domain should be as tight to the model code (active areas) as possible - search the .tlf for &amp;quot;Isolating redundant perimeter sections&amp;quot;, this will tell you how much larger the domain is than it needs to be as a percentage.&lt;br /&gt;
* Using Quadtree may decrease RAM requirement as with Quadtree mesh only active code polygon is processed instead of the whole model domain rectangle used for HPC and Classic. Also, judicious refinement and using larger cells in non-focus areas will decrease the number of active cells and therefore the RAM requirement.&lt;br /&gt;
* The larger cell size, the less RAM is required. &amp;lt;u&amp;gt;[https://www.youtube.com/watch?v=1jWyIXHR_lM Cell size sensitivity testing]&amp;lt;/u&amp;gt; can be carried out to find out the largest cell size without compromising model accuracy.&lt;br /&gt;
* Using Sub Grid Sampling (SGS) increases the RAM requirement compared to a non SGS model with the same cell size. If SGS increases the RAM beyond what is desired, consider the following:&lt;br /&gt;
&amp;lt;ol&amp;gt; &lt;br /&gt;
* Increase your 2D cell size. Thanks to SGS the cell size can typically be increased whilst still achieving a good cell size convergence.&lt;br /&gt;
* Review your SGS Sample Frequency in the TLF. Typically, a value of 11 or less is all that is necessary to set the SGS parameterisation to a level that achieves excellent accuracy. If the SGS Sample Frequency is excessively large, test reducing the default value by using either the &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;SGS Sample Frequency&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;tt&amp;gt;or &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;SGS Sample Sample Target Distance &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt;commands.  &lt;br /&gt;
&amp;lt;/ol&amp;gt; &lt;br /&gt;
* Inputs might be clipped if their extent is much larger than the code, e.g. grids, material layers and so on.  For example if a 100GB DEM is being input to TUFLOW with the majority of the DEM being outside the TUFLOW model, TUFLOW allocates memory to read the entire DEM in for processing.  Memory for reading inputs is only used temporarily and is released after the processing of the input, e.g. the DEM.&lt;br /&gt;
* Large DEM and material grids can use up a lot of memory during model initialisation as the entire grid is read for processing. Re-tiling the grid into smaller sections will use up less memory as each smaller grid will be processed at the time avoiding high memory peaks.&lt;br /&gt;
* Inspecting .tlf file can help recognising which model features require the most RAM and more RAM efficient methods might be considered. For example, using gridded rainfall is more RAM efficient than using large number of rainfall polygons. Other features such as soil infiltration, hazard outputs and output zones all require additional memory.&lt;br /&gt;
* Grid (raster) outputs from TUFLOW (including DEM check files and Map Output Formats ASC, FLT, NC, TGO and WRR), require significant memory for storing interpolation factors.  An interpolation is required as these outputs are all north-south aligned, while TUFLOW models can include rotation, water level lines and varying cell sizes.  By default the grid output resolution is half the 2D cell size.  Increasing the output cell size with the .tcf command &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Grid Output Cell Size &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt; &amp;lt;grid_output_cell_size&amp;gt;&amp;lt;/tt&amp;gt; can reduce the amount of memory required for this.  Refer to the &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt; for more information on grid outputs.&lt;br /&gt;
* When using Quadtree the .qcf command &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Quadtree Mesh Processing Method &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt; Memory Efficient&amp;lt;/tt&amp;gt; can reduce the amount of memory, although the model initialisation might take longer.&lt;br /&gt;
&lt;br /&gt;
Other processes can slow TUFLOW simulations down if they are competing for resources. A few potential causes:&lt;br /&gt;
* Running another model at the same time (as the CPU RAM is shared between both simulations)&lt;br /&gt;
* Scheduled computer back ups&lt;br /&gt;
* Operating system updates&lt;br /&gt;
* Antivirus scans&lt;br /&gt;
* Others activities (e.g. copying large files, writing large files).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[ TUFLOW_Modelling_Guidance | Back to TUFLOW Modelling Guidance]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=TUFLOW_Simulation_Speed&amp;diff=45227</id>
		<title>TUFLOW Simulation Speed</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=TUFLOW_Simulation_Speed&amp;diff=45227"/>
		<updated>2025-12-10T01:18:21Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Common Questions Answered (FAQ) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Common Questions Answered (FAQ)=&lt;br /&gt;
==How can I speed up my TUFLOW model, make it more storage efficient and reduce RAM requirements?==&lt;br /&gt;
The following tips provide advice on how to make TUFLOW models initialise, run and write results faster. Most of the suggestions will also ensure the model output size is kept to minimum, minimising required disk space.&lt;br /&gt;
* Initialisation:&lt;br /&gt;
** Use XF files to speed up the model initialisation (the default).&lt;br /&gt;
** Use TIF or FLT grids for grid inputs instead of ASC as they are faster to read. FLT files are ESRI binary (float) version of the ASC files, their size is about 1/2 to 1/5 of an ASC file. To convert ASC to FLT, use -conv switch with our &amp;lt;u&amp;gt;[[ASC_to_ASC#Convert | ASC_to_ASC utility]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
* Writing check files:&lt;br /&gt;
** Writing check files to a local solid state drive usually take less time than to a network drive.&lt;br /&gt;
** Make sure there is enough free space as drives slow down when they are nearing to being full.&lt;br /&gt;
** Suppress unnecessary check files - some check files, such as zpt, uvpt and grd check file, can take a relatively long time to write. If some check files are not changing, they can just be written once and excluded for subsequent simulations with the below command. Any check file can be excluded, example of such command is &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Write Check Files EXCLUDE&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt; zpt uvpt grd&amp;lt;/tt&amp;gt;.&lt;br /&gt;
** Use output zones to write localised check files when specific areas of a model domain are of interest.&lt;br /&gt;
* Simulation:&lt;br /&gt;
** Use single precision version of TUFLOW if double precision is not required. More information on single and double versions &amp;lt;u&amp;gt;[[TUFLOW_General_Discussion#What_is_the_difference_between_single_and_double_precision_and_when_should_I_use_them.3F | here]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
** If using TUFLOW HPC, review the &amp;lt;u&amp;gt;[[HPC_Model_Review#dt_Map_Output | minimum dt map output]]&amp;lt;/u&amp;gt; to check for locations with low timestep and whether any improvements can be applied to speed up the simulation.&lt;br /&gt;
* Writing results:&lt;br /&gt;
** Writing results to a local solid state drive usually take less time than to a network drive. This also applies to running models on a cloud. From our testing, writing outputs on a local drive of the virtual machine is noticeably faster than using network storage.&lt;br /&gt;
** Make sure there is enough free space as drives slow down when they are nearing to being full.&lt;br /&gt;
** Use output zones to write localised results when specific areas of a model domain are of interest.&lt;br /&gt;
** Use TIF or FLT for grid results instead of ASC as they are more efficient in terms of write speed and file size.&lt;br /&gt;
** Specify XMDF for temporal output instead of DAT as they are more compressed and faster to write.&lt;br /&gt;
** Use appropriate &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Map Output Interval&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; for XMDF, e.g. around 100 output increments for the whole simulation unless an animation of high temporal resolution is to be created.&lt;br /&gt;
** Output only maximum TIF or FLT grids with &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;FLT Map Output Interval &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt;0&amp;lt;/tt&amp;gt; instead of every &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Map Output Interval&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;. Keep the temporal output only as XMDF.&lt;br /&gt;
** Specify only &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Map Output Data Types &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; that are needed.&lt;br /&gt;
** For further details, see &amp;lt;u&amp;gt;[https://www.youtube.com/watch?v=-CsKKjG7jpQ&amp;amp;ab_channel=TUFLOW Output Management Advice]&amp;lt;/u&amp;gt; webinar.&lt;br /&gt;
* Hardware:&lt;br /&gt;
** Consider using multiple resources:&lt;br /&gt;
*** TUFLOW HPC is parallelised and can run on multiple devices. By default, TUFLOW HPC running on GPU uses one GPU card, to increase the number see &amp;lt;u&amp;gt;[[HPC_Running_and_Converting_Models#Running_HPC_on_Multiple_GPU_Devices | Running HPC on multiple GPU devices]]&amp;lt;/u&amp;gt;. TUFLOW HPC running on CPU uses by default four CPU threads, to increase the number see &amp;lt;u&amp;gt;[[HPC_Running_and_Converting_Models#Running_HPC_on_Multiple_CPU_Threads | Running HPC on multiple CPU threads]]&amp;lt;/u&amp;gt;. Note that model initialisation, 1D calculations and writing results are being processed on the CPU side even if GPU resources are used for the 2D simulation and currently these processes only use one CPU thread.&lt;br /&gt;
*** TUFLOW Classic isn&#039;t parallelised and only uses a single CPU thread for every simulation. Model initialisation, 1D calculations and writing results are also limited to only one CPU thread.&lt;br /&gt;
** The better the hardware, the faster TUFLOW model would run. To see how different hardware compares to each other, see &amp;lt;u&amp;gt;[[Hardware_Benchmarking_-_Results#CPU_Results | Hardware Benchmarking Results]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
** For more information on hardware specification, see &amp;lt;u&amp;gt;[[Hardware_Selection_Advice | Hardware Selection Advice]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
Reducing RAM requirements: &lt;br /&gt;
* Model domain should be as tight to the model code (active areas) as possible - search the .tlf for &amp;quot;Isolating redundant perimeter sections&amp;quot;, this will tell you how much larger the domain is than it needs to be as a percentage.&lt;br /&gt;
* Using Quadtree may decrease RAM requirement as with Quadtree mesh only active code polygon is processed instead of the whole model domain rectangle used for HPC and Classic. Also, judicious refinement and using larger cells in non-focus areas will decrease the number of active cells and therefore the RAM requirement.&lt;br /&gt;
* The larger cell size, the less RAM is required. &amp;lt;u&amp;gt;[https://www.youtube.com/watch?v=1jWyIXHR_lM Cell size sensitivity testing]&amp;lt;/u&amp;gt; can be carried out to find out the largest cell size without compromising model accuracy.&lt;br /&gt;
* Using Sub Grid Sampling (SGS) increases the RAM requirement compared to a non SGS model with the same cell size. If SGS increases the RAM beyond what is desired, consider the following:&lt;br /&gt;
&amp;lt;ol&amp;gt; &lt;br /&gt;
* Increase your 2D cell size. Thanks to SGS the cell size can typically be increased whilst still achieving a good cell size convergence.&lt;br /&gt;
* Review your SGS Sample Frequency in the TLF. Typically, a value of 11 or less is all that is necessary to set the SGS parameterisation to a level that achieves excellent accuracy. If the SGS Sample Frequency is excessively large, test reducing the default value by using either the &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;SGS Sample Frequency &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt; or &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;SGS Sample Sample Target Distance &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt; commands.  &lt;br /&gt;
&amp;lt;/ol&amp;gt; &lt;br /&gt;
* Inputs might be clipped if their extent is much larger than the code, e.g. grids, material layers and so on.  For example if a 100GB DEM is being input to TUFLOW with the majority of the DEM being outside the TUFLOW model, TUFLOW allocates memory to read the entire DEM in for processing.  Memory for reading inputs is only used temporarily and is released after the processing of the input, e.g. the DEM.&lt;br /&gt;
* Large DEM and material grids can use up a lot of memory during model initialisation as the entire grid is read for processing. Re-tiling the grid into smaller sections will use up less memory as each smaller grid will be processed at the time avoiding high memory peaks.&lt;br /&gt;
* Inspecting .tlf file can help recognising which model features require the most RAM and more RAM efficient methods might be considered. For example, using gridded rainfall is more RAM efficient than using large number of rainfall polygons. Other features such as soil infiltration, hazard outputs and output zones all require additional memory.&lt;br /&gt;
* Grid (raster) outputs from TUFLOW (including DEM check files and Map Output Formats ASC, FLT, NC, TGO and WRR), require significant memory for storing interpolation factors.  An interpolation is required as these outputs are all north-south aligned, while TUFLOW models can include rotation, water level lines and varying cell sizes.  By default the grid output resolution is half the 2D cell size.  Increasing the output cell size with the .tcf command &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Grid Output Cell Size &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt; &amp;lt;grid_output_cell_size&amp;gt;&amp;lt;/tt&amp;gt; can reduce the amount of memory required for this.  Refer to the &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt; for more information on grid outputs.&lt;br /&gt;
* When using Quadtree the .qcf command &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Quadtree Mesh Processing Method &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;tt&amp;gt; Memory Efficient&amp;lt;/tt&amp;gt; can reduce the amount of memory, although the model initialisation might take longer.&lt;br /&gt;
&lt;br /&gt;
Other processes can slow TUFLOW simulations down if they are competing for resources. A few potential causes:&lt;br /&gt;
* Running another model at the same time (as the CPU RAM is shared between both simulations)&lt;br /&gt;
* Scheduled computer back ups&lt;br /&gt;
* Operating system updates&lt;br /&gt;
* Antivirus scans&lt;br /&gt;
* Others activities (e.g. copying large files, writing large files).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[ TUFLOW_Modelling_Guidance | Back to TUFLOW Modelling Guidance]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_Introduction&amp;diff=45219</id>
		<title>TUFLOW SWMM Tutorial Introduction</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_Introduction&amp;diff=45219"/>
		<updated>2025-11-25T01:56:33Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* TUFLOW SWMM Documentation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;On request from USA XPSWMM users, TUFLOW linkage with 1D EPA Storm Water Management Model (SWMM) has been added as a supported feature in TUFLOW 2023-03-AD release or newer. EPA SWMM is used for simulating urban watershed hydrologic and 1D hydraulic behavior. Initially developed in the early 1970&#039;s by the USA Environmental Protection Agency (EPA), the software has since undergone numerous updates and enhancements to become one of the most used 1D stormwater runoff and water quality analysis tools in North America. The primary uses of EPA SWMM include designing and evaluating stormwater systems and also planning and assessment of low-impact developments (also known as Water Sensitive Urban Design). For more details about EPA SWMM, please visit: &amp;lt;u&amp;gt;[https://www.epa.gov/water-research/storm-water-management-model-swmm  https://www.epa.gov/water-research/storm-water-management-model-swmm]&amp;lt;/u&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
This EPA SWMM series of tutorials has been written in USA English for the predominantly USA SWMM user base.&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
The following tutorial models are aimed at new and experienced users, stepping through the process of building and running TUFLOW SWMM together. The main objective aims to demonstrate the ability for TUFLOW to link to 1D EPA SWMM in a variety of different common use case scenarios. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note, if you are not already familiar with TUFLOW, we recommend first completing Module 1 and 2 of the &amp;lt;u&amp;gt;[[Tutorial_Introduction | &amp;quot;TUFLOW Only&amp;quot; Tutorials]]&amp;lt;/u&amp;gt; to establish an understanding of 2D modeling, before progressing to learning how to link 1D EPA SWMM to 2D TUFLOW.&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;TUFLOW has supported 1D/2D dynamic coupling since its initial 2D solver development in 1989. Traditionally, 1D (1 Dimensional) linking and associated modeling has been applied using TUFLOW&#039;s 1D solver, ESTRY. As demonstrated in:&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[Tutorial_M03 | Module 3 - 1D Culverts]]&amp;lt;/u&amp;gt; &lt;br /&gt;
:*&amp;lt;u&amp;gt;[[Tutorial_M05 | Module 5 - Integrated Urban Pipe Network Drainage]]&amp;lt;/u&amp;gt; &lt;br /&gt;
:*&amp;lt;u&amp;gt;[[Tutorial_M11 | Module 11 - 1D Open Channel]]&amp;lt;/u&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
EPA SWMM&#039;s inclusion in TUFLOW does not replace ESTRY, rather both 1D solvers complement each other. Links to the TUFLOW SWMM tutorials are included in the section below.&lt;br /&gt;
&lt;br /&gt;
=Software Requirements=&lt;br /&gt;
TUFLOW uses QGIS as its Graphical User Interface (GUI), in combination with text editor and spreadsheet software, for its model creation and result viewing. The group of software creates an extremely workflow efficient and flexible modeling environment. Notably, QGIS does not experience the data load/visualization lag and display issues some other hydraulic modeling software GUI&#039;s are limited by when working with larger datasets.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; width=&amp;quot;75%&amp;quot;&lt;br /&gt;
&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Requirement&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; | Brief Description&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; | Download&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;TUFLOW&#039;&#039;&#039; || TUFLOW is a computer program for simulating depth-averaged, one and two-dimensional free-surface flows such as occurs from floods and tides, with the 2D solution occurring over a regular grid or quadtree mesh of square elements.&amp;lt;br&amp;gt;&lt;br /&gt;
It is recommended to always use the latest release version of TUFLOW.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This tutorial model does not require a TUFLOW license.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This tutorial is configured to use a NVIDIA GPU card. If this is not available, your CPU can be used via the Hardware command. &amp;lt;br&amp;gt;&lt;br /&gt;
||The TUFLOW executable is provided within the &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_Introduction#Tutorial_Data | Tutorial Download Dataset]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;QGIS&#039;&#039;&#039; &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;QGIS TUFLOW plugin || QGIS is the Geographic Information System (GIS) Graphical User Interface (GUI) used to build models and view results. The QGIS TUFLOW plugin includes numerous tools to increase workflow efficiency. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This tutorial was developed using QGIS 3.34 and QGIS TUFLOW Plugin 3.11. Please use these or newer versions of QGIS and the plugin. Earlier releases will not include the TUFLOW SWMM automation tools demonstrated in the Tutorials. &lt;br /&gt;
&lt;br /&gt;
||&amp;lt;u&amp;gt;[https://qgis.org/download/ Latest 64-bit version of QGIS]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;u&amp;gt;[[TUFLOW_QGIS_Plugin| QGIS TUFLOW Plugin Installation]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;NotePad++&#039;&#039;&#039; &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Syntax Highlighting || A text editor is required for creation of the TUFLOW control (script) files. This tutorial was developed with NotePad++. Ideally a text editor should be able to:&amp;lt;br&amp;gt;&lt;br /&gt;
*Color code the TUFLOW control files;&lt;br /&gt;
*Open other files from the active control file; and&lt;br /&gt;
*Launch a TUFLOW simulation. &amp;lt;br&amp;gt;&lt;br /&gt;
TUFLOW color coding can be enabled using syntax highlighting. &lt;br /&gt;
|| &amp;lt;u&amp;gt;[https://notepad-plus-plus.org/downloads/ Latest 64-bit version of Notepad++]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;u&amp;gt;[https://downloads.tuflow.com/_archive/Miscellaneous/NPP_TUFLOW_Syntax_Highlighting.zip TUFLOW syntax highlighting for Notepad++]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For instructions on configuring Notepad++ for TUFLOW modeling, see &amp;lt;u&amp;gt;[[NotepadPlusPlus_Tips |Notepad++ tips]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Microsoft Excel&#039;&#039;&#039; || A spreadsheet software is required for working with tabular data and .csv files. This tutorial has been created using Excel. || &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Tutorial Data=&lt;br /&gt;
To build the tutorial model, download the dataset below. This includes a digital elevation model (DEM), aerial photography, background model data for the tutorial model and a working version of the model. GeoPackage database has been used as the GIS format for the model build tasks. For tips on using GeoPackage databases see &amp;lt;u&amp;gt;[https://wiki.tuflow.com/GeoPackage_Tips GeoPackage Tips]&amp;lt;/u&amp;gt;. &lt;br /&gt;
:*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/TUFLOW/Wiki_Tute_Models/TUFLOW_SWMM_Tutorial_Models_QGIS_GPKG.zip  TUFLOW SWMM Tutorial Dataset - QGIS - GPKG]&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Tutorial Modules=&lt;br /&gt;
The download dataset contains the input files and working version of the tutorial model for reference. Results and check files are not included to keep the size of the download file manageable; they will be created when running the model simulations. The folder should be placed in a location with write permissions.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The tutorial model is presented in several modules. All modules can be completed independently, however new users are encouraged to undertake the modules in sequence:&lt;br /&gt;
&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01 | TUFLOW SWMM Module 1]]&amp;lt;/u&amp;gt;  - 1D SWMM Culverts&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02 | TUFLOW SWMM Module 2]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 2D TUFLOW Direct Rainfall Hydrology&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M03 | TUFLOW SWMM Module 3]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M04 | TUFLOW SWMM Module 4]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology: Executing multiple different event simulations from a single model control file.&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM | XPSWMM to TUFLOW SWMM: Automated (Recommended) Approach]]&amp;lt;/u&amp;gt;  - How to convert an XPSWMM model to TUFLOW SWMM: Automated XPX Conversion Tool Approach.&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM_Archive | XPSWMM to TUFLOW SWMM: Manual Approach]]&amp;lt;/u&amp;gt;  - How to convert an XPSWMM model to TUFLOW SWMM: Manual Approach.&lt;br /&gt;
&lt;br /&gt;
== TUFLOW SWMM Documentation ==&lt;br /&gt;
TUFLOW SWMM documentation can be found in the TUFLOW Manual and in the TUFLOW plugin documentation for the related QGIS tools.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt;&lt;br /&gt;
* &amp;lt;u&amp;gt;[[TUFLOW QGIS Plugin#Processing_Toolbox|TUFLOW QGIS Plugin Documentation including SWMM tools]]&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Recommended Further Reading=&lt;br /&gt;
For users who wish to get a better understanding of either 1D EPA SWMM or 2D TUFLOW, the following resources may be of use:&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;EPA SWMM&#039;&#039;&#039;: &amp;lt;u&amp;gt;[https://www.epa.gov/water-research/storm-water-management-model-swmm www.epa.gov]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume1_Hydrology_P100NYRA.pdf SWMM5 Reference Manual - Volume 1 (Hydrology)]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydaulics_P100S9AS.pdf SWMM5 Reference Manual - Volume 2 (Hydraulics) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydraulics_Addendum-20220210mas2wr.pdf  SWMM5 Reference Manual - Volume 2 (Hydraulics Addendum) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume3_Water_Quality_P100P2NY.pdf  SWMM5 Reference Manual - Volume 3 (Water Quality) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/swmm-users-manual-version-5.2.pdf EPA SWMM5 User&#039;s Manual]&amp;lt;/u&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;TUFLOW&#039;&#039;&#039;: &amp;lt;u&amp;gt;[https://www.tuflow.com www.tuflow.com]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[[Tutorial_Introduction#Tutorial_Modules | TUFLOW Tutorial Models]]&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Contact=&lt;br /&gt;
For comments, requests and feedback contact &amp;lt;u&amp;gt;[mailto:support@tuflow.com support@tuflow.com]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
For further training opportunities see &amp;lt;u&amp;gt;[https://tuflow.com/training/training-course-catalogue/ TUFLOW Training Catalogue]&amp;lt;/u&amp;gt; and/or contact &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[Main_Page| Back to Wiki Main Page]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_Introduction&amp;diff=45218</id>
		<title>TUFLOW SWMM Tutorial Introduction</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_Introduction&amp;diff=45218"/>
		<updated>2025-11-25T01:56:03Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Recommended Further Reading */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;On request from USA XPSWMM users, TUFLOW linkage with 1D EPA Storm Water Management Model (SWMM) has been added as a supported feature in TUFLOW 2023-03-AD release or newer. EPA SWMM is used for simulating urban watershed hydrologic and 1D hydraulic behavior. Initially developed in the early 1970&#039;s by the USA Environmental Protection Agency (EPA), the software has since undergone numerous updates and enhancements to become one of the most used 1D stormwater runoff and water quality analysis tools in North America. The primary uses of EPA SWMM include designing and evaluating stormwater systems and also planning and assessment of low-impact developments (also known as Water Sensitive Urban Design). For more details about EPA SWMM, please visit: &amp;lt;u&amp;gt;[https://www.epa.gov/water-research/storm-water-management-model-swmm  https://www.epa.gov/water-research/storm-water-management-model-swmm]&amp;lt;/u&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
This EPA SWMM series of tutorials has been written in USA English for the predominantly USA SWMM user base.&lt;br /&gt;
&lt;br /&gt;
= Introduction =&lt;br /&gt;
The following tutorial models are aimed at new and experienced users, stepping through the process of building and running TUFLOW SWMM together. The main objective aims to demonstrate the ability for TUFLOW to link to 1D EPA SWMM in a variety of different common use case scenarios. &lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Note, if you are not already familiar with TUFLOW, we recommend first completing Module 1 and 2 of the &amp;lt;u&amp;gt;[[Tutorial_Introduction | &amp;quot;TUFLOW Only&amp;quot; Tutorials]]&amp;lt;/u&amp;gt; to establish an understanding of 2D modeling, before progressing to learning how to link 1D EPA SWMM to 2D TUFLOW.&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;TUFLOW has supported 1D/2D dynamic coupling since its initial 2D solver development in 1989. Traditionally, 1D (1 Dimensional) linking and associated modeling has been applied using TUFLOW&#039;s 1D solver, ESTRY. As demonstrated in:&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[Tutorial_M03 | Module 3 - 1D Culverts]]&amp;lt;/u&amp;gt; &lt;br /&gt;
:*&amp;lt;u&amp;gt;[[Tutorial_M05 | Module 5 - Integrated Urban Pipe Network Drainage]]&amp;lt;/u&amp;gt; &lt;br /&gt;
:*&amp;lt;u&amp;gt;[[Tutorial_M11 | Module 11 - 1D Open Channel]]&amp;lt;/u&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
EPA SWMM&#039;s inclusion in TUFLOW does not replace ESTRY, rather both 1D solvers complement each other. Links to the TUFLOW SWMM tutorials are included in the section below.&lt;br /&gt;
&lt;br /&gt;
=Software Requirements=&lt;br /&gt;
TUFLOW uses QGIS as its Graphical User Interface (GUI), in combination with text editor and spreadsheet software, for its model creation and result viewing. The group of software creates an extremely workflow efficient and flexible modeling environment. Notably, QGIS does not experience the data load/visualization lag and display issues some other hydraulic modeling software GUI&#039;s are limited by when working with larger datasets.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; width=&amp;quot;75%&amp;quot;&lt;br /&gt;
&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Requirement&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; | Brief Description&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; | Download&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;TUFLOW&#039;&#039;&#039; || TUFLOW is a computer program for simulating depth-averaged, one and two-dimensional free-surface flows such as occurs from floods and tides, with the 2D solution occurring over a regular grid or quadtree mesh of square elements.&amp;lt;br&amp;gt;&lt;br /&gt;
It is recommended to always use the latest release version of TUFLOW.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This tutorial model does not require a TUFLOW license.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This tutorial is configured to use a NVIDIA GPU card. If this is not available, your CPU can be used via the Hardware command. &amp;lt;br&amp;gt;&lt;br /&gt;
||The TUFLOW executable is provided within the &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_Introduction#Tutorial_Data | Tutorial Download Dataset]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;QGIS&#039;&#039;&#039; &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;QGIS TUFLOW plugin || QGIS is the Geographic Information System (GIS) Graphical User Interface (GUI) used to build models and view results. The QGIS TUFLOW plugin includes numerous tools to increase workflow efficiency. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
This tutorial was developed using QGIS 3.34 and QGIS TUFLOW Plugin 3.11. Please use these or newer versions of QGIS and the plugin. Earlier releases will not include the TUFLOW SWMM automation tools demonstrated in the Tutorials. &lt;br /&gt;
&lt;br /&gt;
||&amp;lt;u&amp;gt;[https://qgis.org/download/ Latest 64-bit version of QGIS]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;u&amp;gt;[[TUFLOW_QGIS_Plugin| QGIS TUFLOW Plugin Installation]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;NotePad++&#039;&#039;&#039; &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Syntax Highlighting || A text editor is required for creation of the TUFLOW control (script) files. This tutorial was developed with NotePad++. Ideally a text editor should be able to:&amp;lt;br&amp;gt;&lt;br /&gt;
*Color code the TUFLOW control files;&lt;br /&gt;
*Open other files from the active control file; and&lt;br /&gt;
*Launch a TUFLOW simulation. &amp;lt;br&amp;gt;&lt;br /&gt;
TUFLOW color coding can be enabled using syntax highlighting. &lt;br /&gt;
|| &amp;lt;u&amp;gt;[https://notepad-plus-plus.org/downloads/ Latest 64-bit version of Notepad++]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;u&amp;gt;[https://downloads.tuflow.com/_archive/Miscellaneous/NPP_TUFLOW_Syntax_Highlighting.zip TUFLOW syntax highlighting for Notepad++]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For instructions on configuring Notepad++ for TUFLOW modeling, see &amp;lt;u&amp;gt;[[NotepadPlusPlus_Tips |Notepad++ tips]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
|-&lt;br /&gt;
| &#039;&#039;&#039;Microsoft Excel&#039;&#039;&#039; || A spreadsheet software is required for working with tabular data and .csv files. This tutorial has been created using Excel. || &lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Tutorial Data=&lt;br /&gt;
To build the tutorial model, download the dataset below. This includes a digital elevation model (DEM), aerial photography, background model data for the tutorial model and a working version of the model. GeoPackage database has been used as the GIS format for the model build tasks. For tips on using GeoPackage databases see &amp;lt;u&amp;gt;[https://wiki.tuflow.com/GeoPackage_Tips GeoPackage Tips]&amp;lt;/u&amp;gt;. &lt;br /&gt;
:*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/TUFLOW/Wiki_Tute_Models/TUFLOW_SWMM_Tutorial_Models_QGIS_GPKG.zip  TUFLOW SWMM Tutorial Dataset - QGIS - GPKG]&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Tutorial Modules=&lt;br /&gt;
The download dataset contains the input files and working version of the tutorial model for reference. Results and check files are not included to keep the size of the download file manageable; they will be created when running the model simulations. The folder should be placed in a location with write permissions.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The tutorial model is presented in several modules. All modules can be completed independently, however new users are encouraged to undertake the modules in sequence:&lt;br /&gt;
&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01 | TUFLOW SWMM Module 1]]&amp;lt;/u&amp;gt;  - 1D SWMM Culverts&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02 | TUFLOW SWMM Module 2]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 2D TUFLOW Direct Rainfall Hydrology&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M03 | TUFLOW SWMM Module 3]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M04 | TUFLOW SWMM Module 4]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology: Executing multiple different event simulations from a single model control file.&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM | XPSWMM to TUFLOW SWMM: Automated (Recommended) Approach]]&amp;lt;/u&amp;gt;  - How to convert an XPSWMM model to TUFLOW SWMM: Automated XPX Conversion Tool Approach.&lt;br /&gt;
:*&amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM_Archive | XPSWMM to TUFLOW SWMM: Manual Approach]]&amp;lt;/u&amp;gt;  - How to convert an XPSWMM model to TUFLOW SWMM: Manual Approach.&lt;br /&gt;
&lt;br /&gt;
== TUFLOW SWMM Documentation ==&lt;br /&gt;
TUFLOW SWMM documentation can be found in the TUFLOW Manual, the 2023-03-AD release notes for TUFLOW-SWMM and in the TUFLOW plugin documentation for the related QGIS tools.&lt;br /&gt;
&lt;br /&gt;
* &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt;&lt;br /&gt;
* &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/ TUFLOW 2023-03-AD Release notes - SWMM Section]&amp;lt;/u&amp;gt;&lt;br /&gt;
* &amp;lt;u&amp;gt;[[TUFLOW QGIS Plugin#Processing_Toolbox|TUFLOW QGIS Plugin Documentation including SWMM tools]]&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Recommended Further Reading=&lt;br /&gt;
For users who wish to get a better understanding of either 1D EPA SWMM or 2D TUFLOW, the following resources may be of use:&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;EPA SWMM&#039;&#039;&#039;: &amp;lt;u&amp;gt;[https://www.epa.gov/water-research/storm-water-management-model-swmm www.epa.gov]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume1_Hydrology_P100NYRA.pdf SWMM5 Reference Manual - Volume 1 (Hydrology)]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydaulics_P100S9AS.pdf SWMM5 Reference Manual - Volume 2 (Hydraulics) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydraulics_Addendum-20220210mas2wr.pdf  SWMM5 Reference Manual - Volume 2 (Hydraulics Addendum) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume3_Water_Quality_P100P2NY.pdf  SWMM5 Reference Manual - Volume 3 (Water Quality) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/swmm-users-manual-version-5.2.pdf EPA SWMM5 User&#039;s Manual]&amp;lt;/u&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;TUFLOW&#039;&#039;&#039;: &amp;lt;u&amp;gt;[https://www.tuflow.com www.tuflow.com]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[[Tutorial_Introduction#Tutorial_Modules | TUFLOW Tutorial Models]]&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Contact=&lt;br /&gt;
For comments, requests and feedback contact &amp;lt;u&amp;gt;[mailto:support@tuflow.com support@tuflow.com]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
For further training opportunities see &amp;lt;u&amp;gt;[https://tuflow.com/training/training-course-catalogue/ TUFLOW Training Catalogue]&amp;lt;/u&amp;gt; and/or contact &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[Main_Page| Back to Wiki Main Page]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=XPSWMM_to_TUFLOW-SWMM&amp;diff=45217</id>
		<title>XPSWMM to TUFLOW-SWMM</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=XPSWMM_to_TUFLOW-SWMM&amp;diff=45217"/>
		<updated>2025-11-25T01:27:33Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* TUFLOW Simulation Execution */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Introduction =&lt;br /&gt;
This Wiki page outlines recommended steps for the conversion of an XPSWMM model to TUFLOW. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
XPSWMM is a flood and urban stormwater drainage modeling software developed by Autodesk (previously Innovyze and XP Solutions). The XPSWMM solution uses EPA SWMM for its 1D calculations, dynamically linked to TUFLOW for its 2D calculations. The software functions within a custom build Graphical User Interface (GUI). Unknown to many XPSWMM modelers, during simulation, XPSWMM processes its inputs into TUFLOW files and also calls TUFLOW for the 2D calculations. As XPSWMM uses TUFLOW for its 2D engine, like-for-like results can be achieved using this software. The modeling workflow in TUFLOW differs from XPSWMM, as TUFLOW modeling is integrated with QGIS (Geographical Information System) GIS software instead of embedded within a software specific Graphical User Interface.&lt;br /&gt;
&lt;br /&gt;
If you are building a TUFLOW SWMM model from scratch, not from XPSWMM, please refer to the &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_Introduction | TUFLOW SWMM Tutorials]]&amp;lt;/u&amp;gt;. Tutorials are provided for the following topics:&lt;br /&gt;
* &amp;lt;u&amp;gt;[[TUFLOW SWMM Tutorial M01 | TUFLOW SWMM Module 1]]&amp;lt;/u&amp;gt; - 1D SWMM Culverts&lt;br /&gt;
* &amp;lt;u&amp;gt;[[TUFLOW SWMM Tutorial M02 | TUFLOW SWMM Module 2]]&amp;lt;/u&amp;gt; - 1D SWMM Pipe Network / 2D TUFLOW Direct Rainfall Hydrology&lt;br /&gt;
* &amp;lt;u&amp;gt;[[TUFLOW SWMM Tutorial M03 | TUFLOW SWMM Module 3]]&amp;lt;/u&amp;gt; - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology&lt;br /&gt;
* &amp;lt;u&amp;gt;[[TUFLOW SWMM Tutorial M04 | TUFLOW SWMM Module 4]]&amp;lt;/u&amp;gt; - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology: Executing multiple different event simulations from a single model control file.&lt;br /&gt;
&lt;br /&gt;
== Dataset Download ==&lt;br /&gt;
The dataset used for this model conversion demonstration is available for download here: &amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/XPSWMM_XPX_to_TUFLOW_Conversion.zip XPSWMM XPX to TUFLOW Conversion Dataset]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&lt;br /&gt;
This dataset contains the XPSWMM model and the resulting TUFLOW model that is created. These can be found in the &#039;&#039;&#039;XPSWMM&#039;&#039;&#039; and &#039;&#039;&#039;Complete_Conversion&#039;&#039;&#039; folders respectively. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;If you are using this example conversion dataset, please rerun the XPSWMM model in the location where you save the dataset before beginning your own TUFLOW model conversion.&#039;&#039;&#039; Rerunning the model is necessary because XPSWMM will write TUFLOW files during its preprocessing, subsequently defining the correct file path information (for the location where you saved your files) in the newly written TUFLOW files. We also recommend creating your own TUFLOW model in a different folder from the provided TUFLOW dataset so you can easily compare your model against it.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If you do not have access to a XPSWMM license and the XPSWMM Application, please refer to the &amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM_Troubleshooting#Model_Conversion_Without_a_XPSWMM_License |XPSWMM to TUFLOW SWMM Troubleshooting]]&amp;lt;/u&amp;gt; page. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= XPSWMM to TUFLOW Model Conversion =&lt;br /&gt;
== Export Data From XPSWMM Model == &lt;br /&gt;
&#039;&#039;&#039;Digital Terrain Model (DTM) Data&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
XPSWMM reads its 2D DTM data in one of two ways:&lt;br /&gt;
* The DTM data can be directly specified in the &#039;2D Model Settings&#039;, or &lt;br /&gt;
* The DTM data can be internally processed by XPSWMM using its terrain tools and DTM builder. &lt;br /&gt;
Depending on which method is applied to your XPSWMM model, the steps required to will vary. Review which method is used:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open your existing model in XPSWMM.&lt;br /&gt;
&amp;lt;li&amp;gt; In the top dropdown menu options, go to Configuration &amp;gt; Job Control &amp;gt; 2D Model Settings. This will open a dialog. &lt;br /&gt;
&amp;lt;li&amp;gt; Under &#039;2D Hydraulics Job Control&#039;, select &#039;Surface &amp;amp; Sampling&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt; Review the options in the &#039;Surface&#039; section:&lt;br /&gt;
:* If &#039;Use DTM&#039; is selected: Continue to the section below (&amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM#Export_DTM_Data_from_XPSWMM |Export DTM Data from XPSWMM]]&amp;lt;/u&amp;gt;) and complete the steps.&lt;br /&gt;
:* If &#039;Use Grid File for Topography&#039; is selected and a &#039;Grid file&#039; is specified, the steps outlined in the &#039;Export DTM Data From XPSWMM&#039; section can be skipped. Go to the &amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM#Export_XPX_Data_From_XPSWMM|Export XPX Data From XPSWMM]]&amp;lt;/u&amp;gt; section.&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If you have a .tif elevation file, you can continue to the &amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM#Export_XPX_Data_From_XPSWMM|Export XPX Data From XPSWMM]]&amp;lt;/u&amp;gt; section. The conversion process will be identical however, once converted, you will have to create the &#039;&#039;&#039;TUFLOW\model\grid&#039;&#039;&#039; folder manually and copy the .tif file into it. &lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_XPtoTUFLOW_Export_Data_01b.mp4|width=1350}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Export DTM Data From XPSWMM ===&lt;br /&gt;
If &#039;Use DTM&#039; was selected, XPSWMM preprocesses its Digital Terrain Model (DTM) into a binary XPTIN elevation dataset for inclusion in the TUFLOW model. XPTIN is a binary format that can&#039;t readily be used in GIS software. For this reason, the following steps outline how to obtain a DTM dataset in a GIS friendly form.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In the XPSWMM Layers panel, under &#039;Topography&#039;, right click on &#039;&#039;&#039;DTM&#039;&#039;&#039; and select &#039;Export DTM Data&#039;. &lt;br /&gt;
:* Input TIN File: Select the relevant XPSWMM Input TIN file. &lt;br /&gt;
:* Output File Format: &#039;ASCII Grid File Format&#039;.&lt;br /&gt;
:* Cell Size Value: Choose a suitable DTM resolution. This resolution should be finer than the hydraulic model resolution. Typically, a DTM resolution is 1/5th to 1/10th of the hydraulic model 2D cell size is common (1 in the example dataset).&lt;br /&gt;
&#039;&#039;Note: XPSWMM requires an integer cell size value for this export step. For example, Cell Size Values of 1, 2, 3, 4, 5 ... are suitable. The XPSWMM export will not function if you specify a decimal cell size value (eg. 0.5, 2.5, etc.).&#039;&#039;  &lt;br /&gt;
&amp;lt;li&amp;gt; Click &#039;Export&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; Save the file under an appropriate name (e.g. &#039;&#039;&#039;1D2D_Urban_Grid.asc&#039;&#039;&#039;) to the folder where XPSWMM writes the .tcf during its simulation preprocessing. By default, this is the &#039;&#039;&#039;2D\Data&#039;&#039;&#039; folder. &amp;lt;br&amp;gt;&lt;br /&gt;
If this folder does not exist, either:&lt;br /&gt;
:* The XPSWMM model has not run, so the TUFLOW control files have not been created by XPSWMM. Run the XPSWMM model (go to Analyze &amp;gt; Solve... in top dropdown menu options).&lt;br /&gt;
:* Non-default output settings have been specified in XPSWMM. To determine the output location, in the top dropdown menu options, go to Configuration &amp;gt; Job Control &amp;gt; 2D Model Settings &amp;gt; Folder Options. Ensure the following &#039;Folder Locations&#039; are selected.&lt;br /&gt;
::[[File: XPSWMM_to_TUFLOW_2DJobControl_FolderOptions_Dialog_01e.png]]&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt; In the top dropdown menu options, navigate to  Configuration &amp;gt; Job Control &amp;gt; 2D Model Settings. This will open a dialog, under &#039;2D Hydraulics Job Control&#039;, select &#039;Surface &amp;amp; Sampling&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; Tick on &#039;Use grid file for topography&#039; and select &#039;...&#039; to navigate to the Grid file saved in the &#039;&#039;&#039;2D\Data&#039;&#039;&#039; folder. This file will be read directly into TUFLOW. &lt;br /&gt;
&amp;lt;li&amp;gt; Click &#039;OK&#039; to save the settings. &lt;br /&gt;
&amp;lt;li&amp;gt; Run the XPSWMM model to rewrite the TUFLOW files (including the new linkage to the DTM dataset) to the Data folder (go to Analyze &amp;gt; Solve... in top dropdown menu options).&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_XPtoTUFLOW_Export_Data_02b.mp4|width=1350}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Export XPX Data From XPSWMM ===&lt;br /&gt;
A XPX file is a simple command line file that contains the information needed to create link and node objects. To export this data from the XPSWMM model:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In XPSWMM, in the top dropdown menu options, navigate to File &amp;gt; Import/Export Data &amp;gt; Export XPX Data. This will open a dialog. Leave all options as default and click &#039;Export&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; When prompted, save the file under an appropriate name (eg &#039;&#039;&#039;1D2D_Urban_001.xpx&#039;&#039;&#039;) to the folder where the XPSWMM model is located.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_XPtoTUFLOW_Export_Data_03b.mp4|width=1350}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Convert XPSWMM Model to TUFLOW SWMM ==&lt;br /&gt;
Ensure you have QGIS and have the QGIS TUFLOW Plugin installed:&lt;br /&gt;
*Install QGIS 3.34 or later: &amp;lt;u&amp;gt;[https://www.qgis.org/download/ Latest 64-bit version of QGIS]&amp;lt;/u&amp;gt;. &lt;br /&gt;
*Install the QGIS TUFLOW Plugin by following the instructions, &amp;lt;u&amp;gt;[[TUFLOW_QGIS_Plugin | QGIS TUFLOW Plugin Installation]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The following steps outline the process of converting a XPSWMM model to TUFLOW SWMM using the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Convert_XPSWMM_Model_From_XPX|Convert - XPSWMM model from XPX]]&amp;lt;/u&amp;gt;&#039; processing tool.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open QGIS and go to Processing &amp;gt; Toolbox from the top dropdown menu options to open the Processing Toolbox.&lt;br /&gt;
&amp;lt;li&amp;gt; Go to TUFLOW &amp;gt;&amp;gt; SWMM in the processing tool list and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Convert_XPSWMM_Model_From_XPX|Convert - XPSWMM model from XPX]]&amp;lt;/u&amp;gt;&#039;. This opens the dialog shown below.&lt;br /&gt;
:* XPSWMM Exported XPX File: Click &#039;...&#039; and navigate to the exported XPX data (e.g. &#039;&#039;&#039;1D2D_Urban_001.xpx&#039;&#039;&#039;). This should be located in the same folder as the XPSWMM model. &lt;br /&gt;
:* TUFLOW TCF Filename: Click &#039;...&#039; and navigate to the XPSWMM .tcf. This should be located in the &#039;&#039;&#039;2D\Data&#039;&#039;&#039; folder (e.g. &#039;&#039;&#039;2D\Data &amp;gt;&amp;gt; 1D2D_Urban_001.tcf&#039;&#039;&#039;). &lt;br /&gt;
:* SWMM File Prefix: Choose an appropriate prefix for the SWMM files (e.g. &#039;&#039;&#039;1D2D_Urban_swmm&#039;&#039;&#039;).&lt;br /&gt;
:* Output Solution Scheme: &#039;HPC&#039;&lt;br /&gt;
:* Output Hardware Specification: &#039;GPU&#039; (if GPU is not available, select &#039;CPU&#039;)&lt;br /&gt;
:* Output Vector Format: &#039;GPKG&#039;&lt;br /&gt;
:* Output Raster Format: &#039;GTIFF&#039;&lt;br /&gt;
:* Output Profile: Any option can be used. &#039;ALL IN ONE&#039; is used in this example for model design consistency with the &amp;lt;u&amp;gt;[[Tutorial_Introduction | TUFLOW SWMM Tutorials]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
:* Event name if no global storms: Choose an appropriate event name if applicable (100yr in the example dataset). &lt;br /&gt;
:* BC width for created 1D/2D connections (HX/SX): This value should be approximately 2 times the width of the hydraulic model 2D cell size (10 in the example dataset).&lt;br /&gt;
:* BC offset distance for created 1D/2D connections (HX/SX): Distance from the channel endpoint to the midpoint of the BC line (2 in the example dataset).&lt;br /&gt;
:* Output Folder: Click &#039;...&#039; and navigate to an appropriate location to save your TUFLOW model. In this location, create a new folder called &#039;&#039;&#039;TUFLOW&#039;&#039;&#039; and select it.&lt;br /&gt;
:* Output CRS: Select an appropriate Coordinate Reference System (CRS) for the model. For the demonstration model, the CRS is &#039;EPSG:32760 - WGS 84 / UTM zone 60S&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; Click &#039;Run&#039;. Once the tool is finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_XPtoTUFLOW_Convert_01c.mp4|width=1350}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Inspect the output of the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Convert_XPSWMM_Model_From_XPX|Convert - XPSWMM model from XPX]]&amp;lt;/u&amp;gt;&#039; processing tool and load the TUFLOW model into QGIS:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows File Explorer, inspect the files output by the processing tool. In particular:&lt;br /&gt;
* The &#039;&#039;&#039;TUFLOW\bc_dbase&#039;&#039;&#039; folder contains the BC Database which will contain any curves used in BC conditions, for easy extending to other events.&lt;br /&gt;
* The &#039;&#039;&#039;TUFLOW\model&#039;&#039;&#039; folder contains the TUFLOW SWMM Control File (TSCF) which holds all commands specific to SWMM, including links to the converted SWMM INP file. &lt;br /&gt;
* The &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder contains a GeoPackage database (&#039;&#039;&#039;*_convert_messages.gpkg&#039;&#039;&#039;). This GeoPackage contains locations and descriptions of any errors or warnings that occurred during the conversion process. &lt;br /&gt;
: &#039;&#039;&#039;Note:&#039;&#039;&#039; Conversion messages are addressed in further detail here &amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM_Troubleshooting#Common_Conversion_Issues |XPSWMM to TUFLOW SWMM Troubleshooting]]&amp;lt;/u&amp;gt;. &lt;br /&gt;
* The &#039;&#039;&#039;TUFLOW\runs&#039;&#039;&#039; folder contains the TCF. If event(s) are specified, the TCF filename with have event placeholder(s), i.e. &#039;_~e1~_~e2~_&#039; (e.g. &#039;&#039;&#039;1D2D_Urban_001_~e1~.tcf&#039;&#039;&#039;). Again, if event(s) are used, this folder also contains the TUFLOW Event File (TEF) with the event(s) specified. &amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_XPtoTUFLOW_Convert_02b.mp4|width=800}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open QGIS, and click on the ‘Load TUFLOW Layers from TCF’ symbol from the QGIS TUFLOW Plugin toolbar.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File: Tuflow_plugin_load_tcf_layers.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Navigate to the location of the TUFLOW model and go to the &#039;&#039;&#039;TUFLOW\runs&#039;&#039;&#039; folder. Select the TCF.&lt;br /&gt;
&amp;lt;li&amp;gt; In the Load Layers window, select:&lt;br /&gt;
* Ordering Options: Alphabetical&lt;br /&gt;
* Grouping Options: Group by control file&lt;br /&gt;
* Raster Load Options: Load Normally &lt;br /&gt;
&amp;lt;li&amp;gt; Click ‘Open’ and ‘OK’.&lt;br /&gt;
&amp;lt;li&amp;gt; Change the symbology of the DTM dataset:&lt;br /&gt;
* In the QGIS Layers panel, right click on the DTM Grid file and select &#039;Properties&#039;.&lt;br /&gt;
* In the Symbology tab, under &#039;Band Rendering&#039;, set the &#039;Render type&#039; to &#039;Hillshade&#039; and the &#039;Z Factor&#039; to 3.&lt;br /&gt;
&amp;lt;li&amp;gt; Inspect the output GIS layers.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_XPtoTUFLOW_Convert_03b.mp4|width=1350}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Recommended Additional Conversion Steps == &lt;br /&gt;
While the bulk of the XPSWMM to TUFLOW SWMM model conversion is automated by the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Convert_XPSWMM_Model_From_XPX|Convert - XPSWMM model from XPX]]&amp;lt;/u&amp;gt;&#039; processing tool, some required or recommended conventions must be implemented/updated manually. Therefore, it is highly recommended to complete the additional conversion steps: &amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM_Recommended_Additional_Conversion_Steps|Recommended Additional Conversion Steps]]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt; &lt;br /&gt;
These steps can help improve model stability and they may also be helpful to address any messages that occurred when using the conversion tool. &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== TUFLOW Simulation Execution ==&lt;br /&gt;
Set up a simple batch file (.bat) to run TUFLOW. This approach calls the TUFLOW executable file (.exe) and runs the TCF file.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Create a new text file in the &#039;&#039;&#039;TUFLOW\runs&#039;&#039;&#039; folder and save as &#039;&#039;&#039;_run_HPC.bat&#039;&#039;&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt;Open the &#039;&#039;&#039;_run_HPC.bat&#039;&#039;&#039; in a text editor and include a file path to the TUFLOW executable and the TCF name: &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;set &amp;lt;/font&amp;gt;exe&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;=&amp;lt;/font&amp;gt;&amp;quot;..\..\exe\2025.2.1\TUFLOW_iSP_w64.exe&amp;quot;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;set &amp;lt;/font&amp;gt;run&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;=&amp;lt;/font&amp;gt;start &amp;quot;TUFLOW&amp;quot; /wait &amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;%exe%&amp;lt;/font&amp;gt; -b&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;%run%&amp;lt;/font&amp;gt; -e1 100yr 1D2D_Urban_001_~e1~.tcf&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;/tt&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; A relative path is used for the executable and the TCF, full file path can also be used.&lt;br /&gt;
&amp;lt;li&amp;gt;Save the batch file and double click it in Windows File Explorer to run the simulation. This will open the TUFLOW Console Window and the simulation should be executed. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
TUFLOW simulations can be executed via numerous ways. A comprehensive summary of the most commonly used approaches is documented in the &amp;lt;u&amp;gt;[[Running_TUFLOW | Running TUFLOW]]&amp;lt;/u&amp;gt; Wiki page.&lt;br /&gt;
&lt;br /&gt;
=== Troubleshooting ===&lt;br /&gt;
Did your TUFLOW SWMM model fail to run successfully? If so, here is a link to a troubleshooting guide: &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Troubleshooting | TUFLOW SWMM Troubleshooting]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= TUFLOW SWMM Result Viewing =&lt;br /&gt;
Are you familiar with loading and viewing TUFLOW results in QGIS? If not, we strongly recommend self-registering and completing our free eLearning: &lt;br /&gt;
&amp;lt;u&amp;gt;[https://www.tuflow.com/training/training-course-catalogue/tt001-e-introduction-to-qgis-for-tuflow-elearning/ Introduction to QGIS for TUFLOW]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Our &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_Introduction | TUFLOW SWMM Tutorials]]&amp;lt;/u&amp;gt; also demonstrate working with TUFLOW SWMM results.&lt;br /&gt;
&lt;br /&gt;
= Recommended Further Reading =&lt;br /&gt;
For users who wish to get a better understanding of either 2D TUFLOW or 1D EPA SWMM, the following resources may be of use:&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;TUFLOW&#039;&#039;&#039;: &amp;lt;u&amp;gt;[https://www.tuflow.com www.tuflow.com]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://www.tuflow.com/downloads/#tuflow TUFLOW User Manual]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/ TUFLOW 2023-03-AD release notes]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[[Tutorial_Introduction#Tutorial_Modules | TUFLOW Tutorial Models]]&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;EPA SWMM&#039;&#039;&#039;: &amp;lt;u&amp;gt;[https://www.epa.gov/water-research/storm-water-management-model-swmm www.epa.gov]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume1_Hydrology_P100NYRA.pdf SWMM5 Reference Manual - Volume 1 (Hydrology)]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydaulics_P100S9AS.pdf SWMM5 Reference Manual - Volume 2 (Hydraulics) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydraulics_Addendum-20220210mas2wr.pdf  SWMM5 Reference Manual - Volume 2 (Hydraulics Addendum) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume3_Water_Quality_P100P2NY.pdf  SWMM5 Reference Manual - Volume 3 (Water Quality) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
*&amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/swmm-users-manual-version-5.2.pdf EPA SWMM5 User&#039;s Manual]&amp;lt;/u&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Contact=&lt;br /&gt;
For comments, requests and feedback contact &amp;lt;u&amp;gt;[mailto:support@tuflow.com support@tuflow.com]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
For further training opportunities see &amp;lt;u&amp;gt;[https://tuflow.com/training/training-course-catalogue/ TUFLOW Training Catalogue]&amp;lt;/u&amp;gt; and/or contact &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[Main_Page| Back to Wiki Main Page]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_M04&amp;diff=45216</id>
		<title>TUFLOW SWMM Tutorial M04</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_M04&amp;diff=45216"/>
		<updated>2025-11-25T01:27:04Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Running the Simulation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Introduction =&lt;br /&gt;
This tutorial, Module 4 of the TUFLOW SWMM tutorial dataset will demonstrate TUFLOW&#039;s in-built event management functionality. This powerful functionality runs multiple event combinations (e.g. magnitude, duration, temporal patterns, climate change) using a single set of control files, rather than creating a new set of control files for every event simulation. This tutorial demonstrates how event management can be used on a smaller scale, running only 6 models.&amp;lt;br&amp;gt;&lt;br /&gt;
The real power of event management is seen when running a model of a much greater size. For example, without implementing event management, a project requiring simulation of the following event combinations would require 144 TCF and bc_dbase files:&lt;br /&gt;
:*6 x Event Magnitude:	01%, 2%, 5%, 10%, 20% and 50% Annual Exceedance Probability (AEP)&lt;br /&gt;
:*8 x Event Duration:	1, 2, 3, 6, 9, 12, 18 and 24 hour storm&lt;br /&gt;
:*3 x Climate Change Planning Horizon:	current climate, 2050, 2100&lt;br /&gt;
Using predefined naming conventions, with TUFLOW&#039;s event management functionality, all the events can be executed from a single TCF and bc_dbase file!  &lt;br /&gt;
&lt;br /&gt;
This feature of TUFLOW makes management of the model files easier, ensures consistency between the simulations and improves project quality control by reducing the likelihood of human error associated with incorrect file referencing. &amp;lt;br&amp;gt;  &lt;br /&gt;
&lt;br /&gt;
TUFLOW SWMM Tutorial Module 4 builds from the model created in &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M03|TUFLOW SWMM Tutorial Module 3]]&amp;lt;/u&amp;gt;. The completed TUFLOW SWMM Module 3 model is provided in the &#039;&#039;&#039;&#039;&#039;TUFLOW_SWMM_Module_04\TUFLOW&#039;&#039;&#039;&#039;&#039; folder of the download dataset as the starting point for this tutorial. If you are not already familiar with TUFLOW SWMM linking, we recommend completing TUFLOW SWMM Modules 1, 2 and 3 prior to starting this tutorial. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Simulation Control Files =&lt;br /&gt;
TUFLOW&#039;s automated event management operates by introducing wildcard referencing into the boundary condition database.&amp;lt;br&amp;gt;&lt;br /&gt;
A new control file, called the &#039;TUFLOW Event File&#039; (TEF) is added. It lists all event titles that are applied to the wildcard character in the boundary condition database. It also lists unique commands to associate with the specific events.&amp;lt;br&amp;gt;&lt;br /&gt;
Models are executed using a batch file, with the event specifically listed as a variable in the batch file syntax.&lt;br /&gt;
&lt;br /&gt;
This tutorial example will upgrade our single simulation model to run six event simulations. The simulations will cater for three Annual Exceedance Probability (AEP) event magnitudes:  5%, 2% and 1% AEP. In Average Recurrence Interval (ARI) terminology, this translates to the 1 in 20, 50 and 100 year ARI events. These three design events will be simulated for two event storm durations: 1 and 2 hours.&amp;lt;br&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
=== TUFLOW Boundary Condition Database (bc_dbase) ===&lt;br /&gt;
The first task when upgrading a model to include Event Management functionality is to decide on a naming convention for the event wildcard characters to be used in the bc_dbase.csv.&lt;br /&gt;
*Event Magnitude: &#039;&#039;&#039;AEP&#039;&#039;&#039;&lt;br /&gt;
*Event Duration: &#039;&#039;&#039;DUR&#039;&#039;&#039;&lt;br /&gt;
Update the bc_dbase with event magnitude and event duration wildcard characters. &lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_04\Tutorial_Data&#039;&#039;&#039; folder. Copy and paste the following files to the &#039;&#039;&#039;TUFLOW_SWMM_Module_04\TUFLOW\bc_dbase&#039;&#039;&#039; folder. These files contain the inflows and rainfall for each event magnitude and duration. &lt;br /&gt;
:*&#039;&#039;&#039;TS04_inflow_05p1hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_inflow_05p2hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_inflow_02p1hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_inflow_02p2hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_inflow_01p1hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_inflow_01p2hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_rainfall_05p1hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_rainfall_05p2hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_rainfall_02p1hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_rainfall_02p2hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_rainfall_01p1hr.csv&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;TS04_rainfall_01p2hr.csv&#039;&#039;&#039; &amp;lt;br&amp;gt;&lt;br /&gt;
The files with &#039;inflow&#039; in their name are flow hydrograph boundary conditions sourced from an external hydrology model, such as HEC-HMS, RORB, URBS, WBNM etc. &amp;lt;br&amp;gt;&lt;br /&gt;
The files with &#039;rainfall&#039; in their name are rainfall depth hyetographs used to define rainfall timeseries in the SWMM urban hydrology section of the model.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Save a copy of the &#039;&#039;&#039;bc_dbase_TS03_001.csv&#039;&#039;&#039; as &#039;&#039;&#039;bc_dbase_TS04_001.csv&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Open the file and make the following updates to the &#039;Source&#039; column. The &#039;AEP&#039; and &#039;DUR&#039; wildcards must be between the special character &#039;~&#039; to function as a variable. Note, columns E to I are to remain blank. The final &#039;&#039;&#039;bc_dbase_TS04_001.csv&#039;&#039;&#039; should look like this: &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:SWMM_M04_event_bcdbase_01a.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save &#039;&#039;&#039;bc_dbase_TS04_001.csv&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS4_Sim_Control_01b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== TUFLOW Event File (TEF) ===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_04\Tutorial_Data&#039;&#039;&#039; folder. Copy the &#039;&#039;&#039;TS04_Event_File.tef&#039;&#039;&#039; to the &#039;&#039;&#039;TUFLOW_SWMM_Module_04\TUFLOW\runs&#039;&#039;&#039; folder. &lt;br /&gt;
&amp;lt;li&amp;gt;Open the TEF in a Text Editor (Notepad++ is recommended). There are three event magnitudes and two event durations listed:&lt;br /&gt;
:*Event Magnitudes: 5% , 2% and 1% AEP&lt;br /&gt;
:*Event Durations: 1hr and 2hrs&lt;br /&gt;
&amp;lt;li&amp;gt;The event specific commands are contained between the &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Define Event&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; and &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;End Define&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; commands. &lt;br /&gt;
&amp;lt;li&amp;gt;The &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;BC Event Source&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; command is linked to the bc_dbase file (&#039;&#039;&#039;bc_dbase_TS04_001.csv&#039;&#039;&#039;). In the below examples, any occurrence of &#039;~AEP~&#039; in &#039;&#039;&#039;bc_dbase_TS04_001.csv&#039;&#039;&#039; will be replaced with &#039;05p&#039; and any occurrence of &#039;~DUR~&#039; in &#039;&#039;&#039;bc_dbase_TS04_001.csv&#039;&#039;&#039; will be replaced with &#039;1hr&#039;. Also, when the 1 hour event is called the simulation, the end time will be set to 2 hours (instead of 3 hours, as per the other simulations). &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! EVENT MAGNITUDES&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Define Event&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;05p&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
 &amp;lt;ol&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;   BC Event Source &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; ~AEP~ | 05p&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;End Define&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! EVENT DURATIONS&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Define Event&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;1hr&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
 &amp;lt;ol&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;   BC Event Source &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; ~DUR~ | 1hr&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
    &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;   End Time &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; 2&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;End Define&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; When TUFLOW runs a simulation, it reads all of the defined events in the TEF, though only uses the event variables specified in the batch file. We will create a compatible batch file shortly.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS4_Sim_Control_02c.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== TUFLOW Control File (TCF) ===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open &#039;&#039;&#039;TS03_5m_001.tcf&#039;&#039;&#039; in a Text Editor (Notepad++ is recommended). Save the file as &#039;&#039;&#039;TS04_5m_~e1~_~e2~_001.tcf&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_04\TUFLOW\runs&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;li&amp;gt;Make the following reference update:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;BC Database &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\bc_dbase\bc_dbase_TS04_001.csv&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the Boundary Conditions Database&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following commands to reference the TEF at the end of the TCF:  &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! EVENTS&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Event File &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;TS04_Event_File.tef&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the TUFLOW Event File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
The location of this command in the TCF is important. If there are any commands associated with an event which overwrite other existing commands (such as &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;End Time&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;==&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;), the TEF file needs to be processed last for it to take precedence over other commands fulfilling the same purpose. Referencing this file in the last line in the TCF ensures this order of operation occurs as intended.&amp;lt;br&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Save the TCF.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS4_Sim_Control_03c.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Running the Simulation =&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save a copy of &#039;&#039;&#039;_run_TS03_HPC.bat&#039;&#039;&#039; as &#039;&#039;&#039;_run_TS04_HPC.bat&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_04\TUFLOW\runs&#039;&#039;&#039; folder.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Update the batch file to reference the &#039;&#039;&#039;TS04_5m_~e1~_~e2~_001.tcf&#039;&#039;&#039; and include event switches (-e1, -e2) defining event magnitude and event duration:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&#039;&#039;&#039;set&#039;&#039;&#039;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;exe&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&amp;quot;..\..\..\exe\2025.2.1\TUFLOW_iSP_w64.exe&amp;quot;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&#039;&#039;&#039;set&#039;&#039;&#039;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;run&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;start &amp;quot;TUFLOW&amp;quot; /wait&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; %exe%&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -b&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -e1 05p -e2 1hr TS04_5m_~e1~_~e2~_001.tcf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -e1 05p -e2 2hr TS04_5m_~e1~_~e2~_001.tcf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -e1 02p -e2 1hr TS04_5m_~e1~_~e2~_001.tcf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -e1 02p -e2 2hr TS04_5m_~e1~_~e2~_001.tcf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -e1 01p -e2 1hr TS04_5m_~e1~_~e2~_001.tcf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -e1 01p -e2 2hr TS04_5m_~e1~_~e2~_001.tcf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save the batch file and double click it in Windows File Explorer to run the simulation.&amp;lt;br&amp;gt;&lt;br /&gt;
If the model simulation doesn&#039;t run, here is a link to some common &amp;lt;u&amp;gt;[[Tutorial_Troubleshooting_QGIS | Trouble Shooting]]&amp;lt;/u&amp;gt; advice.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS4_Run_Sim_01c.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Troubleshooting ==&lt;br /&gt;
Did your TUFLOW SWMM model fail to run successfully? If so, here is a link to a troubleshooting guide: &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Troubleshooting | TUFLOW SWMM Troubleshooting]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Advanced Looping Batch File (Optional)=&lt;br /&gt;
Looping batch files are a powerful tool to enable high volume simulation management with the least amount syntax, and subsequently manual effort. For example, the following looped batch file executed 1440 simulation using 15 lines of syntax!&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:SWMM_M04_advanced_looping_batch_01c.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
We will convert our sequential formatted batch file to a looped format:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save a copy of &#039;&#039;&#039;_run_TS04_HPC.bat&#039;&#039;&#039; as &#039;&#039;&#039;_run_TS04_HPC_loop.bat&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_04\TUFLOW\runs&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following commands. Indentation is important in batch files, insert tabs to match the below spacing:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;echo &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;off&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;set &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;exe&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&amp;quot;..\..\..\exe\2023-03-AF\TUFLOW_iSP_w64.exe&amp;quot;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;set &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;run&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;start &amp;quot;TUFLOW&amp;quot; /wait &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%exe%&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -b&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;set&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; AEP&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;05p 02p 01p&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;set&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; DUR&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;1hr 2hr&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;for &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%%a&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; in &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;(&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%AEP%&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; do &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;(&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;	for &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%%b&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; in &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;(&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%DUR%&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;)&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; do &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;( &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&amp;lt;ol&amp;gt;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;	echo &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Running &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%%a %%b &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
	&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; %run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;-e1 &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%%a&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -e2 &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%%b &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;TS04_5m_~e1~_~e2~_001.tcf&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&amp;lt;/ol&amp;gt;)&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;)&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; The &#039;AEP&#039; and &#039;DUR&#039; are user defined batch file variables. Projects may use different variable names. The &#039;AEP&#039; refers to an event magnitude (Annual Exceedance Probability) and &#039;DUR&#039; refers to an event duration.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Save the batch file and double click it in Windows File Explorer to run the simulation.&lt;br /&gt;
If the model simulation doesn&#039;t run, here is a link to some common &amp;lt;u&amp;gt;[[Tutorial_Troubleshooting_QGIS | Trouble Shooting]]&amp;lt;/u&amp;gt; advice.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS4_Run_Sim_02b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Check and Result Files =&lt;br /&gt;
When the TUFLOW models were executed via the batch file, the names of check and result files should have been updated to include the event variables from the simulation. For example:&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; width=&amp;quot;60%&amp;quot; style=&amp;quot;text-align:center&amp;quot;&lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| TCF &lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Event 1 (-e1) &lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Event 2 (-e2)&lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Check and Result filename &lt;br /&gt;
|-&lt;br /&gt;
|rowspan=&amp;quot;6&amp;quot;|TS04_5m_&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;&#039;~e1~_~e2~&#039;&#039;&#039;&amp;lt;/font&amp;gt;_001.tcf&lt;br /&gt;
| 05p || 1hr || TS04_5m_&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;&#039;05p_1hr&#039;&#039;&#039;&amp;lt;/font&amp;gt;_001&lt;br /&gt;
|-&lt;br /&gt;
| 05p || 2hr || TS04_5m_&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;&#039;05p_2hr&#039;&#039;&#039;&amp;lt;/font&amp;gt;_001&lt;br /&gt;
|-&lt;br /&gt;
| 02p || 1hr || TS04_5m_&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;&#039;02p_1hr&#039;&#039;&#039;&amp;lt;/font&amp;gt;_001&lt;br /&gt;
|-&lt;br /&gt;
| 02p || 2hr || TS04_5m_&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;&#039;02p_2hr&#039;&#039;&#039;&amp;lt;/font&amp;gt;_001&lt;br /&gt;
|-&lt;br /&gt;
| 01p || 1hr || TS04_5m_&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;&#039;01p_1hr&#039;&#039;&#039;&amp;lt;/font&amp;gt;_001&lt;br /&gt;
|-&lt;br /&gt;
| 01p || 2hr || TS04_5m_&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&#039;&#039;&#039;01p_2hr&#039;&#039;&#039;&amp;lt;/font&amp;gt;_001&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Check Sucessful Completion of Multiple Simulations==&lt;br /&gt;
Open &#039;&#039;&#039;_TUFLOW Simulations.log&#039;&#039;&#039; from the &#039;&#039;&#039;TUFLOW_SWMM_Module_04\TUFLOW\runs&#039;&#039;&#039; folder. Confirm &#039;Finished&#039; is tagged next to the entry for each of the six simulations we executed. This log confirms the model simulation was completed.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS4_Results_01b.mp4|width=1350}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Viewing Multiple Simulation Results==&lt;br /&gt;
===Load Results===&lt;br /&gt;
Open the simulation results in QGIS. When loading multiple simulations which include 1D results (all with the same object IDs), a two step load workflow is recommended to avoid filling the QGIS layer panel with duplicate 1D object entries.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open TUFLOW Viewer from the TUFLOW Plugin toolbar.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:tuflow_plugin_tuflow_viewer.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Open 1D and 2D results: Select File &amp;gt; Load Results. Navigate to the &#039;&#039;&#039;TUFLOW\runs&#039;&#039;&#039; folder and select &#039;&#039;&#039;TS04_5m_~e1~_~e2~_001.tcf&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; When asked which simulation to load, select &#039;&#039;&#039;TS04_5m_01p_1hr_001&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; When asked &#039;Do you want to open result GIS layer?&#039;, select &#039;Yes&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt; After &#039;&#039;&#039;TS04_5m_01p_1hr_001&#039;&#039;&#039; has loaded, open the remaining result files:&lt;br /&gt;
* Select File &amp;gt; Load Results. Navigate to the &#039;&#039;&#039;TUFLOW\runs&#039;&#039;&#039; folder and select &#039;&#039;&#039;TS04_5m_~e1~_~e2~_001.tcf&#039;&#039;&#039;.&lt;br /&gt;
* When asked which simulation to load, select all remaining results (except &#039;&#039;&#039;TS04_5m_01p_1hr_001&#039;&#039;&#039;).&lt;br /&gt;
* When asked &#039;Do you want to open result GIS layer?&#039;, select &#039;No&#039;.  The results will still be loaded, though will all be associated with the GIS objects loaded for the &#039;&#039;&#039;TS04_5m_01p_1hr_001&#039;&#039;&#039; simulation. &lt;br /&gt;
&amp;lt;li&amp;gt; In the QGIS Layers Panel, move the GIS vector (line and point) layers to the top of the list. This will ensure these layers are displayed above all mesh result layers in the project. &lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS4_Results_02c.mp4|width=1350}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Mesh Results (Map Output)===&lt;br /&gt;
Inspect the results for all events.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Zoom in to the pipe network area.&lt;br /&gt;
&amp;lt;li&amp;gt;Click on the scalar dataset &#039;Depth&#039; under the &#039;Result Type&#039; in the TUFLOW Viewer &#039;Map Outputs&#039; list. Toggle on the maximum depth output by clicking the [[File: max_output_icon.png]] symbol.&lt;br /&gt;
&amp;lt;li&amp;gt;Click through the results in the &#039;Open Results&#039; list to observe the different max depth values.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS4_Results_03c.mp4|width=1350}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Vector Results (Pipe Network Output)===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, right click &#039;&#039;&#039;TS04_5m_01p_1hr_001_swmm_ts_L&#039;&#039;&#039;, and select &#039;Show Labels&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Use the &#039;Select Features&#039; tool to highlight &#039;Pipe 3&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt;In the &#039;Open Results&#039; list, select all 1hr duration event results (hold Ctrl to select multiple). &lt;br /&gt;
&amp;lt;li&amp;gt;Click on a scalar dataset &#039;Flow&#039; under the &#039;Result Type&#039; in the TUFLOW Viewer &#039;Time Series&#039; list. &lt;br /&gt;
&amp;lt;li&amp;gt;Try multiple combinations of the simulation results to observe how the different events impacted flow through &#039;Pipe 3&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click the &#039;Refresh Current Plot&#039; [[File: Refreshplotblack.png || 20px]] button to update the plot window after making new selections. &lt;br /&gt;
&amp;lt;li&amp;gt;Click the &#039;Clear Current Plot&#039; [[File: QGIS_Plugin_Icon_ClearPlot.png || 20px]] button to remove all data from the plot window if needed prior to making a new selection.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS4_Results_04c.mp4|width=1350}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Conclusion =&lt;br /&gt;
*Automated Event Management functionality was added to the TUFLOW SWMM model.&lt;br /&gt;
*Multiple event simulations were run in sequence from a batch file.&lt;br /&gt;
*Creation of looped batch file was demonstrated for the efficient execution of bulk simulations.&lt;br /&gt;
*Multiple event simulation results were inspected using the QGIS TUFLOW Viewer.&lt;br /&gt;
*For further training opportunities see &amp;lt;u&amp;gt;[https://tuflow.com/training/training-course-catalogue/ TUFLOW Training Catalogue]&amp;lt;/u&amp;gt; and/or contact &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Other TUFLOW SWMM Tutorials=&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01 | TUFLOW SWMM Module 1]]&amp;lt;/u&amp;gt;  - 1D SWMM Culverts&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02 | TUFLOW SWMM Module 2]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 2D TUFLOW Direct Rainfall Hydrology&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M03 | TUFLOW SWMM Module 3]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M04 | TUFLOW SWMM Module 4]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology: Executing multiple different event simulations from a single model control file.&lt;br /&gt;
*&amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM | XPSWMM to TUFLOW SWMM]]&amp;lt;/u&amp;gt;  - How to convert an XPSWMM model to TUFLOW SWMM.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[TUFLOW_SWMM_Tutorial_Introduction#Tutorial_Modules| Back to TUFLOW SWMM Tutorial Introduction Main Page]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_M03&amp;diff=45215</id>
		<title>TUFLOW SWMM Tutorial M03</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_M03&amp;diff=45215"/>
		<updated>2025-11-25T01:26:34Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Running the Simulation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Introduction =&lt;br /&gt;
This tutorial, Module 3 of the TUFLOW-SWMM tutorial dataset, demonstrates how to add SWMM urban hydrology to a 1D SWMM stormwater pipe network / 2D TUFLOW HPC catchment model. TUFLOW-SWMM Tutorial Module 3 builds from the model created in &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02|TUFLOW SWMM Tutorial Module 2]]&amp;lt;/u&amp;gt;. The completed TUFLOW-SWMM Module 2 model is provided in the &#039;&#039;&#039;&#039;&#039;TUFLOW_SWMM_Module_03\TUFLOW&#039;&#039;&#039;&#039;&#039; folder of the download dataset as the starting point for this tutorial. If you are not already familiar with TUFLOW-SWMM linking, we recommend completing TUFLOW-SWMM Modules 1 and 2 prior to starting this tutorial. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Project Initialization =&lt;br /&gt;
==QGIS==&lt;br /&gt;
QGIS Version 3.34 or newer, and QGIS TUFLOW Plugin 3.11 or newer are required to access the SWMM Processing Tools described in the following sections. For installation, see &amp;lt;u&amp;gt;[https://wiki.tuflow.com/TUFLOW_QGIS_Plugin Installation of TUFLOW Plugin]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
Define the Coordinate Reference System (CRS), also called ‘Projection’, for the QGIS workspace:&lt;br /&gt;
&amp;lt;ol&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Open QGIS.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to Project &amp;gt; Properties… &lt;br /&gt;
&amp;lt;li&amp;gt;In the CRS tab, type ‘WGS 84 / UTM Zone 60S’.&lt;br /&gt;
&amp;lt;li&amp;gt;Select the matching projection in the &#039;Predefined Coordinate Reference Systems&#039; section.&lt;br /&gt;
&amp;lt;li&amp;gt;Click ‘Apply’ and ‘OK’.&lt;br /&gt;
&amp;lt;li&amp;gt;Ensure that the projection is set correctly by viewing the bottom right hand corner of the workspace. It should read ‘EPSG:32760’.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Initialization_01a.mp4|width=1235}}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==TUFLOW Model==&lt;br /&gt;
===Load and Style TUFLOW Model Files===&lt;br /&gt;
Load in the project GIS layers:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Click on the ‘Load TUFLOW Layers from TCF’ symbol from the TUFLOW Plugin toolbar.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File: Tuflow_plugin_load_tcf_layers.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\TUFLOW\runs&#039;&#039;&#039; folder and select &#039;&#039;&#039;TS02_5m_001.tcf&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Load Layers window, select:&lt;br /&gt;
* Ordering Options: Alphabetical&lt;br /&gt;
* Grouping Options: Group by control file&lt;br /&gt;
* Raster Load Options: Load Normally &lt;br /&gt;
&amp;lt;li&amp;gt;Click ‘Open’ and ‘OK’.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Style the TUFLOW layers. Suggested styling steps were provided in &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01#Load_and_Style_TUFLOW_Model_Files|TUFLOW SWMM Tutorial M01]]&amp;lt;/u&amp;gt;. They have not been duplicated here.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===TUFLOW Plugin===&lt;br /&gt;
Next we need to configure the QGIS TUFLOW Plugin settings to link with the project folder where we will build our model:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open the &#039;Configure TUFLOW Project&#039; tool by selecting Plugins &amp;gt; TUFLOW &amp;gt; Editing &amp;gt; Configure / Create TUFLOW Project.&lt;br /&gt;
&amp;lt;li&amp;gt;Set the CRS (Coordinate Reference System) by selecting one of the vector layers associated with the opened model using the drop menu list. For example, &#039;&#039;2d_bc_M01_001_L&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;To set the location of the TUFLOW folder, click &#039;Browse...&#039; and navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_03&#039;&#039;&#039; folder. Click &#039;Select Folder&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt;To set the location of the TUFLOW single precision executable file, click &#039;Browse...&#039; and navigate to the &#039;&#039;&#039;exe\2023-03-AF&#039;&#039;&#039; folder. Select &#039;&#039;&#039;TUFLOW_iSP_w64.exe&#039;&#039;&#039; and click &#039;Open&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;GPKG&#039; as the GIS Format. &lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;TUFLOW Classic / HPC&#039; as the TUFLOW Engine.&lt;br /&gt;
&amp;lt;li&amp;gt;Tick on &#039;Save Default Settings Globally&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;OK&#039;.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File: TS3_Configure_Project_01a.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Increment TUFLOW GeoPackage File === &lt;br /&gt;
We will now save a copy of &#039;&#039;&#039;TS02_001.gpkg&#039;&#039;&#039; with a new name, &#039;&#039;&#039;TS03_001.gpkg&#039;&#039;&#039;. This project initialization step is recommended so prior model versions from a project are not broken as a result of changes being made to GIS inputs.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;2d_bc_M01_001_L&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click on the &#039;Increment Selected Layer&#039; symbol from the TUFLOW Plugin toolbar. This opens the dialog shown below. &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:tuflow_plugin_increment_layer.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
:*Source Layer: Automatically set to the selected layer, &#039;&#039;&#039;2d_bc_M01_001_L&#039;&#039;&#039;.&lt;br /&gt;
:*Output Database: Click &#039;Browse...&#039;. This will automatically open to the &#039;&#039;&#039;TUFLOW\model\gis&#039;&#039;&#039; folder. Set the new output database name to &#039;&#039;&#039;TS03_001.gpkg&#039;&#039;&#039; and click &#039;Save&#039;.&lt;br /&gt;
:*Output Layer Name: This will automatically increment to &#039;&#039;&#039;2d_bc_M01_00&#039;&#039;2&#039;&#039;_L&#039;&#039;&#039;. Change the name back to &#039;&#039;&#039;2d_bc_M01_00&#039;&#039;1&#039;&#039;_L&#039;&#039;&#039;.&lt;br /&gt;
:*Delete the pre-filled &#039;Incremented Layer&#039; entry in the table. We do not wish to modify the version number associated with the 2d_bc file. This current exercise will not change the version number of any of the GIS layer inputs, it is simply establishing a copy of the existing GeoPackage where future edits will be saved to.&lt;br /&gt;
:*Select &#039;Remove Source Layer from Workspace&#039;.&lt;br /&gt;
:*Select &#039;Increment Layer and Preserve Database&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;OK&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;The GeoPackage database, &#039;&#039;&#039;TS03_001.gpkg&#039;&#039;&#039; will now be in the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\TUFLOW\model\gis&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_Initialization_02b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Increment SWMM GeoPackage File === &lt;br /&gt;
SWMM pipe network junction attributes need to be updated when converting a TUFLOW 2D direct rainfall / SWMM 1D model &amp;lt;u&amp;gt;([[TUFLOW_SWMM_Tutorial_M02|TUFLOW SWMM Tutorial Module 2]]&amp;lt;/u&amp;gt;). into a format that uses SWMM hydrology instead of direct rainfall. Similar to above (incrementing the TUFLOW GeoPackage file), we will increment the SWMM pipe network database name so we do not alter the inputs necessary for &#039;&#039;&#039;TS02_5m_001.tcf&#039;&#039;&#039; to function without issue. &lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In the QGIS Layers Panel, open the &#039;&#039;&#039;TS02_001.tscf&#039;&#039;&#039; group. In the &#039;&#039;&#039;sw02_001.inp&#039;&#039;&#039; group, right click &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; Select TUFLOW &amp;gt; SWMM - Increment GeoPackage. This opens the dialog shown below. &lt;br /&gt;
:*Output File: Click the &#039;...&#039;. This will automatically open to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder. Set the output database name to &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039; and click &#039;Save&#039;. &lt;br /&gt;
:*Existing GeoPackage Layers: &#039;Unload -- do not move&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; Select &#039;OK&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; The tool will automatically load &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039; into the QGIS workspace and remove &#039;&#039;&#039;sw02_001.inp&#039;&#039;&#039; from the QGIS workspace.&lt;br /&gt;
&amp;lt;li&amp;gt; In the QGIS Layers Panel, move &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039; to the top of the list. This will ensure the data within this database file is displayed above all other layers in the project. &lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_Initialization_03b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Save QGIS Project Workspace===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Go to Project &amp;gt; Save As.&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_03&#039;&#039;&#039; folder and type &#039;&#039;&#039;SWMM_M03&#039;&#039;&#039; as the filename with the extension .qgz.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= GIS Inputs =&lt;br /&gt;
==Update SWMM GeoPackage Spatial Database== &lt;br /&gt;
In previous tutorials we have created new SWMM GeoPackage databases for our new entries. This tutorial will demonstrate a different update approach. Instead of creating a new SWMM GeoPackage database, we will update the existing database, &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039; by adding new SWMM Sections for the hydrology elements we will be incorporating into the model in this tutorial.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Go to Processing &amp;gt; Toolbox from the top dropdown menu options to open the Processing Toolbox.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to TUFLOW &amp;gt;&amp;gt; SWMM in the processing tool list and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_GeoPackage_Add_Sections |GeoPackage - Add sections]]&amp;lt;/u&amp;gt;&#039;. This opens the dialog shown below.&lt;br /&gt;
:*GPKG filename modify: Click the ... and navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\TUFLOW\model\swmm&#039;&#039;&#039; folder. Select &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039;.&lt;br /&gt;
:*CRS for GeoPackage: Click the drop down menu and select &#039;Project CRS: EPSG:32760 - WGS 84 / UTM zone 60S&#039;.&lt;br /&gt;
:*SWMM Sections to add: Click the ..., and tick on:&lt;br /&gt;
::*&#039;&#039;&#039;Hydrology--Raingages&#039;&#039;&#039;&lt;br /&gt;
::*&#039;&#039;&#039;Hydrology--Subcatchments&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Run&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool is finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_SWMM_Inputs_01b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The above steps have added the new sections to the SWMM GeoPackage database, &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039;. However, the new sections are not currently displayed in the QGIS Layers Panel. We need to close the database and reopen it to view the changes.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, right click &#039;&#039;&#039;sw03_001&#039;&#039;&#039; and select &#039;Remove Group...&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In Windows File Explorer, navigate to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder and drag and drop &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039; into QGIS. &lt;br /&gt;
&amp;lt;li&amp;gt;When prompted by QGIS, under &#039;Options&#039;, tick on &#039;Add layers to group&#039;, then select &#039;Add Layers&#039; to open all vectors within &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039;. By default, all items in the available list should have been selected. &lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, move &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039; to the top of the list. This will ensure the data within this database file is displayed above all other layers in the project when we are making edits. &lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, within the &#039;&#039;&#039;sw03_001&#039;&#039;&#039; group, move &#039;&#039;&#039;Hydrology--Subcatchments&#039;&#039;&#039; to the bottom. This will ensure that the other data within this database can be seen. &lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_SWMM_Inputs_02b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== SWMM GIS Data Entry ==&lt;br /&gt;
&lt;br /&gt;
A GeoPackage called &#039;&#039;&#039;Urban_Hydrology.gpkg&#039;&#039;&#039; is provided in the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\Tutorial_Data&#039;&#039;&#039; folder. It contains one SWMM input layer and one TUFLOW input layer: &lt;br /&gt;
:*&#039;&#039;&#039;SWMM_Subcatchments&#039;&#039;&#039;: defines the 1D SWMM urban hydrology subcatchment delineation and associated parameters.&lt;br /&gt;
:*&#039;&#039;&#039;TUFLOW_Subcatchments&#039;&#039;&#039;: defines the remaining 2D TUFLOW catchment hydrology subcatchment delineation.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To populate the SWMM GeoPackage created in the previous section:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In Windows File Explorer, navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\Tutorial_Data&#039;&#039;&#039; folder. Drag and drop the &#039;&#039;&#039;Urban_Hydrology.gpkg&#039;&#039;&#039; into QGIS. &lt;br /&gt;
&amp;lt;li&amp;gt;When prompted by QGIS select &#039;&#039;&#039;SWMM_Subcatchments&#039;&#039;&#039;. Click &#039;Add Layers&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, right click on the &#039;&#039;&#039;SWMM_Subcatchments&#039;&#039;&#039; layer and select &#039;Zoom to Layer(s)&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Use the &#039;Select Features&#039; tool to highlight all items included in &#039;&#039;&#039;SWMM_Subcatchments&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Edit&#039; from the top QGIS tab and &#039;Copy Features&#039; from the drop down menu. &lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) the &#039;&#039;&#039;sw03_001 &amp;gt;&amp;gt; Hydrology--Subcatchments&#039;&#039;&#039; layer. &lt;br /&gt;
&amp;lt;li&amp;gt;Make the &#039;&#039;&#039;sw03_001 &amp;gt;&amp;gt; Hydrology--Subcatchments&#039;&#039;&#039; layer editable by clicking the &#039;Toggle Editing&#039; symbol [[File:toggle_editing_icon.png|27x27px]].&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Edit&#039; from the top QGIS tab and click &#039;Paste Features&#039; from the drop down menu.&lt;br /&gt;
&amp;lt;li&amp;gt;Toggle the editing off to save the edits.&lt;br /&gt;
&amp;lt;li&amp;gt;Remove &#039;&#039;&#039;Urban_Hydrology&#039;&#039;&#039; from the QGIS Layers Panel.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_SWMM_Inputs_03b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==SWMM GIS Data Updates==&lt;br /&gt;
The following updates are being made to the objects and layers within &#039;&#039;&#039;sw03_001.gpkg&#039;&#039;&#039;. &lt;br /&gt;
&lt;br /&gt;
===Update SWMM Hydrology Raingages===&lt;br /&gt;
The text information within &#039;&#039;&#039;Hydrology--Raingages&#039;&#039;&#039; defines the pluviographs in the catchment. We will link to two different rain gages in this example. &amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; &#039;Gage&#039; is the American spelling of &#039;Gauge&#039; in Oxford English.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Hydrology--Raingages&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt;Right click &#039;&#039;&#039;Hydrology--Raingages&#039;&#039;&#039; and select &#039;Open Attribute Table&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Add Feature&#039; twice. Enter the following attributes (leave all other fields as &#039;&#039;NULL&#039;&#039;):&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; width=&amp;quot;60%&amp;quot;&lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Name &lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Form &lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Intevl &lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| SnowCatchDeficiency&lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Format &lt;br /&gt;
!style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot;| Tseries &lt;br /&gt;
|-&lt;br /&gt;
| RF_G1 || Volume || 0.1 || 1 || TIMESERIES || RF_FC04 &lt;br /&gt;
|-&lt;br /&gt;
| RF_G2 || Volume || 0.1 || 1 || TIMESERIES || RF_FC07 &lt;br /&gt;
|}&lt;br /&gt;
For a summary of the attributes associated with &#039;&#039;&#039;Hydrology--Raingages&#039;&#039;&#039;, refer to &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/SWMM-Input-Detailed-1.html#tab:tab-SWMM-Input-Raingages TUFLOW 2023-03-AD Release Notes (Table A.11)]&amp;lt;/u&amp;gt; and the &amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume1_Hydrology_P100NYRA.pdf SWMM5 Reference Manual - Volume 1 (Hydrology)]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
Note, the spatial locations where the gage information is applied is covered in the following section.&lt;br /&gt;
&amp;lt;li&amp;gt; Turn off editing and save the information.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_SWMM_Inputs_04b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Update SWMM Hydrology Subcatchments===&lt;br /&gt;
The information within &#039;&#039;&#039;Hydrology--Subcatchments&#039;&#039;&#039; defines the subcatchment parameters (including catchment area, width, slope, percent impervious, outlet specification and infiltration details). All required data entries have been pre-filled in the supplied dataset except the &#039;Area&#039; information, which we will determine using QGIS. SWMM requires the hydrology subcatchment area information in hectares.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Hydrology--Subcatchments&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt;Right click &#039;&#039;&#039;Hydrology--Subcatchments&#039;&#039;&#039; and select &#039;Open Attribute Table&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Choose &#039;Area&#039; as the target field and type the calculation expression, &#039;area($geometry) / 10000&#039;. &lt;br /&gt;
:* &#039;area($geometry) &#039;: Extracts the area of each region (subcatchment) in &#039;&#039;&#039;Hydrology--Subcatchments&#039;&#039;&#039;.&lt;br /&gt;
:* &#039;/ 10000&#039;: Converts the area values into hectares.&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; The projection used in these tutorials is measured in meters. Thus, when QGIS extracts the area from a region, it reports the area in m&amp;lt;sup&amp;gt;2&amp;lt;/sup&amp;gt;. If using a projection that is measured in feet, QGIS would extract the area in ft&amp;lt;sup&amp;gt;2&amp;lt;/sup&amp;gt;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Update All&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing and save the information.&lt;br /&gt;
&amp;lt;li&amp;gt;Inspect the attribute information within &#039;&#039;&#039;Hydrology--Subcatchments&#039;&#039;&#039; to familiarize yourself with the data. A few demonstration features have been included in the dataset. &lt;br /&gt;
:*Two rainfall gages are linked to the subcatchments. Downstream subcatchments linked to rain gage &#039;RF_G1&#039;. Upstream subcatchments are linked to rain gage &#039;RF_G2&#039;.&lt;br /&gt;
:*Subcatchments &#039;SPit11A&#039; and &#039;SPit11A&#039; are being routed to subcatchment &#039;SPit11C&#039; before entering the SWMM pipe network. All other hydrology subcatchments route directly to a SWMM &#039;&#039;&#039;Node--Junctions&#039;&#039;&#039;.&amp;lt;br&amp;gt;&lt;br /&gt;
For a summary of the attributes associated with the layer, refer to &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/SWMM-Input-Detailed-1.html#tab:tab-SWMM-Input-Subcatchments TUFLOW 2023-03-AD Release Notes (Table A.38)]&amp;lt;/u&amp;gt; and the &amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume1_Hydrology_P100NYRA.pdf SWMM5 Reference Manual - Volume 1 (Hydrology)]&amp;lt;/u&amp;gt;. &lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_SWMM_Inputs_05b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===SWMM Options===&lt;br /&gt;
SWMM &#039;&#039;&#039;Project--Options&#039;&#039;&#039; defines the SWMM simulation controls, such as hydrology computation timestep. &#039;&#039;&#039;Project--Options&#039;&#039;&#039; are not required in the new GeoPackage database we are creating for this Tutorial. This is because this model will be constructed from multiple SWMM input (INP) files:&lt;br /&gt;
:*&#039;&#039;&#039;sw01_001.inp&#039;&#039;&#039; (road culverts).&lt;br /&gt;
:*&#039;&#039;&#039;sw03_001.inp&#039;&#039;&#039; (underground pipe network inputs and SWMM hydrology).&lt;br /&gt;
When TUFLOW processes SWMM inputs, it combines the multiple INP files into one single INP prior to simulation. For this model, the simulation control parameters defined in Module 1 (&#039;&#039;&#039;sw01_001 &amp;gt; Project--Options&#039;&#039;&#039;) will apply. The options relevant to this tutorial that have already been defined in the Module 1 input include:&lt;br /&gt;
:*&#039;&#039;&#039;flow_units&#039;&#039;&#039;: set to metric.&lt;br /&gt;
:*&#039;&#039;&#039;infiltration&#039;&#039;&#039; method: set to Green Ampt.&lt;br /&gt;
We need to change the SWMM hydrology timestep details. Updating this setting in the &#039;&#039;&#039;sw01_001.inp&#039;&#039;&#039; does not impact any of the previous tutorial modules, as they did not include any hydrology components. &lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, open the &#039;&#039;&#039;TS02_001.tscf&#039;&#039;&#039; group and select (left click) &#039;&#039;&#039;sw01_001 &amp;gt;&amp;gt; Project--Options&#039;&#039;&#039; and toggle on editing. &lt;br /&gt;
&amp;lt;li&amp;gt;Right click &#039;&#039;&#039;Project--Options&#039;&#039;&#039; and select &#039;Open Attribute Table&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Update the following hydrology timestep options: &lt;br /&gt;
:*WET_STEP: 00:01:00&lt;br /&gt;
:*DRY_STEP: 00:01:00&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing to save the edits.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_SWMM_Inputs_06b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Export SWMM INP File ==&lt;br /&gt;
We will now create a new INP file for the pipe network and SWMM urban hydrology inputs and update &#039;&#039;&#039;sw01_001.inp&#039;&#039;&#039; to reflect the changes made to the hydrology options above.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, right click &#039;&#039;&#039;Hydrology--Subcatchments&#039;&#039;&#039; (or any other SWMM layer in the same GeoPackage) and select &#039;TUFLOW&#039; &amp;gt; &#039;SWMM - Export inp file&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;This will open the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_GeoPackage_Write_to_SWMM_inp |GeoPackage - Write to SWMM inp]]&amp;lt;/u&amp;gt;&#039; processing tool, prepopulated with the filename of the layer&#039;s GeoPackage. &amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; This tool can also be activated from the Processing Toolbox. &lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Run&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool is finished, update the &#039;GeoPackage Input File&#039; parameter. Click &#039;...&#039;, and navigate to the &#039;&#039;&#039;TUFLOW\model\gis&#039;&#039;&#039; folder. Select &#039;&#039;&#039;sw01_001.gpkg&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Run&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool is finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;This tool will save the SWMM inp files in the same folder location and with the same name as the GeoPackage input file. In this case, it will save &#039;&#039;&#039;sw03_001.inp&#039;&#039;&#039; and &#039;&#039;&#039;sw01_001.inp&#039;&#039;&#039; to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_SWMM_Inputs_07b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==TUFLOW GIS Updates==&lt;br /&gt;
We will be reverting the TUFLOW model back to a configuration that uses inflows from an external hydrology model (as per Module 1), instead of 2D direct rainfall (Module 2), in the areas not covered by SWMM urban hydrology. Instead of reusing the input from Module 1, we will need to use a new TUFLOW source area inflow layer. This will ensure that we do not double count the flow generated over the area now represented by SWMM.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Click on the ‘Import Empty File’ symbol from the TUFLOW plugin toolbar. &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:tuflow_plugin_import_empty_file.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;2d_sa&#039; from the Empty Type list.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run ID box write &#039;TS03_001&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Tick the &#039;Regions&#039; Geometry Type.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Spatial Database Options, select &#039;All to one&#039;. Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\TUFLOW\model\gis&#039;&#039;&#039; folder and select &#039;&#039;&#039;TS03_001.gpkg&#039;&#039;&#039;. Click Save and hit &#039;OK&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;The &#039;&#039;&#039;2d_sa_TS03_001_R&#039;&#039;&#039; appears in the QGIS Layers Panel.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:TS3_import_empty_2d_sa_01a.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In Windows File Explorer, navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\Tutorial_Data&#039;&#039;&#039; folder. Drag and drop the &#039;&#039;&#039;Urban_Hydrology.gpkg&#039;&#039;&#039; into QGIS. &lt;br /&gt;
&amp;lt;li&amp;gt;When prompted by QGIS, select &#039;&#039;&#039;TUFLOW_Subcatchments&#039;&#039;&#039;. Click &#039;Add Layers&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) the &#039;&#039;&#039;TUFLOW_Subcatchments&#039;&#039;&#039; layer.&lt;br /&gt;
&amp;lt;li&amp;gt;Use the &#039;Select Features&#039; tool to highlight the four regions included in &#039;&#039;&#039;TUFLOW_Subcatchments&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Edit&#039; from the top QGIS tab and &#039;Copy Features&#039; from the drop down menu. &lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) the &#039;&#039;&#039;2d_sa_TS03_001_R&#039;&#039;&#039; layer.&lt;br /&gt;
&amp;lt;li&amp;gt;Make the &#039;&#039;&#039;2d_sa_TS03_001_R&#039;&#039;&#039; layer editable by clicking the &#039;Toggle Editing&#039; symbol [[File:toggle_editing_icon.png|27x27px]].&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Edit&#039; from the top QGIS tab and click &#039;Paste Features&#039; from the drop down menu.&lt;br /&gt;
&amp;lt;li&amp;gt;Toggle off editing to save the edits.&lt;br /&gt;
&amp;lt;li&amp;gt;Remove &#039;&#039;&#039;Urban_Hydrology.gpkg&#039;&#039;&#039;.&amp;lt;br&amp;gt;&lt;br /&gt;
The polygon entry we have updated refers to a new subcatchment name for the region adjacent to the SWMM subcatchments. The new name is &#039;FC06.62&#039;, instead of &#039;FC06&#039;. When we update the TUFLOW Control files we will configure the file references so we are sourcing data from a new flow file obtained from an external hydrology model that has been updated with the reduced catchment area, in recognition of SWMM being used for the flow estimate in the proposed urban development area. &amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Common hydrology software used in combination with TUFLOW by modelers include: HEC-HMS, RORB, Drains, WBNM, URBS and more.&#039;&#039;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_TUFLOW_Inputs_01b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==TUFLOW Boundary Updates==&lt;br /&gt;
As a result of the changes made to the TUFLOW inflows, new TUFLOW Boundary Condition csv files are also needed. Updated files have been provided in the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\Tutorial_Data&#039;&#039;&#039; folder. These files provide the values and model linkages to the new hydrology inflows, which include the &#039;FC06.62&#039; entry.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Copy &#039;&#039;&#039;bc_dbase_TS03_001.csv&#039;&#039;&#039; and &#039;&#039;&#039;TS03_01p2hr.csv&#039;&#039;&#039; from the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\Tutorial_Data&#039;&#039;&#039; folder to the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\TUFLOW\bc_dbase&#039;&#039;&#039; folder. &lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_TUFLOW_Boundary_01b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simulation Control Files=&lt;br /&gt;
To avoid the potential risk of overwriting existing control files accidentally, we will start by saving new control files where we will be making subsequent syntax updates during the following steps.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open &#039;&#039;&#039;TS02_5m_001.tcf&#039;&#039;&#039; in a Text Editor (Notepad++ is recommended). Save the file as &#039;&#039;&#039;TS03_5m_001.tcf&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\TUFLOW\runs&#039;&#039;&#039; folder. &lt;br /&gt;
&amp;lt;li&amp;gt;Using the &#039;Open File&#039; function in Notepad++: &lt;br /&gt;
:*Open &#039;&#039;&#039;TS02_001.tbc,&#039;&#039;&#039;  and save the file as &#039;&#039;&#039;TS03_001.tbc&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW\model&#039;&#039;&#039; folder.&lt;br /&gt;
:*Open &#039;&#039;&#039;TS02_001.tscf,&#039;&#039;&#039;  and save the file as &#039;&#039;&#039;TS03_001.tscf&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW\model&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===TUFLOW Control File (TCF)===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Edit &#039;&#039;&#039;TS03_5m_001.tcf&#039;&#039;&#039; by making the following reference updates:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Spatial Database &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\model\gis\TS03_001.gpkg&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Specify the location of the GeoPackage Spatial Database&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;BC Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\model\TS03_001.tbc&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the TUFLOW Boundary Condition Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;BC Database&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\bc_dbase\bc_dbase_TS03_001.csv&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the Boundary Condition Database&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;SWMM Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\model\TS03_001.tscf&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the SWMM (1D) Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Add the following command to the &#039;&amp;lt;tt&amp;gt;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;Time Control&amp;lt;/font&amp;gt;&amp;lt;/tt&amp;gt;&#039; section. This command is necessary for many TUFLOW-SWMM models, especially when using SWMM hydrology. The 2D timestep dictates the SWMM 1D timestep. Generally, this timestep is adequate for SWMM but in cases where the flows are contained in the 1D, the timestep may become too large for SWMM. This command forces it into the appropriate range. If this command is neglected, some models will experience very high mass errors. The range of timesteps used is reported in the SWMM .rpt file (&#039;&#039;&#039;TS03_5m_001_swmm.rpt&#039;&#039;&#039;) in the &#039;&#039;&#039;TUFLOW\results&#039;&#039;&#039; folder.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Timestep Maximum &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;3&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Specifies a maximum timestep of 3 seconds&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Comment out the &#039;Map Cuttoff Depth&#039; command by placing a &#039;!&#039; at the beginning of the line. This command is only necessary for 2D direct rainfall (rain on grid) modelling (SWMM Tutorial 2).&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! Map Cutoff Depth == 0.05&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_Sim_Control_01b.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===TUFLOW Boundary Control File (TBC)===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Edit &#039;&#039;&#039;TS03_001.tbc&#039;&#039;&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt;Comment out the &#039;Global Rainfall BC&#039; command by placing a &#039;!&#039; at the beginning of the line. This command is only necessary for 2D direct rainfall (rain on grid) modelling (SWMM Tutorial 2).&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! Global Rainfall BC == RF_FC04&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following additional command:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read GIS SA&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;2d_sa_TS03_001_R &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! Reads in 2D source area - Excluding SWMM areas&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_Sim_Control_02c.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===TUFLOW SWMM Control File (TSCF)===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Edit &#039;&#039;&#039;TS03_001.tscf&#039;&#039;&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt;Replace &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read SWMM&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;swmm\sw02_001.inp&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; with the following command:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read SWMM&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;swmm\sw03_001.inp&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;As we are pushing flows from the subcatchments straight to the pipe network, the water level of the ponded water at the nodes can become much higher than the 2D water levels. The inlet will surcharge but the flow is throttled. The following command will pull water out of the 2D if the 1D ponded water level goes beyond 0.1 m higher than the 2D (not needed for rain on grid simulations). Add the following command:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Maximum Inlet Ponded Depth&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;0.1 &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! Pull ponded water out of the 1D domain as needed&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following command:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read BC Timeseries&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; == &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;RF_FC04 | RF_FC07 &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! TUFLOW BC Database / SWMM Rain Gage Linkage&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_Sim_Control_03c.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Running the Simulation=&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save a copy of &#039;&#039;&#039;_run_TS02_HPC.bat&#039;&#039;&#039; as &#039;&#039;&#039;_run_TS03_HPC.bat&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\TUFLOW\runs&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;li&amp;gt;Update the batch file to reference the &#039;&#039;&#039;TS03_5m_001.tcf&#039;&#039;&#039; :&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&#039;&#039;&#039;set&#039;&#039;&#039;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;exe&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&amp;quot;..\..\..\exe\2025.2.1\TUFLOW_iSP_w64.exe&amp;quot;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&#039;&#039;&#039;set&#039;&#039;&#039;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;run&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;start &amp;quot;TUFLOW&amp;quot; /wait&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; %exe%&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -b&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;TS03_5m_001.tcf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Save the batch file and double click it in Windows File Explorer to run the simulation. &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Did your TUFLOW-SWMM model fail to run successfully? If so, here is a link to a troubleshooting guide: &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Troubleshooting | TUFLOW SWMM Troubleshooting]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS3_Run_Sim_01c.mp4|width=1236}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Check Files = &lt;br /&gt;
Review the SWMM INP and simulation report file from the &#039;&#039;&#039;TUFLOW_SWMM_Module_03\TUFLOW\results&#039;&#039;&#039; folder to confirm the new hydrology inputs are being processed correctly:&lt;br /&gt;
* View &#039;&#039;&#039;TS03_5m_001_swmm.inp&#039;&#039;&#039; in a text editor to confirm the combining of the two input INP files has occurred correctly. Also use the QGIS Processing tool, &amp;lt;u&amp;gt;[[QGIS_SWMM_GeoPackage_Create_from_SWMM_inp |GeoPackage - Create from SWMM inp ]]&amp;lt;/u&amp;gt;, to view the information in QGIS. &lt;br /&gt;
* View &#039;&#039;&#039;TS03_5m_001_swmm_curves.inp&#039;&#039;&#039; in a text editor to confirm the rainfall time series that has been used by the SWMM hydrology engine matches the input dataset.&lt;br /&gt;
* View &#039;&#039;&#039;TS03_5m_001_swmm.rpt&#039;&#039;&#039; in a text editor to confirm the model computation is healthy in term of mass conservation.&lt;br /&gt;
&lt;br /&gt;
= Results Output =&lt;br /&gt;
Complete the steps outlined in following link to review the simulation results from the TUFLOW SWMM model simulation:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M03_Results_QGIS | TUFLOW SWMM Tutorial 03 Results]]&amp;lt;/u&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Conclusion =&lt;br /&gt;
*EPA SWMM urban hydrology was added to the model (replacing 2D drect rainfall / rain-on-grid).&lt;br /&gt;
*The 1D SWMM pipe urban pipe network junction attributes were updated to accomodate for the change in model configuration, from 2D direct rainfall to 1D SWMM hydrology.&lt;br /&gt;
*Check and result files associated with the SWMM hydrology modelling were inspected.&lt;br /&gt;
*For further training opportunities see &amp;lt;u&amp;gt;[https://tuflow.com/training/training-course-catalogue/ TUFLOW Training Catalogue]&amp;lt;/u&amp;gt; and/or contact &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Other TUFLOW SWMM Tutorials=&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01 | TUFLOW SWMM Module 1]]&amp;lt;/u&amp;gt;  - 1D SWMM Culverts&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02 | TUFLOW SWMM Module 2]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 2D TUFLOW Direct Rainfall Hydrology&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M03 | TUFLOW SWMM Module 3]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M04 | TUFLOW SWMM Module 4]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology: Executing multiple different event simulations from a single model control file.&lt;br /&gt;
*&amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM | XPSWMM to TUFLOW SWMM]]&amp;lt;/u&amp;gt;  - How to convert an XPSWMM model to TUFLOW SWMM.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[TUFLOW_SWMM_Tutorial_Introduction#Tutorial_Modules| Return to TUFLOW SWMM Tutorial Introduction Main Page]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_M02&amp;diff=45214</id>
		<title>TUFLOW SWMM Tutorial M02</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_M02&amp;diff=45214"/>
		<updated>2025-11-25T01:25:42Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Running the Simulation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Introduction =&lt;br /&gt;
This tutorial, Module 2 of the TUFLOW SWMM tutorial dataset will demonstrate how to model underground stormwater pipe networks using SWMM, linked to the TUFLOW HPC 2D solution scheme. Boundary condition inflows to the model are defined using TUFLOW&#039;s 2D direct rainfall (rain on grid) approach. TUFLOW SWMM Tutorial Module 2 builds from the model created in &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01|TUFLOW SWMM Tutorial Module 1]]&amp;lt;/u&amp;gt;. The completed TUFLOW SWMM Module 1 model is provided in the &#039;&#039;&#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW&#039;&#039;&#039;&#039;&#039; folder of the download dataset as the starting point for this tutorial. If you are not already familiar with TUFLOW SWMM linking, we recommend completing TUFLOW SWMM Module 1 prior to starting this tutorial. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Project Initialization =&lt;br /&gt;
==QGIS==&lt;br /&gt;
QGIS Version 3.34 or newer, and QGIS TUFLOW Plugin 3.11 or newer are required to access the SWMM Processing Tools described in the following sections. For installation, see &amp;lt;u&amp;gt;[https://wiki.tuflow.com/TUFLOW_QGIS_Plugin Installation of TUFLOW Plugin]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
Define the Coordinate Reference System (CRS), also called ‘Projection’, for the QGIS workspace:&lt;br /&gt;
&amp;lt;ol&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Open QGIS.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to Project &amp;gt; Properties… &lt;br /&gt;
&amp;lt;li&amp;gt;In the CRS tab, type ‘WGS 84 / UTM Zone 60S’.&lt;br /&gt;
&amp;lt;li&amp;gt;Select the matching projection in the &#039;Predefined Coordinate Reference Systems&#039; section.&lt;br /&gt;
&amp;lt;li&amp;gt;Click ‘Apply’ and ‘OK’.&lt;br /&gt;
&amp;lt;li&amp;gt;Ensure that the projection is set correctly by viewing the bottom right hand corner of the workspace. It should read ‘EPSG:32760’.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Initialization_01a.mp4|width=1235}}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==TUFLOW Model==&lt;br /&gt;
===Load and Style TUFLOW Model Files===&lt;br /&gt;
Load in the project GIS layers:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Click on the ‘Load TUFLOW Layers from TCF’ symbol from the TUFLOW Plugin toolbar.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File: Tuflow_plugin_load_tcf_layers.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW\runs&#039;&#039;&#039; folder and select &#039;&#039;&#039;TS01_5m_001.tcf&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Load Layers window, select:&lt;br /&gt;
* Ordering Options: Alphabetical&lt;br /&gt;
* Grouping Options: Group by control file&lt;br /&gt;
* Raster Load Options: Load Normally &lt;br /&gt;
&amp;lt;li&amp;gt;Click ‘Open’ and ‘OK’.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Style the TUFLOW layers. Suggested styling steps were provided in &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01#Project_Initialization|TUFLOW SWMM Tutorial M01]]&amp;lt;/u&amp;gt;. They have not been duplicated here.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===TUFLOW Plugin===&lt;br /&gt;
Next we need to configure the QGIS TUFLOW Plugin settings to link with the project folder where we will build our model:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open the &#039;Configure TUFLOW Project&#039; tool by selecting Plugins &amp;gt; TUFLOW &amp;gt; Editing &amp;gt; Configure / Create TUFLOW Project.&lt;br /&gt;
&amp;lt;li&amp;gt;Set the CRS (Coordinate Reference System) by selecting one of the vector layers associated with the opened model using the drop menu list. For example, &#039;&#039;2d_bc_M01_001_L&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;To set the location of the TUFLOW folder, click &#039;Browse...&#039; and navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02&#039;&#039;&#039; folder. Click &#039;Select Folder&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt;To set the location of the TUFLOW single precision executable file, click &#039;Browse...&#039; and navigate to the &#039;&#039;&#039;exe\2023-03-AF&#039;&#039;&#039; folder. Select &#039;&#039;&#039;TUFLOW_iSP_w64.exe&#039;&#039;&#039; and click &#039;Open&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;GPKG&#039; as the GIS Format. &lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;TUFLOW Classic / HPC&#039; as the TUFLOW Engine.&lt;br /&gt;
&amp;lt;li&amp;gt;Tick on &#039;Save Default Settings Globally&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;OK&#039;.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File: TS2_Configure_Project_01a.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Increment TUFLOW GeoPackage File === &lt;br /&gt;
We will now save a copy of &#039;&#039;&#039;TS01_001.gpkg&#039;&#039;&#039; with a new name, &#039;&#039;&#039;TS02_001.gpkg&#039;&#039;&#039;. This project initialization step is recommended so prior model versions from a project are not broken as a result of changes being made to GIS inputs.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;2d_bc_M01_001_L&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click on the &#039;Increment Selected Layer&#039; symbol from the TUFLOW Plugin toolbar. This opens the dialog shown below. &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:tuflow_plugin_increment_layer.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
:*Source Layer: Automatically set to the selected layer, &#039;&#039;&#039;2d_bc_M01_001_L&#039;&#039;&#039;.&lt;br /&gt;
:*Output Database: Click &#039;Browse...&#039;. This will automatically open to the &#039;&#039;&#039;TUFLOW\model\gis&#039;&#039;&#039; folder. Set the new output database name to &#039;&#039;&#039;TS02_001.gpkg&#039;&#039;&#039; and click &#039;Save&#039;.&lt;br /&gt;
:*Output Layer Name: This will automatically increment to &#039;&#039;&#039;2d_bc_M01_00&#039;&#039;2&#039;&#039;_L&#039;&#039;&#039;. Change the name back to &#039;&#039;&#039;2d_bc_M01_00&#039;&#039;1&#039;&#039;_L&#039;&#039;&#039;.&lt;br /&gt;
:*Delete the pre-filled &#039;Incremented Layer&#039; entry in the table. We do not wish to modify the version number associated with the 2d_bc file. This current exercise will not change the version number of any of the GIS layer inputs, it is simply establishing a copy of the existing GeoPackage where future edits will be saved to.&lt;br /&gt;
:*Select &#039;Remove Source Layer from Workspace&#039;.&lt;br /&gt;
:*Select &#039;Increment Layer and Preserve Database&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;OK&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;The GeoPackage database, &#039;&#039;&#039;TS02_001.gpkg&#039;&#039;&#039; will now be in the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW\model\gis&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_Initialization_02c.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Save QGIS Project Workspace===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Go to Project &amp;gt; Save As.&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02&#039;&#039;&#039; folder and type &#039;&#039;&#039;SWMM_M02&#039;&#039;&#039; as the filename with the extension .qgz.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= GIS Inputs =&lt;br /&gt;
==Create SWMM GeoPackage Spatial Database== &lt;br /&gt;
We will create a new SWMM GeoPackage database for our pipe network feature entries:&lt;br /&gt;
&amp;lt;ol&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Go to Processing &amp;gt; Toolbox from the top dropdown menu options to open the Processing Toolbox.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to TUFLOW &amp;gt;&amp;gt; SWMM in the processing tool list and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_GeoPackage_Create |GeoPackage - Create]]&amp;lt;/u&amp;gt;&#039;. This opens the dialog shown below.&lt;br /&gt;
:*To set the ‘CRS for GeoPackage’: Click the drop down menu and select ‘Project CRS: EPSG:32760 - WGS 84 / UTM zone 60S’.&lt;br /&gt;
:*To set the ‘Initial SWMM Sections’: Click the …, and tick on (if not already ticked): &lt;br /&gt;
::*&#039;&#039;&#039;Nodes--Junctions&#039;&#039;&#039;, &#039;&#039;&#039;Nodes--Outfalls.&#039;&#039;&#039; &lt;br /&gt;
::*&#039;&#039;&#039;Links--Conduits, Links--Streets.&#039;&#039;&#039;&lt;br /&gt;
::*&#039;&#039;&#039;Inlets--Inlets.&#039;&#039;&#039;&lt;br /&gt;
:*To define the ‘GPKG filename to create’: Click the …, select ‘Save to File’. Navigate to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder and save the GeoPackage Database as &#039;&#039;&#039;sw02_001.gpkg&#039;&#039;&#039;.&lt;br /&gt;
::&#039;&#039;&#039;Note:&#039;&#039;&#039; In Module 1 we also included &#039;&#039;&#039;Nodes--Storage&#039;&#039;&#039;, &#039;&#039;&#039;Project--Title&#039;&#039;&#039;, &#039;&#039;&#039;Project--Options&#039;&#039;&#039;, and &#039;&#039;&#039;Project--Report&#039;&#039;&#039; in the GeoPackage file. &#039;&#039;&#039;Project--Options&#039;&#039;&#039; is not required this time as this tutorial model will use two SWMM INP files. The file created during Module 1 (for the road culverts) and the INP is to be created from this GeoPackage (for the underground pipe network inputs). When TUFLOW processes SWMM inputs, it combines the multiple INP files into one before simulation. As such, the details from the Module 1 &#039;&#039;&#039;Project--Options&#039;&#039;&#039; input will be used in this tutorial. If &#039;&#039;&#039;Project--Options&#039;&#039;&#039; are included in multiple Geopackage/INP files, the entry that is referenced lowest in the TUFLOW SWMM Control file (TSCF) will be used. &#039;&#039;&#039;Nodes--Storage&#039;&#039;&#039; will not be used in this tutorial, as these are only needed to represent detention, or for nodes connected using HX boundaries.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Run&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool has finished, click ‘Close’.&lt;br /&gt;
&amp;lt;li&amp;gt;In Windows File Explorer, navigate to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder and drag and drop &#039;&#039;&#039;sw02_001.gpkg&#039;&#039;&#039; into QGIS. &lt;br /&gt;
&amp;lt;li&amp;gt;When prompted by QGIS, under &#039;Options&#039;, tick on &#039;Add layers to group&#039;, then select &#039;Add Layers&#039; to open all vectors within &#039;&#039;&#039;sw02_001.gpkg&#039;&#039;&#039;. By default, all items in the available list should have been selected. &lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, move &#039;&#039;&#039;sw02_001.gpkg&#039;&#039;&#039; to the top of the list. This will ensure the data within this database file is displayed above all other layers in the project. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_01e.mp4|width=1236}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== GIS Data Entry ==&lt;br /&gt;
&lt;br /&gt;
A GeoPackage called &#039;&#039;&#039;Urban_Development.gpkg&#039;&#039;&#039; is provided in the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\Tutorial_Data&#039;&#039;&#039; folder. It contains three SWMM input layers (and five other geometry input layers to be used later in the module): &lt;br /&gt;
:*&#039;&#039;&#039;Pipes&#039;&#039;&#039;: defines the underground pipe network location, type and geometry.&lt;br /&gt;
:*&#039;&#039;&#039;Junctions&#039;&#039;&#039;: defines the pipe network inlets.&lt;br /&gt;
:*&#039;&#039;&#039;Outfalls&#039;&#039;&#039;: defines the pipe network outlet.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
To populate the GeoPackage database created in the previous section:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In Windows File Explorer, navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\Tutorial_Data&#039;&#039;&#039; folder. Drag and drop the &#039;&#039;&#039;Urban_Development.gpkg&#039;&#039;&#039; into QGIS. &lt;br /&gt;
&amp;lt;li&amp;gt;When prompted by QGIS, under &#039;Options&#039;, tick on &#039;Add layers to group&#039;, then select &#039;&#039;&#039;Pipes&#039;&#039;&#039;, &#039;&#039;&#039;Junctions&#039;&#039;&#039; and &#039;&#039;&#039;Outfalls&#039;&#039;&#039; (hold Ctrl to select multiple). Click &#039;Add Layers&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, right click on the &#039;&#039;&#039;Pipes&#039;&#039;&#039; layer and select &#039;Zoom to Layer(s)&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Use the &#039;Select Features&#039; tool to highlight all items included in &#039;&#039;&#039;Pipes&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Edit&#039; from the top QGIS tab and &#039;Copy Features&#039; from the drop down menu. &lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) the &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; layer.&lt;br /&gt;
&amp;lt;li&amp;gt;Make the &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; layer editable by clicking the &#039;Toggle Editing&#039; symbol [[File:toggle_editing_icon.png|27x27px]].&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Edit&#039; from the top QGIS tab and click &#039;Paste Features&#039; from the drop down menu.&lt;br /&gt;
&amp;lt;li&amp;gt;Toggle the editing off to save the edits.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_02d.mp4|width=1236}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Similarly, copy the objects from &#039;&#039;&#039;Junctions&#039;&#039;&#039; into &#039;&#039;&#039;Nodes--Junctions&#039;&#039;&#039;. Junctions are considered inlets, and should be defined at the upstream end of isolated culverts and all upstream ends of pipes within a network.&lt;br /&gt;
&amp;lt;li&amp;gt;Also copy the objects from &#039;&#039;&#039;Outfalls&#039;&#039;&#039; into &#039;&#039;&#039;Nodes--Outfalls&#039;&#039;&#039;. Outfalls are treated as outlets, and are required at the downstream end of isolated culverts and the most downstream end of a pipe network.&lt;br /&gt;
&amp;lt;li&amp;gt;Toggle off editing to save the edits.&lt;br /&gt;
&amp;lt;li&amp;gt;Remove &#039;&#039;&#039;Urban_Development.gpkg&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_03c.mp4|width=1236}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Inspect the attribute information within the respective layers to familiarize yourself with the data.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_04c.mp4|width=1236}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== GIS Data Updates ==&lt;br /&gt;
The provided GIS data requires numerous updates, prior to our model simulation. We have built these updates into this tutorial to demonstrate some of the available TUFLOW SWMM model built processing tools. &lt;br /&gt;
&lt;br /&gt;
The following updates are being made to objects and layers within &#039;&#039;&#039;sw02_001.gpkg&#039;&#039;&#039;.&lt;br /&gt;
===Update SWMM Inlet Usage Layer Details===&lt;br /&gt;
An Inlet Usage Layer defines the physical location of inlets to the pipe network. It also defines some of the site specific geometry, such as inlet type, street cross-section reference, surface inlet elevation, placement type (on-sag and on-grade). To reduce data entry requirements for this tutorial, a complete Inlet Usage Layer has been provided, &#039;&#039;&#039;swmm_iu_TS02_001&#039;&#039;&#039;. It includes a variety of on-sag and on-grade inlets. On-sag inlets are used in locations where the inlet is located in an area of minimal longtudial slope. In this situation ponded surface water enters the pipe network. On-grade inlets are used where bypass flow is expected due to the inlet location being on a slope. For on-grade inlets, TUFLOW SWMM captures a percentage of the “approach flow” based on several factors including the total 2D approach flow, velocity and depth.&amp;lt;br&amp;gt;   &lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\Tutorial_Data&#039;&#039;&#039; folder and save a copy of &#039;&#039;&#039;swmm_iu_TS02_001&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW\model\swmm&#039;&#039;&#039; folder.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder. Drag and drop &#039;&#039;&#039;swmm_iu_TS02_001&#039;&#039;&#039; into the QGIS workspace.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you progress from this tutorial to project modeling, you will need to create an Inlet Usage Layer yourself. The template file for this is available from &#039;&#039;&#039;model\gis\empty\swmm_iu_empty.gpkg&#039;&#039;&#039;. The file is created during the initial &#039;Write Empty&#039; step of the model build process (refer to &amp;lt;u&amp;gt;[[Tutorial_M01#Project_Initialisation | TUFLOW Tutorial Model 1]]&amp;lt;/u&amp;gt;). A summary of the attributes within the Inlet Usage Layer is documented in   &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/SWMM-TUFLOW-1.html#tab:tab-SWMMinletusage TUFLOW 2023-03-AD Release Notes (Table 4.1)]&amp;lt;/u&amp;gt; &lt;br /&gt;
&lt;br /&gt;
The &#039;Inlet&#039; Attribute within &#039;&#039;&#039;swmm_iu_TS02_001&#039;&#039;&#039; is an ID reference to inlet geometry and associated information listed within &#039;&#039;&#039;sw02_001.gpkg&#039;&#039;&#039; &amp;gt;&amp;gt; &#039;&#039;&#039;Inlets--Inlets&#039;&#039;&#039;. A single inlet type, &#039;Combo1&#039;, was referenced in &#039;&#039;&#039;swmm_iu_TS02_001&#039;&#039;&#039; (the provided Inlet Usage Layer). In recognition of this, we need to create the entry for &#039;Combo1&#039; in the &#039;&#039;&#039;Inlets--Inlets&#039;&#039;&#039; layer. &lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Inlets--Inlets&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt;Right click &#039;&#039;&#039;Inlets--Inlets&#039;&#039;&#039; and select &#039;Open Attribute Table&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Add Feature&#039;. Enter the following attributes (leave all other fields as &#039;&#039;NULL&#039;&#039;):&lt;br /&gt;
:*Name: Combo1&lt;br /&gt;
:*Type: COMBINATION&lt;br /&gt;
:*Grate_Length: 0.6&lt;br /&gt;
:*Grate_Width: 0.3&lt;br /&gt;
:*Grate_Type: P_BAR-50&lt;br /&gt;
:*Curb_Length: 0.9&lt;br /&gt;
:*Curb_Height: 0.15&lt;br /&gt;
:*Curb_Throat: VERTICAL&lt;br /&gt;
For a summary of the attributes associated with the &#039;&#039;&#039;Inlets--Inlets&#039;&#039;&#039; layer, refer to &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/SWMM-Input-Detailed-1.html#tab:tab-SWMM-Input-Inlets TUFLOW 2023-03-AD Release Notes (Table A.16)]&amp;lt;/u&amp;gt; and the &amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydraulics_Addendum-20220210mas2wr.pdf  SWMM5 Reference Manual - Volume 2 (Hydraulics Addendum) ]&amp;lt;/u&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing to save the edits.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_05c.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Update Streets Details===&lt;br /&gt;
&lt;br /&gt;
Street cross-section information is needed for SWMM on-grade inlet flow calculations. A single street cross-section type named &#039;Xsec1&#039;, is referenced in &#039;&#039;&#039;swmm_iu_TS02_001&#039;&#039;&#039; (the Inlet Usage Layer) using the &#039;StreetXSEC&#039; field. &amp;lt;br&amp;gt;&lt;br /&gt;
We will now define this street cross-section type and its attributes. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Links--Streets&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt;Right click &#039;&#039;&#039;Links--Streets&#039;&#039;&#039; and select &#039;Open Attribute Table&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Add Feature&#039;. Enter the following attributes:&lt;br /&gt;
:*Name: Xsec1&lt;br /&gt;
:*Tcrown: 7&lt;br /&gt;
:*Hcurb: 0.2&lt;br /&gt;
:*Sx: 4&lt;br /&gt;
:*nRoad: 0.014&lt;br /&gt;
:*a: 0&lt;br /&gt;
:*W: 0&lt;br /&gt;
:*Sides: 1&lt;br /&gt;
:*Tback: 5&lt;br /&gt;
:*Sback: 2&lt;br /&gt;
:*nBack: 0.016&lt;br /&gt;
For a summary of the attributes associated with the &#039;&#039;&#039;Links--Streets&#039;&#039;&#039; layer, refer to &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/SWMM-Input-Detailed-1.html#tab:tab-SWMM-Input-Streets TUFLOW 2023-03-AD Release Notes (Table A.24)]&amp;lt;/u&amp;gt; and the &amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydaulics_P100S9AS.pdf SWMM Reference Manual - Volume 2 (Hydraulics)]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing to save the edits.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_06c.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Update Conduit Details===&lt;br /&gt;
====Node Details====&lt;br /&gt;
&lt;br /&gt;
The &#039;From Node&#039; and &#039;To Node&#039; attribute information in &#039;&#039;&#039;Links---Conduits&#039;&#039;&#039; is necessary to build the 1D SWMM network. It defines the link/node connections. The information we will be adding to &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; is extracted from &#039;&#039;&#039;Nodes--Junctions&#039;&#039;&#039; and &#039;&#039;&#039;Nodes--Outfalls&#039;&#039;&#039; automatically using the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Node_Fields |Conduits - Assign node fields]]&amp;lt;/u&amp;gt;&#039; tool from the Processing Toolbox.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Processing Toolbox, select the &#039;Edit Features In-Place&#039; tool [[File:edit_features_in_place_icon.png]]. This allows the editing of an existing layer, instead of the creation of a new layer.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to TUFLOW &amp;gt;&amp;gt; SWMM in the processing tool list and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Node_Fields |Conduits - Assign node fields]]&amp;lt;/u&amp;gt;&#039;. This opens the dialog shown below.&lt;br /&gt;
&amp;lt;li&amp;gt;Tick on the SWMM Node Layers: &#039;&#039;&#039;sw02_001 &amp;gt;&amp;gt; Nodes--Junctions&#039;&#039;&#039; and &#039;&#039;&#039;sw02_001 &amp;gt;&amp;gt; Nodes--Outfalls&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Modify All Features&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool has finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing to save the edits.&lt;br /&gt;
&amp;lt;li&amp;gt;View the attributes associated within &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; to verify the data processing has been completed correctly. The &#039;From Node&#039; and &#039;To Node&#039; attribute information is now configured correctly. &amp;lt;br&amp;gt;&lt;br /&gt;
For a broader understanding of the other attributes associated with the &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; layer, refer to &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/SWMM-Input-Detailed-1.html#tab:tab-SWMM-Input-Conduits TUFLOW 2023-03-AD Release Notes (Table A.19)]&amp;lt;/u&amp;gt; and the &amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydaulics_P100S9AS.pdf SWMM Reference Manual - Volume 2 (Hydraulics)]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tip:&#039;&#039;&#039; In a future modeling project, if you wish to only update selected objects, rather than the entire &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; dataset, select the target objects first using the &#039;Select Features by Area&#039; tool. The &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Node_Fields |Conduits - Assign node fields]]&amp;lt;/u&amp;gt;&#039; tool will provide an option to &#039;Modify Selected Features&#039;, instead of &#039;Modify All Features.&#039;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_07c.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Update Losses====&lt;br /&gt;
&lt;br /&gt;
Update the loss attributes in the &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; layer. These values will be entered automatically using the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Losses |Conduits - Assign losses]]&amp;lt;/u&amp;gt;&#039; tool from the Processing Toolbox. &lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Processing Toolbox, ensure the &#039;Edit Features In-Place&#039; tool [[File:edit_features_in_place_icon.png]] is still selected.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to TUFLOW &amp;gt;&amp;gt; SWMM in the processing tool list and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Losses |Conduits - Assign losses]]&amp;lt;/u&amp;gt;&#039;. This opens the dialog shown below.&lt;br /&gt;
:*Input inlet usage layers: &#039;&#039;&#039;swmm_iu_TS02_001&#039;&#039;&#039;.&lt;br /&gt;
:*Culvert opening - Entrance loss: 0.5&lt;br /&gt;
:*Culvert or pipe network outlet - Exit loss: 1.0&lt;br /&gt;
:*Pipe Network (manholes and pit inlets):&lt;br /&gt;
:::*Entrance loss: 0.2&lt;br /&gt;
:::*Exit loss: 0.4&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Modify All Features&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;After the tool processing has finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing to save the edits.&lt;br /&gt;
&amp;lt;li&amp;gt;View the attributes associated within &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; to verify the data processing has been completed correctly. The &#039;losses_Kentry&#039;, &#039;losses_Kexit&#039; and &#039;losses_Kavg&#039; attribute information is now configured.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_08d.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===1D/2D Linking===&lt;br /&gt;
The 1D SWMM / 2D TUFLOW linkage locations to connect the pipe network inlets to the surface have been already automatically defined in the SWMM Inlet Usage Layer, &#039;&#039;&#039;swmm_iu_TS02_001&#039;&#039;&#039;, using the &#039;Conn1D_2D&#039; attribute.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:swmm_iu_TS02_001_attribute_table_Conn1D2D.png]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
To complete the pipe network, 1D/2D linkage is needed at the outlet of the pipe network. The &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_BC_Create_Channel_Endpoint_1D/2D_Connections |BC - Create channel endpoint 1D/2D connections]]&amp;lt;/u&amp;gt;&#039; tool will be used to automate this process.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Use the &#039;Select Features&#039; tool to select the most downstream object in &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Processing Toolbox, go to TUFLOW &amp;gt;&amp;gt; SWMM and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_BC_Create_Channel_Endpoint_1D/2D_Connections |BC - Create channel endpoint 1D/2D connections]]&amp;lt;/u&amp;gt;&#039;. This opens the dialog shown below.&lt;br /&gt;
:*Input Conduits Layer: &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039;&lt;br /&gt;
:*Tick on &#039;Selected features only&#039;&lt;br /&gt;
:*Create connections at: &#039;Downstream end&#039;&lt;br /&gt;
:*Offset Distance: 2&lt;br /&gt;
:*Length of BC lines: 10&lt;br /&gt;
:*Tick on &#039;Set 2D cell elevation to 1D culvert invert at 1D/2D connection cells if needed&#039;.&lt;br /&gt;
:*Output Layer:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
::&amp;lt;li&amp;gt;Click the ... and select &#039;Save to GeoPackage&#039;.&lt;br /&gt;
::&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW\model\gis&#039;&#039;&#039; folder and select &#039;&#039;&#039;TS02_001.gpkg&#039;&#039;&#039;. Click &#039;Save&#039;. &lt;br /&gt;
::&amp;lt;li&amp;gt;A dialog will open. In the layer name box, write &#039;&#039;&#039;2d_bc_SWMM_Pipe_Network_Connections_001_L&#039;&#039;&#039;.&lt;br /&gt;
::&amp;lt;li&amp;gt;Click &#039;OK&#039;.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Run&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool is finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;The &#039;&#039;&#039;2d_bc_SWMM_Pipe_Network_Connections_001_L&#039;&#039;&#039; appears in the QGIS Layers Panel. &lt;br /&gt;
&amp;lt;li&amp;gt;Click the &#039;Apply TUFLOW Styles to Current Layer&#039; symbol from the TUFLOW Plugin toolbar to style the &#039;&#039;&#039;2d_bc_SWMM_Pipe_Network_Connections_001_L&#039;&#039;&#039; layer. &lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_09e.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Update SWMM Junction Details===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Nodes--Junctions&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Processing Toolbox, select the &#039;Edit Features In-Place&#039; tool. This allows the editing of an existing layer, instead of the creation of a new layer.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to TUFLOW &amp;gt;&amp;gt; SWMM in the processing tool list and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Junctions_Set_Attributes |Junctions - Set attributes ]]&amp;lt;/u&amp;gt;&#039; processing tool. This opens the dialog shown below.&lt;br /&gt;
:*Input Inlet Usage Layers: &#039;&#039;&#039;swmm_iu_TS02_001&#039;&#039;&#039;&lt;br /&gt;
:*Input BC Connection Layers: &#039;&#039;&#039;2d_bc_SWMM_Pipe_Network_Connections_001_L&#039;&#039;&#039;&lt;br /&gt;
:*General Options: &lt;br /&gt;
:::*Maximum Depth Option (Ymax): &#039;Set to 0.0&#039;.&lt;br /&gt;
:::*Nodes receiving subcatchment flows option (if connected to 2D): &#039;Based on options selected below&#039;.&lt;br /&gt;
:*Nodes connected to 2D without Inlets:&lt;br /&gt;
:::*None - leave defaults&lt;br /&gt;
:*Nodes connected to 2D with Inlets:&lt;br /&gt;
:::*Maximum depth (Ymax) option: &#039;Use global option&#039;&lt;br /&gt;
:::*Ysur: 0 (ignored because ponding &amp;gt; 0.0)&lt;br /&gt;
:::*Area of Ponding (Apond): 5&lt;br /&gt;
:*Nodes without 2D Connection:&lt;br /&gt;
:::*Surcharge Depth: 50&lt;br /&gt;
:::*Area of Ponding (Apond): 0.0&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Modify All Features&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool has finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing to save the edits.&lt;br /&gt;
&amp;lt;li&amp;gt;View the attributes associated within &#039;&#039;&#039;Nodes--Junctions&#039;&#039;&#039; to verify the data processing has been completed correctly. &amp;lt;br&amp;gt;&lt;br /&gt;
For a summary of the attributes associated with the &#039;&#039;&#039;Nodes--Junctions&#039;&#039;&#039; layer, refer to &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/SWMM-Input-Detailed-1.html#tab:tab-SWMM-Input-Junctions TUFLOW 2023-03-AD Release Notes (Table A.30)]&amp;lt;/u&amp;gt; and the &amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydaulics_P100S9AS.pdf SWMM Reference Manual - Volume 2 (Hydraulics)]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_10d.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==SWMM Options==&lt;br /&gt;
The model we are building will use two SWMM INP files.&lt;br /&gt;
*&#039;&#039;&#039;sw01_001.inp&#039;&#039;&#039; was already created in TUFLOW SWMM Tutorial Module 1. It contained details defining the three culverts under the roads in the model. It also contained the associated 1D SWMM / 2D TUFLOW connection layer objects and the &#039;&#039;&#039;Project--Options&#039;&#039;&#039; necessary to execute the SWMM simulation. &#039;&#039;&#039;sw01_001.inp&#039;&#039;&#039; has been included in the base model we are using for Module 2. No changes will be made to it.&lt;br /&gt;
* We will create a new INP file for the SWMM pipe network inputs (covered in the next section). As SWMM Options are already included in &#039;&#039;&#039;sw01_001.inp&#039;&#039;&#039;, they are not needed in this second (new) INP file. As such, no new SWMM Option commands are necessary for this tutorial.&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; If &#039;&#039;&#039;Project--Options&#039;&#039;&#039; are included in multiple GeoPackage/INP files, the entry that is referenced lowest in the TUFLOW SWMM Control File (TSCF) will be used.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Export SWMM INP File ==&lt;br /&gt;
We will now create a new INP file for the SWMM pipe network inputs. To do this, we need to convert &#039;&#039;&#039;sw02_001.gpkg&#039;&#039;&#039; into a SWMM INP file.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Right click on the &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; layer in the &#039;&#039;&#039;sw02_001&#039;&#039;&#039; group (or any other SWMM layer in the same GeoPackage) and select &#039;TUFLOW&#039; &amp;gt; &#039;SWMM - Export inp file&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;This will open the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_GeoPackage_Write_to_SWMM_inp |GeoPackage - Write to SWMM inp]]&amp;lt;/u&amp;gt;&#039; processing tool, prepopulated with the filename of the layer&#039;s GeoPackage. &amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; This tool can also be activated from the Processing Toolbox. &lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Run&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool is finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;This tool will save the SWMM inp file in the same folder location and with the same name as the GeoPackage input file. In this case, it will save &#039;&#039;&#039;sw02_001.inp&#039;&#039;&#039; to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_SWMM_Inputs_11e.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== TUFLOW Boundary Updates ==&lt;br /&gt;
We will be using TUFLOW&#039;s 2D direct rainfall (also known as rain on grid) functionality for the catchment inflow boundary condition approach to demonstrate flows into the pipe network inlets. There is a wide range of direct rainfall options built into TUFLOW, including:&lt;br /&gt;
*&#039;&#039;&#039;Globally uniform rainfall:&#039;&#039;&#039; This method applies temporally varied rainfall uniformly (spatially) over the entire model. &lt;br /&gt;
*&#039;&#039;&#039;Spatially varying rainfall:&#039;&#039;&#039; This method applies temporally varied rainfall with spatial variation defined using polygon delineation, grid raster files or inbuilt TUFLOW TIN triangulation routines.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The focus of this tutorial is not to demonstrate the available direct rainfall options. As such, we will be using the simplest approach, globally uniform rainfall. It does not require any GIS updates to implement the boundary condition change. Updates will be limited to the Boundary Condition Database reference and Control File syntax updates. Both are addressed in the next section. If you are interested in learning about the available direct rainfall options, please refer to &amp;lt;u&amp;gt;[[Tutorial_M06 |TUFLOW Tutorial Module 6]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Copy &#039;&#039;&#039;rainfall_stations.csv&#039;&#039;&#039; from the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\Tutorial_Data&#039;&#039;&#039; folder to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW\bc_dbase&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;li&amp;gt;Copy &#039;&#039;&#039;bc_dbase_TS02_001.csv&#039;&#039;&#039; from the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\Tutorial_Data&#039;&#039;&#039; folder to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW\bc_dbase&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
It is common to use depth varying manning&#039;s roughness when using direct rainfall. A Materials File using depth varying inputs has been provided. &lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Copy &#039;&#039;&#039;materials_TS02_001.csv&#039;&#039;&#039; from the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\Tutorial_Data&#039;&#039;&#039; folder to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW\model&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_TUFLOW_Boundary_01a.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== TUFLOW Geometry Update  ==&lt;br /&gt;
We will update TUFLOW&#039;s 2D elevation and landuse to represent changes associated with the urban development. The updates will be consolidated within &#039;&#039;&#039;TS02_001.gpkg&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
Copy the following TUFLOW geometry inputs to GeoPackage &#039;&#039;&#039;TS02_001.gpkg&#039;&#039;&#039;:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Right click anywhere in the QGIS Toolbar Panel and tick on &#039;Browser Panel&#039; from the &#039;Panels&#039; options.&lt;br /&gt;
&amp;lt;li&amp;gt;Within the QGIS Browser Panel, there is a dropdown directory, &#039;Project Home&#039;. This directory is a shortcut to the location where the QGIS workspace is saved. In this case, it is a shortcut to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02&#039;&#039;&#039; folder. &lt;br /&gt;
&amp;lt;li&amp;gt;In the &#039;Project Home&#039; directory, navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\Tutorial_Data&#039;&#039;&#039; folder. &lt;br /&gt;
&amp;lt;li&amp;gt;Drag the following layers (hold Ctrl to select multiple) from the &#039;&#039;&#039;Urban_Development.gpkg&#039;&#039;&#039; and drop them into the &#039;&#039;&#039;TS02_001.gpkg&#039;&#039;&#039; contained within the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW\model\gis&#039;&#039;&#039; folder:&lt;br /&gt;
:*&#039;&#039;&#039;2d_mat_TS02_Dev_Buildings_001_R&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;2d_mat_TS02_Dev_Lots_001_R&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;2d_ztin_TS02_Dev_001_L&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;2d_ztin_TS02_Dev_001_P&#039;&#039;&#039;&lt;br /&gt;
:*&#039;&#039;&#039;2d_ztin_TS02_Dev_001_R&#039;&#039;&#039;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; The focus of this tutorial is not to demonstrate 2D geometry updates. If you are interested in learning about the above &#039;&#039;&#039;2d_ztin&#039;&#039;&#039; and &#039;&#039;&#039;2d_mat&#039;&#039;&#039; changes, please refer to &amp;lt;u&amp;gt;[[Tutorial_M02 |TUFLOW Tutorial Module 2]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_TUFLOW_Geometry_01f.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Simulation Control Files =&lt;br /&gt;
To avoid the potential risk of overwriting existing control files accidentally, we will start by saving new control files where we will be making subsequent syntax updates during the following steps.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open &#039;&#039;&#039;TS01_5m_001.tcf&#039;&#039;&#039; in a Text Editor (Notepad++ is used here). Save the file as &#039;&#039;&#039;TS02_5m_001.tcf&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW\runs&#039;&#039;&#039; folder. &lt;br /&gt;
&amp;lt;li&amp;gt;Using the &#039;Open File&#039; function in Notepad++: &lt;br /&gt;
:*Open &#039;&#039;&#039;M02_001.tgc,&#039;&#039;&#039;  and save the file as &#039;&#039;&#039;TS02_001.tgc&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW\model&#039;&#039;&#039; folder.&lt;br /&gt;
:*Open &#039;&#039;&#039;TS01_001.tbc,&#039;&#039;&#039;  and save the file as &#039;&#039;&#039;TS02_001.tbc&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW\model&#039;&#039;&#039; folder.&lt;br /&gt;
:*Open &#039;&#039;&#039;TS01_001.tscf,&#039;&#039;&#039;  and save the file as &#039;&#039;&#039;TS02_001.tscf&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW\model&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===TUFLOW Control File (TCF)===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open &#039;&#039;&#039;TS02_001.tcf&#039;&#039;&#039; and make the following reference updates:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Spatial Database &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\model\gis\TS02_001.gpkg&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Specify the location of the GeoPackage Spatial Database&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Geometry Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\model\TS02_001.tgc&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the TUFLOW Geometry Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;BC Control File &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\model\TS02_001.tbc&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the TUFLOW Boundary Condition Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;BC Database &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\bc_dbase\bc_dbase_TS02_001.csv&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the Boundary Condition Database&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read Materials File &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\model\materials_TS02_001.csv&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the Materials Definition File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;SWMM Control File &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; ..\model\TS02_001.tscf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the SWMM (1D) Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following line in the &#039;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Output Settings&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&#039; section: &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Map Cutoff Depth &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; 0.05 &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! Sets map cutoff depth of 0.05 meters&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Save the TCF.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_Sim_Control_01d.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== TUFLOW Geometry Control File (TGC) ===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open &#039;&#039;&#039;TS02_001.tgc&#039;&#039;&#039;. If using Notepad++, right click the file reference in &#039;&#039;&#039;TS02_5m_001.tcf&#039;&#039;&#039; and select &#039;Open File&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following command to the the &#039;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Topography&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&#039; section below the below the existing &#039;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read GIS Z Shape&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&#039; command:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Create TIN Zpts &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;2d_ztin_TS02_Dev_001_R | 2d_ztin_TS02_Dev_001_L | 2d_ztin_TS02_Dev_001_P&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Urban Development Topography TIN&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following lines in the &#039;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Materials&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&#039; section, below the existing material commands : &amp;lt;br&amp;gt; &lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read GIS Mat &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;2d_mat_TS02_Dev_Lots_001_R&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;    ! Urban Development Landuse 1&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read GIS Mat &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;2d_mat_TS02_Dev_Buildings_001_R&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; ! Urban Development Landuse 2&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save the TGC.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_Sim_Control_02b.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== TUFLOW Boundary Control File (TBC) ===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open &#039;&#039;&#039;TS02_001.tbc&#039;&#039;&#039;. If using Notepad++, right click the file reference in &#039;&#039;&#039;TS02_5m_001.tcf&#039;&#039;&#039; and select &#039;Open File&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; Comment out the &#039;Read GIS SA&#039; command by placing &#039;!&#039; before the command: &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! Read GIS SA == 2d_sa_M01_001_R&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following additional command lines:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Global Rainfall BC &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;RF_FC04&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reads in global rainfall&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read GIS BC &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;2d_bc_SWMM_Pipe_Network_Connections_001_L&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Links the 1D Pipe Network Outlets to the 2D domain&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save the TBC.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_Sim_Control_03d.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== TUFLOW SWMM Control File (TSCF) ===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open &#039;&#039;&#039;TS02_001.tscf&#039;&#039;&#039;. If using Notepad++, right click the file reference in &#039;&#039;&#039;TS02_5m_001.tcf&#039;&#039;&#039; and select &#039;Open File&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following command lines after &#039;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read SWMM &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;swmm\sw01_001.inp&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&#039;:   &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read SWMM &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;swmm\sw02_001.inp&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! 1D SWMM Pipe Network Input File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read GIS SWMM Inlet Usage &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;swmm\swmm_iu_TS02_001.gpkg &amp;gt;&amp;gt; swmm_iu_TS02_001&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! 1D SWMM Pipe Network Inlet Usage Layer&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save the TSCF.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_Sim_Control_04b.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Running the Simulation =&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save a copy of &#039;&#039;&#039;_run_TS01_HPC.bat&#039;&#039;&#039; as &#039;&#039;&#039;_run_TS02_HPC.bat&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_02\TUFLOW\runs&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;li&amp;gt;Update the batch file to reference the &#039;&#039;&#039;TS02_5m_001.tcf&#039;&#039;&#039; :&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&#039;&#039;&#039;set&#039;&#039;&#039;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;exe&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&amp;quot;..\..\..\exe\2025.2.1\TUFLOW_iSP_w64.exe&amp;quot;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&#039;&#039;&#039;set&#039;&#039;&#039;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;run&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;start &amp;quot;TUFLOW&amp;quot; /wait&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; %exe%&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -b&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;TS02_5m_001.tcf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Save the batch file and double click it in Windows File Explorer to run the simulation. &lt;br /&gt;
&amp;lt;li&amp;gt;Did your TUFLOW SWMM model fail to run successfully? If so, here is a link to a troubleshooting guide: &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Troubleshooting | TUFLOW SWMM Troubleshooting]]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS2_Run_Sim_01c.mp4|width=1236}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Check Files and Results Output=&lt;br /&gt;
Complete the steps outlined in following links to review check files and simulation results from the TUFLOW SWMM model simulation:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02_Check_QGIS | TUFLOW SWMM Tutorial 02 Check Files]]&amp;lt;/u&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02_Results_QGIS | TUFLOW SWMM Tutorial 02 Results]]&amp;lt;/u&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Conclusion =&lt;br /&gt;
* 1D EPA SWMM pipe network features and 2D direct rainfall (rain on grid) hydrology have been added to the tutorial model.&lt;br /&gt;
* Check files were used to review the 1D SWMM pipe network model features.&lt;br /&gt;
* Simulation results in the 1D SWMM pipe network were viewed in time series and long section plot format.&lt;br /&gt;
* For further training opportunities see &amp;lt;u&amp;gt;[https://tuflow.com/training/training-course-catalogue/ TUFLOW Training Catalogue]&amp;lt;/u&amp;gt; and/or contact &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Other TUFLOW SWMM Tutorials=&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01 | TUFLOW SWMM Module 1]]&amp;lt;/u&amp;gt;  - 1D SWMM Culverts&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02 | TUFLOW SWMM Module 2]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 2D TUFLOW Direct Rainfall Hydrology&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M03 | TUFLOW SWMM Module 3]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M04 | TUFLOW SWMM Module 4]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology: Executing multiple different event simulations from a single model control file.&lt;br /&gt;
*&amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM | XPSWMM to TUFLOW SWMM]]&amp;lt;/u&amp;gt;  - How to convert an XPSWMM model to TUFLOW SWMM.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[TUFLOW_SWMM_Tutorial_Introduction#Tutorial_Modules| Back to TUFLOW SWMM Tutorial Introduction Main Page]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_M01&amp;diff=45213</id>
		<title>TUFLOW SWMM Tutorial M01</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=TUFLOW_SWMM_Tutorial_M01&amp;diff=45213"/>
		<updated>2025-11-25T01:24:49Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Running the Simulation */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Introduction =&lt;br /&gt;
In this module, three culverts are added to represent flow through three separate road embankments. EPA SWMM is used as the solution scheme for the 1D culvert flow calculations, dynamically linked with the TUFLOW HPC 2D solution scheme. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
TUFLOW SWMM Tutorial Module 1 builds from the model created in &amp;lt;u&amp;gt;[[Tutorial_M02 |TUFLOW Tutorial Module 2]]&amp;lt;/u&amp;gt; (in the TUFLOW Only tutorial dataset). The completed TUFLOW Module 2 model is provided in the &#039;&#039;&#039;&#039;&#039;TUFLOW_SWMM_Module_01\TUFLOW&#039;&#039;&#039;&#039;&#039; folder of the download dataset as the starting point for this tutorial. If you are not already familiar with TUFLOW, we recommend first completing Module 1 and 2 of the &amp;lt;u&amp;gt;[[Tutorial_Introduction | &amp;quot;TUFLOW Only&amp;quot; Tutorials]]&amp;lt;/u&amp;gt; to establish an understanding of 2D modeling, before progressing to learning how to link 1D EPA SWMM to 2D TUFLOW. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Project Initialization =&lt;br /&gt;
Three steps are required for the project initialization:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Setting the  QGIS Project Coordinate Reference System (CRS).&lt;br /&gt;
&amp;lt;li&amp;gt; Configuring the QGIS TUFLOW Plugin.&lt;br /&gt;
&amp;lt;li&amp;gt; Establishing the new TUFLOW model GeoPackage file that will include new GIS inputs associated with this model update.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== QGIS ==&lt;br /&gt;
QGIS Version 3.34 or newer, and QGIS TUFLOW Plugin 3.11 or newer are required to access the SWMM Processing Tools described in the following sections. For installation, see &amp;lt;u&amp;gt;[https://wiki.tuflow.com/TUFLOW_QGIS_Plugin Installation of TUFLOW Plugin]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
Firstly, define the Coordinate Reference System (CRS), also called ‘Projection’, for the QGIS workspace:&lt;br /&gt;
&amp;lt;ol&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Open QGIS.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to Project &amp;gt; Properties… &lt;br /&gt;
&amp;lt;li&amp;gt;In the CRS tab, type ‘WGS 84 / UTM Zone 60S’.&lt;br /&gt;
&amp;lt;li&amp;gt;Select the matching projection in the &#039;Predefined Coordinate Reference Systems&#039; section.&lt;br /&gt;
&amp;lt;li&amp;gt;Click ‘Apply’ and ‘OK’.&lt;br /&gt;
&amp;lt;li&amp;gt;Ensure that the projection is set correctly by viewing the bottom right hand corner of the workspace. It should read ‘EPSG:32760’.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Initialization_01a.mp4|width=1235}}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==TUFLOW Model==&lt;br /&gt;
===Load and Style TUFLOW Model Files===&lt;br /&gt;
Load and Style the GIS layers from the TUFLOW model:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Click on the ‘Load TUFLOW Layers from TCF’ symbol from the TUFLOW Plugin toolbar.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File: Tuflow_plugin_load_tcf_layers.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\TUFLOW\runs&#039;&#039;&#039; folder and select &#039;&#039;&#039;M02_5m_001.tcf&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Load Layers window, select:&lt;br /&gt;
* Ordering Options: Alphabetical&lt;br /&gt;
* Grouping Options: Group by control file&lt;br /&gt;
* Raster Load Options: Load Normally &lt;br /&gt;
&amp;lt;li&amp;gt;Click ‘Open’ and ‘OK’.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Style the TUFLOW layers however you desire. Common steps to do this are:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Click on the ‘Apply TUFLOW Styles to Open Layers’ symbol from the TUFLOW Plugin toolbar.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:tuflow_plugin_styles_open_layers.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Change the symbology of the DEM:&lt;br /&gt;
*Right click on the &#039;&#039;&#039;DEM&#039;&#039;&#039; file in the QGIS Layers Panel and select &#039;Properties&#039;.&lt;br /&gt;
*From the Symbology tab, under &#039;Band Rendering&#039; select the following options:&lt;br /&gt;
:*Render type: Singleband pseudocolor&lt;br /&gt;
:*Color ramp: Spectral&lt;br /&gt;
:*Color ramp: Invert Color Ramp&lt;br /&gt;
:*Mode: Equal Interval&lt;br /&gt;
*From the Transparency tab, set the Global Opacity to 75%.&lt;br /&gt;
*Click &#039;Apply&#039; and &#039;OK&#039;.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Initialization_03d.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Create a hillshade of the DEM:&lt;br /&gt;
*Right click on the &#039;&#039;&#039;DEM&#039;&#039;&#039; file in the QGIS Layers Panel and select &#039;Duplicate Layer&#039;.&lt;br /&gt;
*Right click on the &#039;&#039;&#039;DEM_copy&#039;&#039;&#039; and select &#039;Rename Layer&#039;. Rename the layer to &#039;&#039;&#039;DEM_Hillshade&#039;&#039;&#039;.&lt;br /&gt;
*Right click on the &#039;&#039;&#039;DEM_Hillshade&#039;&#039;&#039; and select &#039;Properties&#039;.&lt;br /&gt;
*From the Symbology tab, under &#039;Band Rendering&#039; select the following options:&lt;br /&gt;
:*Render type: Hillshade&lt;br /&gt;
:*Z Factor: 3&lt;br /&gt;
*Click &#039;Apply&#039; and &#039;OK&#039;.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Initialization_04b.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===TUFLOW Plugin===&lt;br /&gt;
Next we need to configure the QGIS TUFLOW Plugin settings to link with the project folder where we will build our model:&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open the &#039;Configure TUFLOW Project&#039; tool by selecting Plugins &amp;gt; TUFLOW &amp;gt; Editing &amp;gt; Configure / Create TUFLOW Project.&lt;br /&gt;
&amp;lt;li&amp;gt;Set the CRS (Coordinate Reference System) by selecting one of the vector layers associated with the opened model using the drop menu list. For example, &#039;&#039;2d_bc_M01_001_L&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;To set the location of the TUFLOW folder, click &#039;Browse...&#039; and navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_01&#039;&#039;&#039; folder. Click &#039;Select Folder&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt;To set the location of the TUFLOW single precision executable file, click &#039;Browse...&#039; and navigate to the &#039;&#039;&#039;exe\2023-03-AF&#039;&#039;&#039; folder. Select &#039;&#039;&#039;TUFLOW_iSP_w64.exe&#039;&#039;&#039; and click &#039;Open&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;GPKG&#039; as the GIS Format. &lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;TUFLOW Classic / HPC&#039; as the TUFLOW Engine.&lt;br /&gt;
&amp;lt;li&amp;gt;Tick on &#039;Save Default Settings Globally&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;OK&#039;.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File: TS1_Configure_Project_01a.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Increment Model GeoPackage File === &lt;br /&gt;
We will now save a copy of &#039;&#039;&#039;M02_001.gpkg&#039;&#039;&#039; with a new name, &#039;&#039;&#039;TS01_001.gpkg&#039;&#039;&#039;. This project initialization step is recommended so prior model versions from a project are not broken as a result of changes being made to GIS inputs.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;2d_bc_M01_001_L&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click on the &#039;Increment Selected Layer&#039; symbol from the TUFLOW Plugin toolbar. This opens the dialog shown below. &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:tuflow_plugin_increment_layer.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
:*Source Layer: Automatically set to the selected layer, &#039;&#039;&#039;2d_bc_M01_001_L&#039;&#039;&#039;.&lt;br /&gt;
:*Output Database: Click &#039;Browse...&#039;. This will automatically open to the &#039;&#039;&#039;TUFLOW\model\gis&#039;&#039;&#039; folder. Set the new output database name to &#039;&#039;&#039;TS01_001.gpkg&#039;&#039;&#039; and click &#039;Save&#039;.&lt;br /&gt;
:*Output Layer Name: This will automatically increment to &#039;&#039;&#039;2d_bc_M01_00&#039;&#039;2&#039;&#039;_L&#039;&#039;&#039;. Change the name back to &#039;&#039;&#039;2d_bc_M01_00&#039;&#039;1&#039;&#039;_L&#039;&#039;&#039;.&lt;br /&gt;
:*Delete the pre-filled &#039;Incremented Layer&#039; entry in the table. We do not wish to modify the version number associated with the 2d_bc file. This current exercise will not change the version number of any of the GIS layer inputs, it is simply establishing a copy of the existing GeoPackage where future edits will be saved to.&lt;br /&gt;
:*Select &#039;Remove Source Layer from Workspace&#039;.&lt;br /&gt;
:*Select &#039;Increment Layer and Preserve Database&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;OK&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;The GeoPackage database, &#039;&#039;&#039;TS01_001.gpkg&#039;&#039;&#039; will now be in the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\TUFLOW\model\gis&#039;&#039;&#039; folder. &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Initialization_05c.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Save QGIS Project Workspace===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Go to Project &amp;gt; Save As.&lt;br /&gt;
&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_01&#039;&#039;&#039; folder and type &#039;&#039;&#039;SWMM_M01&#039;&#039;&#039; as the filename with the extension .qgz.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= GIS Inputs =&lt;br /&gt;
==Create SWMM GeoPackage Spatial Database== &lt;br /&gt;
Create a new folder in the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\TUFLOW\model&#039;&#039;&#039; folder called &#039;&#039;&#039;swmm&#039;&#039;&#039;. This is the location where all SWMM inputs will be saved.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
In QGIS, create the SWMM GeoPackage Database:&lt;br /&gt;
&amp;lt;ol&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Go to Processing &amp;gt; Toolbox from the top dropdown menu options to open the Processing Toolbox.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to TUFLOW &amp;gt;&amp;gt; SWMM in the processing tool list and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_GeoPackage_Create |GeoPackage - Create]]&amp;lt;/u&amp;gt;&#039;. This opens the dialog shown below.&lt;br /&gt;
:*To set the ‘CRS for GeoPackage’: Click the drop down menu and select ‘Project CRS: EPSG:32760 - WGS 84 / UTM zone 60S’.&lt;br /&gt;
:*To set the ‘Initial SWMM Sections’: Click …, and tick on (if not already ticked): &lt;br /&gt;
::*&#039;&#039;&#039;Project--Title&#039;&#039;&#039;, &#039;&#039;&#039;Project--Options&#039;&#039;&#039;, &#039;&#039;&#039;Project --Report.&#039;&#039;&#039;&lt;br /&gt;
::*&#039;&#039;&#039;Nodes--Junctions&#039;&#039;&#039;, &#039;&#039;&#039;Nodes--Outfalls.&#039;&#039;&#039;, &#039;&#039;&#039;Nodes--Storage.&#039;&#039;&#039; &lt;br /&gt;
::*&#039;&#039;&#039;Links--Conduits, Links--Streets&#039;&#039;&#039;. &lt;br /&gt;
:*To define the ‘GPKG filename to create’: Click …, select ‘Save to File’. Navigate to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder and save the GeoPackage database as &#039;&#039;&#039;sw01_001.gpkg&#039;&#039;&#039;.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Click ‘Run’. &lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool has finished, click ‘Close’.&lt;br /&gt;
&amp;lt;li&amp;gt;In Windows File Explorer, navigate to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder and drag and drop &#039;&#039;&#039;sw01_001.gpkg&#039;&#039;&#039; into QGIS. &lt;br /&gt;
&amp;lt;li&amp;gt;When prompted by QGIS, under &#039;Options&#039;, tick on &#039;Add layers to group&#039;, then select &#039;Add Layers&#039; to open all vectors within &#039;&#039;&#039;sw01_001.gpkg&#039;&#039;&#039;. By default, all items in the available list should have been selected. &lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, move &#039;&#039;&#039;sw01_001.gpkg&#039;&#039;&#039; to the top of the list. This will ensure the data within this database file is displayed above all other layers in the project. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_01g.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== GIS Data Entry ==&lt;br /&gt;
&lt;br /&gt;
A GeoPackage database called &#039;&#039;&#039;SWMM_Culverts.gpkg&#039;&#039;&#039; is provided in the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\Tutorial_Data&#039;&#039;&#039; folder. It contains three layers: &lt;br /&gt;
:*&#039;&#039;&#039;Conduits:&#039;&#039;&#039; defines the culvert location, type and geometry.&lt;br /&gt;
:*&#039;&#039;&#039;Outfalls:&#039;&#039;&#039; defines the downstream culvert inverts.&lt;br /&gt;
:*&#039;&#039;&#039;Storage_nodes:&#039;&#039;&#039; defines the upstream culvert inverts.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
To populate the GeoPackage database created in the previous section:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In Windows File Explorer, navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\Tutorial_Data&#039;&#039;&#039; folder. Drag and drop the &#039;&#039;&#039;SWMM_Culverts.gpkg&#039;&#039;&#039; into QGIS. &lt;br /&gt;
&amp;lt;li&amp;gt;When prompted by QGIS, under &#039;Options&#039;, tick on &#039;Add layers to group&#039;. By default, all items in the GeoPackage database will be selected. Click &#039;Add Layers&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, right click on the &#039;&#039;&#039;SWMM_Culverts &amp;gt;&amp;gt; Conduits&#039;&#039;&#039; layer and select &#039;Zoom to Layer(s)&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Use the &#039;Select Features&#039; tool to highlight all items included in &#039;&#039;&#039;Conduits&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Edit&#039; from the top QGIS tab and &#039;Copy Features&#039; from the drop down menu. &lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) the &#039;&#039;&#039;sw01_001.gpkg &amp;gt;&amp;gt; Links--Conduits&#039;&#039;&#039; layer. &lt;br /&gt;
&amp;lt;li&amp;gt;Make the &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; layer editable by clicking the &#039;Toggle Editing&#039; symbol [[File:toggle_editing_icon.png|27x27px]].&lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Edit&#039; from the top QGIS tab and click &#039;Paste Features&#039; from the drop down menu.&lt;br /&gt;
&amp;lt;li&amp;gt;Toggle the editing off to save the edits.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_02f.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Similarly, copy the objects from &#039;&#039;&#039;Storage_nodes&#039;&#039;&#039; into &#039;&#039;&#039;Nodes--Storage&#039;&#039;&#039;. Junctions and storage nodes are allowed at the upstream end of culverts. Storage nodes are preferred for culverts receiving 2D flows not through a storm drain inlet.&lt;br /&gt;
&amp;lt;li&amp;gt;Also copy the objects from &#039;&#039;&#039;Outfalls&#039;&#039;&#039; into &#039;&#039;&#039;Nodes--Outfalls&#039;&#039;&#039;. Outfalls are treated as outlets, and are required at the downstream end of culverts.&lt;br /&gt;
&amp;lt;li&amp;gt; Toggle off editing and save the edits.&lt;br /&gt;
&amp;lt;li&amp;gt;Remove &#039;&#039;&#039;SWMM_Culverts.gpkg&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_03f.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Inspect the attribute information within the respective layers to familiarize yourself with the data.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_04f.mp4|width=1236}}&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== GIS Data Updates ==&lt;br /&gt;
The provided GIS data requires numerous updates before proceeding to a model simulation. We have intentionally built these updates into this tutorial to demonstrate some of the available TUFLOW SWMM model build processing tools. The following updates are being made to objects and layers within &#039;&#039;&#039;sw01_001.gpkg&#039;&#039;&#039;.&lt;br /&gt;
===Update Conduit Details===&lt;br /&gt;
==== Node Details ====&lt;br /&gt;
Stage 1 of building the 1D SWMM network involves updating the &#039;From Node&#039; and &#039;To Node&#039; attribute information in &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039;. This information defines the Link/Node connections. &amp;lt;br&amp;gt;&lt;br /&gt;
The information we will be adding to &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; is extracted from &#039;&#039;&#039;Nodes--Storage&#039;&#039;&#039; and &#039;&#039;&#039;Nodes--Outfalls&#039;&#039;&#039; automatically using the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Node_Fields |Conduits - Assign node fields]]&amp;lt;/u&amp;gt;&#039; tool from the Processing Toolbox.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Processing Toolbox, select the &#039;Edit Features In-Place&#039; tool [[File:edit_features_in_place_icon.png]]. This allows the editing of an existing layer, instead of the creation of a new layer.&lt;br /&gt;
&amp;lt;li&amp;gt;Go to TUFLOW &amp;gt;&amp;gt; SWMM in the processing tool list and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Node_Fields |Conduits - Assign node fields]]&amp;lt;/u&amp;gt;&#039;. This opens the dialog shown below.  &lt;br /&gt;
:*SWMM Node Layers: Tick on &#039;&#039;&#039;sw01_001 &amp;gt;&amp;gt; Nodes--Storage&#039;&#039;&#039; and &#039;&#039;&#039;sw01_001 &amp;gt;&amp;gt; Nodes--Outfalls&#039;&#039;&#039;. Click &#039;OK&#039;. &lt;br /&gt;
&amp;lt;li&amp;gt;Select &#039;Modify All Features&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool has finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing to save the edits.&lt;br /&gt;
&amp;lt;li&amp;gt;View the attributes associated within &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; to verify the data processing has been completed correctly. The &#039;From Node&#039; and &#039;To Node&#039; attribute information is now configured correctly. For a broader understanding of the other attributes associated with the &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; layer, refer to &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/release/2023-03-AD/SWMM-Input-Detailed-1.html#tab:tab-SWMM-Input-Conduits TUFLOW 2023-03-AD Release Notes (Table A.19)]&amp;lt;/u&amp;gt; and the &amp;lt;u&amp;gt;[https://downloads.tuflow.com/SWMM/SWMM5_Reference_Manual_Volume2_Hydaulics_P100S9AS.pdf SWMM Reference Manual - Volume 2 (Hydraulics)]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tip 1:&#039;&#039;&#039; If you wish to only update a selection of objects, instead of selecting the entire &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; dataset, select the target objects first using the &#039;Select Features&#039; tool. The &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Node_Fields |Conduits - Assign node fields]]&amp;lt;/u&amp;gt;&#039; tool will provide an option to &#039;Modify Selected Features&#039;, instead of &#039;Modify All Features.&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Tip 2:&#039;&#039;&#039; Unique Node ID&#039;s are required for the SWMM network to function error free. If you are following this workflow for a project model build, please ensure the &#039;&#039;&#039;Nodes--Storage&#039;&#039;&#039; and &#039;&#039;&#039;Nodes--Outfalls&#039;&#039;&#039; object ID information is unique. If duplicate ID values are assigned to multiple objects, consider using the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Integrity_Make_Object_Names_Unique |Integrity - Make object names unique ]]&amp;lt;/u&amp;gt;&#039; TUFLOW SWMM processing tool to ensure all ID values are unique before using &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Node_Fields |Conduits - Assign node fields]]&amp;lt;/u&amp;gt;&#039;.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_05g.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
====Update Losses====&lt;br /&gt;
Stage 2 involves updating the loss attributes in the &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; layer. In this example, default loss values are used and will be entered manually. These loss values can be adjusted in your project models to reflect site specific information if desired. &lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt;Right click &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; and select &#039;Open Attribute Table&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;For each conduit, update the following fields:&lt;br /&gt;
:*losses_Kentry: 0.5&lt;br /&gt;
:*losses_Kexit: 1.0&lt;br /&gt;
:*losses_Kavg: 0.0&lt;br /&gt;
The video below demonstrates how to do this one entry at a time, or via the bulk attribute update options in QGIS.&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing to save the edits.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_06f.mp4|width=1236}}&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Since all the 1D SWMM inputs in this model are embankment culverts that all use the same loss parameters, it&#039;s not necessary to specify different loss attributes. The &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02 | TUFLOW SWMM Module 2]]&amp;lt;/u&amp;gt; will demonstrate an urban pipe network added to the model, with different loss attributes required for the road culverts and underground storm pipe network links. To simplify this step, Module 2 uses the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_Conduits_Assign_Node_Fields |Conduits - Assign node fields]]&amp;lt;/u&amp;gt;&#039; processing tool. &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Create 1D/2D Connections===&lt;br /&gt;
The following instructions introduce a new tool that automates the creation of 1D/2D connections. Due to the limitations of SWMM boundary conditions, HX lines are required for the upstream end of the culvert (rather than SX), and SX connections are used at the downstream end of the culvert.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;In the Processing Toolbox, go to TUFLOW &amp;gt;&amp;gt; SWMM and select &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_BC_Create_Channel_Endpoint_1D/2D_Connections |BC - Create channel endpoint 1D/2D connections]]&amp;lt;/u&amp;gt;&#039;. This opens the dialog shown below.  &amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; Ensure the &#039;Edit Features In-Place&#039; tool has been turned off. &lt;br /&gt;
:*Input Conduits Layer: &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039;&lt;br /&gt;
:*Create connections at: &#039;Both ends&#039;. &lt;br /&gt;
:*Offset Distance: 2&lt;br /&gt;
:*Length of BC lines: 10&lt;br /&gt;
:*Tick on &#039;Set 2D cell elevation to 1D culvert invert at 1D/2D connection cells if needed&#039;.&lt;br /&gt;
:*Output Layer:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
::&amp;lt;li&amp;gt;Click the ... and select &#039;Save to GeoPackage&#039;.&lt;br /&gt;
::&amp;lt;li&amp;gt;Navigate to the &#039;&#039;&#039;TUFLOW\model\gis&#039;&#039;&#039; folder and select &#039;&#039;&#039;TS01_001.gpkg&#039;&#039;&#039;. Click Save. &lt;br /&gt;
::&amp;lt;li&amp;gt;A dialog will open. In the Layer name field, write &#039;&#039;&#039;2d_bc_SWMM_Culvert_Connections_001_L&#039;&#039;&#039;.&lt;br /&gt;
::&amp;lt;li&amp;gt;Click &#039;OK&#039;.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Run&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool is finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;The &#039;&#039;&#039;2d_bc_SWMM_Culvert_Connections_001_L&#039;&#039;&#039; appears in the QGIS Layers Panel. Select &#039;Apply TUFLOW Styles to Current Layer&#039;.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_07f.mp4|width=1236}}&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; The positions of the HX and SX connections may not be in the optimum location or extent using the generalized automated tool. As such, it is recommended to check the output from this processing step. In this module, the 1D/2D connections associated with &#039;&#039;&#039;2d_bc_SWMM_Culvert_Connections_001_L&#039;&#039;&#039; are checked in &amp;lt;u&amp;gt;[[TUFLOW SWMM Tutorial M01 Check QGIS|TUFLOW SWMM Tutorial 01 Check Files]]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===Update Storage Node Details===&lt;br /&gt;
The attributes of the storage nodes need to be modified to represent the storage of the connected HX cells since these cells do not represent storage themselves. The area associated with the storage nodes should be similar to the areas of the HX cells. To set the area, we will use a &amp;quot;PYRAMIDAL&amp;quot; shape with the SWMM side slope (run/rise) (Z) set to 0 to represent vertical walls. As the cell size is 5m, and the length of each polyline is 10m, the length (L) will be set to 10m and the width (W) to 5m. These sizes will be modified later when we change the boundary conditions.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Nodes--Storage&#039;&#039;&#039; and toggle on editing.&lt;br /&gt;
&amp;lt;li&amp;gt; Right click &#039;&#039;&#039;Nodes--Storage&#039;&#039;&#039; and select &#039;Open Attribute Table&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt; Set the following attributes:&lt;br /&gt;
:* YMax: 50.0 (this is a value greater than the expected water level. It is required to allow water to fill node)&lt;br /&gt;
:* TYPE: &#039;PYRAMIDAL&#039;&lt;br /&gt;
:* L: 10&lt;br /&gt;
:* W: 5&lt;br /&gt;
:* Z: 0.0&lt;br /&gt;
&amp;lt;li&amp;gt; Turn off editing to save the edits.&lt;br /&gt;
 &lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_08g.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==SWMM Options==&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, select (left click) &#039;&#039;&#039;Project--Options&#039;&#039;&#039; and toggle on editing. &lt;br /&gt;
&amp;lt;li&amp;gt;Right click &#039;&#039;&#039;Project--Options&#039;&#039;&#039; and select &#039;Open Attribute Table&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Update the following options: &lt;br /&gt;
*&#039;&#039;&#039;START_DATE&#039;&#039;&#039;: 2020-01-01 (Date Format: YYYY-MM-DD)&lt;br /&gt;
*&#039;&#039;&#039;REPORT_STEP&#039;&#039;&#039;: 00:01:00&lt;br /&gt;
&amp;lt;li&amp;gt;Turn off editing to save the edits.  &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_09f.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;Save the QGIS Project Workspace:&lt;br /&gt;
&lt;br /&gt;
# Go to Project &amp;gt; Save. This will update &#039;&#039;&#039;SWMM_M01.qgz&#039;&#039;&#039;, which was created previously in the folder &#039;&#039;&#039;TUFLOW_SWMM_Module_01&#039;&#039;&#039;.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Export SWMM INP File ==&lt;br /&gt;
SWMM is not able to read the &#039;&#039;&#039;sw01_001.gpkg&#039;&#039;&#039; database directly, therefore, we need to convert the GeoPackage file to a SWMM INP file format.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the QGIS Layers Panel, right click &#039;&#039;&#039;Links--Conduits&#039;&#039;&#039; (or any of the SWMM layers) and select &#039;TUFLOW&#039; &amp;gt; &#039;SWMM - Export inp file&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;This will open the &#039;&amp;lt;u&amp;gt;[[QGIS_SWMM_GeoPackage_Write_to_SWMM_inp |GeoPackage - Write to SWMM inp]]&amp;lt;/u&amp;gt;&#039; processing tool, prepopulated with the filename of the layer&#039;s GeoPackage. &amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Note:&#039;&#039;&#039; This tool can also be activated from the Processing Toolbox. &lt;br /&gt;
&amp;lt;li&amp;gt;Click &#039;Run&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;Once the tool is finished, click &#039;Close&#039;.&lt;br /&gt;
&amp;lt;li&amp;gt;This tool will save the SWMM inp file in the same folder location and with the same name as the GeoPackage input file. In this case, it will save &#039;&#039;&#039;sw01_001.inp&#039;&#039;&#039; to the &#039;&#039;&#039;TUFLOW\model\swmm&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_SWMM_Inputs_10e.mp4|width=1236}}&lt;br /&gt;
&amp;lt;/ol&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Simulation Control Files =&lt;br /&gt;
The following steps will require use of a text editor. The tutorial demonstration uses Notepad++. For its configuration information refer to &amp;lt;u&amp;gt;[[NotepadPlusPlus_Tips | Notepad++ Tips]]&amp;lt;/u&amp;gt;. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To differentiate the TUFLOW SWMM tutorials from the TUFLOW/ESTRY tutorials, &#039;TS&#039; is used as the file prefix in this series of tutorials. To avoid the potential risk of overwriting existing control files accidentally, we will start by saving new control files where we will be making subsequent syntax updates during the following steps. &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Set up the simulation control files:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In Windows File Explorer, navigate to the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\TUFLOW\runs&#039;&#039;&#039; folder and open &#039;&#039;&#039;M02_5m_001.tcf&#039;&#039;&#039; in a Text Editor (Notepad++ is recommended). &lt;br /&gt;
&amp;lt;li&amp;gt;Save the file as &#039;&#039;&#039;TS01_5m_001.tcf&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\TUFLOW\runs&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;li&amp;gt;Open &#039;&#039;&#039;M01_001.tbc&#039;&#039;&#039; using the &#039;Open File&#039; function in Notepad++. Save the file as &#039;&#039;&#039;TS01_001.tbc&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\TUFLOW\model&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;li&amp;gt;Create a new blank text file called &#039;&#039;&#039;TS01_001.tscf&#039;&#039;&#039; and save it in the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\TUFLOW\model&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Sim_Control_00a.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== TUFLOW Control File (TCF) ===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Open &#039;&#039;&#039;TS01_5m_001.tcf&#039;&#039;&#039; in a Text Editor (Notepad++ is recommended) and make the following reference updates:  &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Spatial Database &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; ..\model\gis\TS01_001.gpkg &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; ! Specify the location of the GeoPackage Spatial Database&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;BC Control File &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;..\model\TS01_001.tbc&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the TUFLOW Boundary Conditions Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Add the following line in the &#039;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Model Inputs&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&#039; section:  &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;SWMM Control File &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; ..\model\TS01_001.tscf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! Reference the SWMM (1D) Control File&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Add the following line in the &#039;&amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Output Settings&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&#039; section: &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;NetCDF Output Start Date &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;2020-01-01 00:00 &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;! Sets the output units for the NetCDF time variable&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Save the TCF.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Sim_Control_01c.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== TUFLOW Boundary Control File (TBC) ===&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;From &#039;&#039;&#039;TS01_001.tcf&#039;&#039;&#039;, right click &#039;&#039;&#039;TS01_001.tbc&#039;&#039;&#039; and select &#039;Open File&#039;. This opens &#039;&#039;&#039;TS01_001.tbc&#039;&#039;&#039; into a new tab in Notepad ++.&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following command line after &#039;&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read GIS SA &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;2d_sa_M01_001_R&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&#039;:  &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read GIS BC &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;2d_bc_SWMM_Culvert_Connections_001_L&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;      ! Links 1D SWMM culverts to the 2D TUFLOW domain&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &lt;br /&gt;
&amp;lt;li&amp;gt;Save the TBC.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Sim_Control_02c.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== TUFLOW SWMM Control File (TSCF) ===&lt;br /&gt;
A new control file, the TUFLOW SWMM Control File (TSCF), is used to control the SWMM input data. All 1D SWMM files and commands are referenced in the TUFLOW SWMM Control File.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;From &#039;&#039;&#039;TS01_001.tcf&#039;&#039;&#039;, right click &#039;&#039;&#039;TS01_001.tscf&#039;&#039;&#039; and select &#039;Open File&#039;. This opens &#039;&#039;&#039;TS01_001.tscf&#039;&#039;&#039; into a new tab in Notepad ++.&lt;br /&gt;
&amp;lt;li&amp;gt;Add the following command: &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Read SWMM &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;== &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;swmm\sw01_001.inp&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;green&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;  ! 1D SWMM culvert input file&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save the TSCF.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Sim_Control_03c.mp4|width=1235}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Running the Simulation =&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Save a copy of &#039;&#039;&#039;_run_M02_HPC.bat&#039;&#039;&#039; as &#039;&#039;&#039;_run_TS01_HPC.bat&#039;&#039;&#039; in the &#039;&#039;&#039;TUFLOW_SWMM_Module_01\TUFLOW\runs&#039;&#039;&#039; folder.&lt;br /&gt;
&amp;lt;li&amp;gt;Update the batch file to reference the &#039;&#039;&#039;TS01_5m_001.tcf&#039;&#039;&#039; :&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&#039;&#039;&#039;set&#039;&#039;&#039;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;exe&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&amp;quot;..\..\..\exe\2025.2.1\TUFLOW_iSP_w64.exe&amp;quot;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;&#039;&#039;&#039;set&#039;&#039;&#039;&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;run&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;red&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;=&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt;&amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;start &amp;quot;TUFLOW&amp;quot; /wait&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; %exe%&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt; -b&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;font color=&amp;quot;orange&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;%run% &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &amp;lt;font color=&amp;quot;black&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;TS01_5m_001.tcf &amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; &lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Save the batch file and double click it in Windows File Explorer to run the simulation. &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
If the model simulation doesn&#039;t run:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Check in the screen output or the tlf file near the end for &amp;quot;For SWMM Model Errors see:&amp;quot;. This indicates that there is something wrong with the SWMM inputs. Reviewing that file will provide feedback on what is wrong.&lt;br /&gt;
&amp;lt;li&amp;gt; Review this link for common &amp;lt;u&amp;gt;[[TUFLOW_SWMM_Troubleshooting | TUFLOW SWMM Troubleshooting]]&amp;lt;/u&amp;gt; advice.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
{{Video|name=Animation_TS1_Run_Sim_01d.mp4|width=1236}}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Check Files and Results Output=&lt;br /&gt;
Complete the steps outlined in following links to review check files and simulation results from the TUFLOW SWMM model simulation:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01_Check_QGIS | TUFLOW SWMM Tutorial 01 Check Files]]&amp;lt;/u&amp;gt; &amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01_Results_QGIS | TUFLOW SWMM Tutorial 01 Results]]&amp;lt;/u&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
= Conclusion =&lt;br /&gt;
*EPA SWMM culverts were added to convey water through the structures under the three roads in the tutorial model.&lt;br /&gt;
*Check files were used to review the inclusion of 1D SWMM culverts to a 2D TUFLOW model.&lt;br /&gt;
*Results through the 1D culverts were assessed.&lt;br /&gt;
*For further training opportunities see &amp;lt;u&amp;gt;[https://tuflow.com/training/training-course-catalogue/ TUFLOW Training Catalogue]&amp;lt;/u&amp;gt; and/or contact &amp;lt;u&amp;gt;[mailto:training@tuflow.com training@tuflow.com]&amp;lt;/u&amp;gt;.&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Other TUFLOW SWMM Tutorials=&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M01 | TUFLOW SWMM Module 1]]&amp;lt;/u&amp;gt;  - 1D SWMM Culverts&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M02 | TUFLOW SWMM Module 2]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 2D TUFLOW Direct Rainfall Hydrology&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M03 | TUFLOW SWMM Module 3]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology&lt;br /&gt;
*&amp;lt;u&amp;gt;[[TUFLOW_SWMM_Tutorial_M04 | TUFLOW SWMM Module 4]]&amp;lt;/u&amp;gt;  - 1D SWMM Pipe Network / 1D SWMM Urban Hydrology: Executing multiple different event simulations from a single model control file.&lt;br /&gt;
*&amp;lt;u&amp;gt;[[XPSWMM_to_TUFLOW-SWMM | XPSWMM to TUFLOW SWMM]]&amp;lt;/u&amp;gt;  - How to convert an XPSWMM model to TUFLOW SWMM.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[TUFLOW_SWMM_Tutorial_Introduction#Tutorial_Modules| Return to TUFLOW SWMM Tutorial Introduction Main Page]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44983</id>
		<title>NotepadPlusPlus Run TUFLOW</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44983"/>
		<updated>2025-09-26T06:56:46Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To run TUFLOW from Notepad++ we need to create a new Run option.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select the &#039;&#039;Run &amp;gt;&amp;gt;&amp;gt; Run&#039;&#039; menu items.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run dialogue select the three dots (...), navigate to and select the desired executable.  If there are spaces in the name this path should be enclosed in quotes.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the command line after the TUFLOW path enter &amp;quot;space&amp;quot; (without the quotes) and &amp;lt;tt&amp;gt;&amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/tt&amp;gt; (with the quotes).&amp;lt;br&amp;gt;&lt;br /&gt;
The line should be of the form as bellow where the executable path matches the location on your computer:&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;C:\TUFLOW\Releases\2020-10-AA\TUFLOW_iSP_w64.exe&amp;quot; &amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW1.png]]&lt;br /&gt;
&amp;lt;li&amp;gt;This tells notepad to pass the currently open file to TUFLOW as the input file.&lt;br /&gt;
&amp;lt;li&amp;gt;Select Save and give the item a sensible name e.g. TUFLOW 2020-10-AA-iSP.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;To run TUFLOW with the currently open TCF file, simply select the item from the Run menu (or set a shortcut if desired).&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW2.png]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Troubleshooting&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
If you receive a &amp;quot;ShellExecute  ERROR&amp;quot;, further configuration is necessary.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:shell_execute_error.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows Explorer navigate to the folder location where you have saved the TUFLOW executable.&lt;br /&gt;
&amp;lt;li&amp;gt; Double left mouse click the TUFLOW executable. When the following protection pop-up appears, select &amp;quot;More info&amp;quot; &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Windows_Protection.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;Run anyway&amp;quot;. This will open a DOS window and run the TUFLOW executable.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Windows_Run_Anyway.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Close the TUFLOW DOS window.&lt;br /&gt;
&amp;lt;li&amp;gt; Restart Notepad++. The TUFLOW Run Option should now function correctly. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;TIP:&#039;&#039;&#039; The shortcuts can be found and edited in the shortcuts.xml file stored on your machine.  The easiest way to find this is to search for it, on my computer it is located here:&lt;br /&gt;
C:\Users\username\AppData\Roaming\Notepad++\&lt;br /&gt;
&lt;br /&gt;
This file includes all of the commands for the shortcuts in your &amp;quot;Run&amp;quot; menu. In this case the final entry is the TUFLOW entry.&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
    &amp;lt;UserDefinedCommands&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Launch in Firefox&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;88&amp;quot;&amp;gt;firefox &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Get php help&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;112&amp;quot;&amp;gt;https://www.php.net/%20$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Google Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;113&amp;quot;&amp;gt;https://www.google.com/search?q=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Wikipedia Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;114&amp;quot;&amp;gt;https://en.wikipedia.org/wiki/Special:Search?search=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;116&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file (relative)&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;32&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_DIRECTORY)/$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open in another instance&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;117&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD) -nosession -multiInst&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open containing folder&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;explorer $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open current dir cmd&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;cmd /K cd $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Send via Outlook&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;79&amp;quot;&amp;gt;outlook /a &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;TUFLOW 2011-09-w64-iSP&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;&amp;amp;quot;C:\TUFLOW\Releases\2011-09\w64\TUFLOW_iSP_w64.exe&amp;amp;quot; &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
    &amp;lt;/UserDefinedCommands&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[NotepadPlusPlus_Tips | Back to Notepad ++ tips.]]&lt;br /&gt;
}} &amp;lt;br&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44982</id>
		<title>NotepadPlusPlus Run TUFLOW</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44982"/>
		<updated>2025-09-26T06:55:24Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To run TUFLOW from Notepad++ we need to create a new Run option.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select the &#039;&#039;Run &amp;gt;&amp;gt;&amp;gt; Run&#039;&#039; menu items.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run dialogue select the three dots (...), navigate to and select the desired executable.  If there are spaces in the name this path should be enclosed in quotes.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the command line after the TUFLOW path enter &amp;quot;space&amp;quot; (without the quotes) and &amp;lt;tt&amp;gt;&amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/tt&amp;gt; (with the quotes).&amp;lt;br&amp;gt;&lt;br /&gt;
The line should be of the form as bellow where the executable path matches the location on your computer:&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;C:\TUFLOW\Releases\2020-10-AA\TUFLOW_iSP_w64.exe&amp;quot; &amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW1.png]]&lt;br /&gt;
&amp;lt;li&amp;gt;This tells notepad to pass the currently open file to TUFLOW as the input file.&lt;br /&gt;
&amp;lt;li&amp;gt;Select Save and give the item a sensible name e.g. TUFLOW 2020-10-AA-iSP.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;To run TUFLOW with the currently open TCF file, simply select the item from the Run menu (or set a shortcut if desired).&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW2.png]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Troubleshooting&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
If you receive a &amp;quot;ShellExecute  ERROR&amp;quot; further configuration is necessary.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:shell_execute_error.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows Exporer navigate to the folder location where you have saved the TUFLOW executable.&lt;br /&gt;
&amp;lt;li&amp;gt; Double left mouse click the TUFLOW executable. When the following protection pop-up appears, select &amp;quot;More info&amp;quot; &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Windows_Protection.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;Run anyway&amp;quot;. This will open a DOS window and run the TUFLOW executable.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Windows_Run_Anyway.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Close the TUFLOW DOS window.&lt;br /&gt;
&amp;lt;li&amp;gt; Restart Notepad++. The TUFLOW Run Option should now function correctly. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;TIP:&#039;&#039;&#039; The shortcuts can be found and edited in the shortcuts.xml file stored on your machine.  The easiest way to find this is to search for it, on my computer it is located here:&lt;br /&gt;
C:\Users\username\AppData\Roaming\Notepad++\&lt;br /&gt;
&lt;br /&gt;
This file includes all of the commands for the shortcuts in your &amp;quot;Run&amp;quot; menu. In this case the final entry is the TUFLOW entry.&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
    &amp;lt;UserDefinedCommands&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Launch in Firefox&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;88&amp;quot;&amp;gt;firefox &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Get php help&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;112&amp;quot;&amp;gt;https://www.php.net/%20$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Google Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;113&amp;quot;&amp;gt;https://www.google.com/search?q=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Wikipedia Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;114&amp;quot;&amp;gt;https://en.wikipedia.org/wiki/Special:Search?search=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;116&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file (relative)&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;32&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_DIRECTORY)/$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open in another instance&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;117&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD) -nosession -multiInst&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open containing folder&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;explorer $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open current dir cmd&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;cmd /K cd $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Send via Outlook&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;79&amp;quot;&amp;gt;outlook /a &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;TUFLOW 2011-09-w64-iSP&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;&amp;amp;quot;C:\TUFLOW\Releases\2011-09\w64\TUFLOW_iSP_w64.exe&amp;amp;quot; &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
    &amp;lt;/UserDefinedCommands&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[NotepadPlusPlus_Tips | Back to Notepad ++ tips.]]&lt;br /&gt;
}} &amp;lt;br&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44981</id>
		<title>NotepadPlusPlus Run TUFLOW</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44981"/>
		<updated>2025-09-26T06:54:24Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To run TUFLOW from Notepad++ we need to create a new Run option.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select the &#039;&#039;Run &amp;gt;&amp;gt;&amp;gt; Run&#039;&#039; menu items.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run dialogue select the three dots (...), navigate to and select the desired executable.  If there are spaces in the name this path should be enclosed in quotes.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the command line after the TUFLOW path enter &amp;quot;space&amp;quot; (without the quotes) and &amp;lt;tt&amp;gt;&amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/tt&amp;gt; (with the quotes).&amp;lt;br&amp;gt;&lt;br /&gt;
The line should be of the form as bellow where the executable path matches the location on your computer:&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;C:\TUFLOW\Releases\2020-10-AA\TUFLOW_iSP_w64.exe&amp;quot; &amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW1.png]]&lt;br /&gt;
&amp;lt;li&amp;gt;This tells notepad to pass the currently open file to TUFLOW as the input file.&lt;br /&gt;
&amp;lt;li&amp;gt;Select Save and give the item a sensible name e.g. TUFLOW 2020-10-AA-iSP.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;To run TUFLOW with the currently open TCF file, simply select the item from the Run menu (or set a shortcut if desired).&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW2.png]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Troubleshooting&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
If you receive a &amp;quot;ShellExecute  ERROR&amp;quot; further configuration is necessary.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:shell_execute_error.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows Exporer navigate to the folder location where you have saved the TUFLOW executable.&lt;br /&gt;
&amp;lt;li&amp;gt; Double left mouse click the TUFLOW executable. When the following protection pop-up appears, select &amp;quot;More info&amp;quot; &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Windows_Protection.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;Run anyway&amp;quot;. This will open a DOS window and run the TUFLOW executable.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Windows_Run_Anyway.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Close the TUFLOW DOS window.&lt;br /&gt;
&amp;lt;li&amp;gt; Restart Notepad++. The TUFLOW Run Option should now function correctly. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[NotepadPlusPlus_Tips | Back to Notepad ++ tips.]]&lt;br /&gt;
}} &amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;TIP:&#039;&#039;&#039; The shortcuts can be found and edited in the shortcuts.xml file stored on your machine.  The easiest way to find this is to search for it, on my computer it is located here:&lt;br /&gt;
C:\Users\username\AppData\Roaming\Notepad++\&lt;br /&gt;
&lt;br /&gt;
This file includes all of the commands for the shortcuts in your &amp;quot;Run&amp;quot; menu. In this case the final entry is the TUFLOW entry.&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
    &amp;lt;UserDefinedCommands&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Launch in Firefox&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;88&amp;quot;&amp;gt;firefox &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Get php help&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;112&amp;quot;&amp;gt;https://www.php.net/%20$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Google Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;113&amp;quot;&amp;gt;https://www.google.com/search?q=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Wikipedia Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;114&amp;quot;&amp;gt;https://en.wikipedia.org/wiki/Special:Search?search=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;116&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file (relative)&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;32&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_DIRECTORY)/$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open in another instance&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;117&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD) -nosession -multiInst&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open containing folder&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;explorer $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open current dir cmd&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;cmd /K cd $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Send via Outlook&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;79&amp;quot;&amp;gt;outlook /a &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;TUFLOW 2011-09-w64-iSP&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;&amp;amp;quot;C:\TUFLOW\Releases\2011-09\w64\TUFLOW_iSP_w64.exe&amp;amp;quot; &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
    &amp;lt;/UserDefinedCommands&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44980</id>
		<title>NotepadPlusPlus Run TUFLOW</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44980"/>
		<updated>2025-09-26T06:54:01Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To run TUFLOW from Notepad++ we need to create a new Run option.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select the &#039;&#039;Run &amp;gt;&amp;gt;&amp;gt; Run&#039;&#039; menu items.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run dialogue select the three dots (...), navigate to and select the desired executable.  If there are spaces in the name this path should be enclosed in quotes.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the command line after the TUFLOW path enter &amp;quot;space&amp;quot; (without the quotes) and &amp;lt;tt&amp;gt;&amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/tt&amp;gt; (with the quotes).&amp;lt;br&amp;gt;&lt;br /&gt;
The line should be of the form as bellow where the executable path matches the location on your computer:&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;C:\TUFLOW\Releases\2020-10-AA\TUFLOW_iSP_w64.exe&amp;quot; &amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW1.png]]&lt;br /&gt;
&amp;lt;li&amp;gt;This tells notepad to pass the currently open file to TUFLOW as the input file.&lt;br /&gt;
&amp;lt;li&amp;gt;Select Save and give the item a sensible name e.g. TUFLOW 2020-10-AA-iSP.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;To run TUFLOW with the currently open TCF file, simply select the item from the Run menu (or set a shortcut if desired).&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW2.png]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Troubleshooting&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
If you receive a &amp;quot;ShellExecute  ERROR&amp;quot; further configuration is necessary.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:shell_execute_error.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows Exporer navigate to the folder location where you have saved the TUFLOW executable.&lt;br /&gt;
&amp;lt;li&amp;gt; Double left mouse click the TUFLOW executable. When the following protection pop-up appears, select &amp;quot;More info&amp;quot; &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Windows_Protection.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;Run anyway&amp;quot;. This will open a DOS window and run the TUFLOW executable.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Windows_Run_Anyway.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Close the TUFLOW DOS window.&lt;br /&gt;
&amp;lt;li&amp;gt; Restart Notepad++. The TUFLOW Run Option should now function correctly. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[NotepadPlusPlus_Tips | Back to Notepad ++ tips.]]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;TIP:&#039;&#039;&#039; The shortcuts can be found and edited in the shortcuts.xml file stored on your machine.  The easiest way to find this is to search for it, on my computer it is located here:&lt;br /&gt;
C:\Users\username\AppData\Roaming\Notepad++\&lt;br /&gt;
&lt;br /&gt;
This file includes all of the commands for the shortcuts in your &amp;quot;Run&amp;quot; menu. In this case the final entry is the TUFLOW entry.&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
    &amp;lt;UserDefinedCommands&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Launch in Firefox&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;88&amp;quot;&amp;gt;firefox &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Get php help&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;112&amp;quot;&amp;gt;https://www.php.net/%20$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Google Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;113&amp;quot;&amp;gt;https://www.google.com/search?q=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Wikipedia Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;114&amp;quot;&amp;gt;https://en.wikipedia.org/wiki/Special:Search?search=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;116&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file (relative)&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;32&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_DIRECTORY)/$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open in another instance&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;117&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD) -nosession -multiInst&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open containing folder&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;explorer $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open current dir cmd&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;cmd /K cd $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Send via Outlook&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;79&amp;quot;&amp;gt;outlook /a &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;TUFLOW 2011-09-w64-iSP&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;&amp;amp;quot;C:\TUFLOW\Releases\2011-09\w64\TUFLOW_iSP_w64.exe&amp;amp;quot; &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
    &amp;lt;/UserDefinedCommands&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44979</id>
		<title>NotepadPlusPlus Run TUFLOW</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44979"/>
		<updated>2025-09-26T06:53:40Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To run TUFLOW from Notepad++ we need to create a new Run option.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select the &#039;&#039;Run &amp;gt;&amp;gt;&amp;gt; Run&#039;&#039; menu items.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run dialogue select the three dots (...), navigate to and select the desired executable.  If there are spaces in the name this path should be enclosed in quotes.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the command line after the TUFLOW path enter &amp;quot;space&amp;quot; (without the quotes) and &amp;lt;tt&amp;gt;&amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/tt&amp;gt; (with the quotes).&amp;lt;br&amp;gt;&lt;br /&gt;
The line should be of the form as bellow where the executable path matches the location on your computer:&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;C:\TUFLOW\Releases\2020-10-AA\TUFLOW_iSP_w64.exe&amp;quot; &amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW1.png]]&lt;br /&gt;
&amp;lt;li&amp;gt;This tells notepad to pass the currently open file to TUFLOW as the input file.&lt;br /&gt;
&amp;lt;li&amp;gt;Select Save and give the item a sensible name e.g. TUFLOW 2020-10-AA-iSP.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;To run TUFLOW with the currently open TCF file, simply select the item from the Run menu (or set a shortcut if desired).&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW2.png]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Troubleshooting&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
If you receive a &amp;quot;ShellExecute  ERROR&amp;quot; further configuration is necessary.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:shell_execute_error.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows Exporer navigate to the folder location where you have saved the TUFLOW executable.&lt;br /&gt;
&amp;lt;li&amp;gt; Double left mouse click the TUFLOW executable. When the following protection pop-up appears, select &amp;quot;More info&amp;quot; &lt;br /&gt;
[[File:Windows_Protection.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;Run anyway&amp;quot;. This will open a DOS window and run the TUFLOW executable.&lt;br /&gt;
[[File:Windows_Run_Anyway.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Close the TUFLOW DOS window.&lt;br /&gt;
&amp;lt;li&amp;gt; Restart Notepad++. The TUFLOW Run Option should now function correctly. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[NotepadPlusPlus_Tips | Back to Notepad ++ tips.]]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;TIP:&#039;&#039;&#039; The shortcuts can be found and edited in the shortcuts.xml file stored on your machine.  The easiest way to find this is to search for it, on my computer it is located here:&lt;br /&gt;
C:\Users\username\AppData\Roaming\Notepad++\&lt;br /&gt;
&lt;br /&gt;
This file includes all of the commands for the shortcuts in your &amp;quot;Run&amp;quot; menu. In this case the final entry is the TUFLOW entry.&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
    &amp;lt;UserDefinedCommands&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Launch in Firefox&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;88&amp;quot;&amp;gt;firefox &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Get php help&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;112&amp;quot;&amp;gt;https://www.php.net/%20$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Google Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;113&amp;quot;&amp;gt;https://www.google.com/search?q=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Wikipedia Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;114&amp;quot;&amp;gt;https://en.wikipedia.org/wiki/Special:Search?search=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;116&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file (relative)&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;32&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_DIRECTORY)/$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open in another instance&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;117&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD) -nosession -multiInst&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open containing folder&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;explorer $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open current dir cmd&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;cmd /K cd $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Send via Outlook&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;79&amp;quot;&amp;gt;outlook /a &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;TUFLOW 2011-09-w64-iSP&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;&amp;amp;quot;C:\TUFLOW\Releases\2011-09\w64\TUFLOW_iSP_w64.exe&amp;amp;quot; &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
    &amp;lt;/UserDefinedCommands&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44978</id>
		<title>NotepadPlusPlus Run TUFLOW</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44978"/>
		<updated>2025-09-26T06:53:09Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To run TUFLOW from Notepad++ we need to create a new Run option.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select the &#039;&#039;Run &amp;gt;&amp;gt;&amp;gt; Run&#039;&#039; menu items.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run dialogue select the three dots (...), navigate to and select the desired executable.  If there are spaces in the name this path should be enclosed in quotes.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the command line after the TUFLOW path enter &amp;quot;space&amp;quot; (without the quotes) and &amp;lt;tt&amp;gt;&amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/tt&amp;gt; (with the quotes).&amp;lt;br&amp;gt;&lt;br /&gt;
The line should be of the form as bellow where the executable path matches the location on your computer:&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;C:\TUFLOW\Releases\2020-10-AA\TUFLOW_iSP_w64.exe&amp;quot; &amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW1.png]]&lt;br /&gt;
&amp;lt;li&amp;gt;This tells notepad to pass the currently open file to TUFLOW as the input file.&lt;br /&gt;
&amp;lt;li&amp;gt;Select Save and give the item a sensible name e.g. TUFLOW 2020-10-AA-iSP.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;To run TUFLOW with the currently open TCF file, simply select the item from the Run menu (or set a shortcut if desired).&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW2.png]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Troubleshooting&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
If you receive a &amp;quot;ShellExecute  ERROR&amp;quot; further configuration is necessary.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:shell_execute_error.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows Exporer navigate to the folder location where you have saved the TUFLOW executable.&lt;br /&gt;
&amp;lt;li&amp;gt; Double left mouse click the TUFLOW executable. When the following protection pop-up appears, select &amp;quot;More info&amp;quot; &lt;br /&gt;
[[Windows_Protection.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;Run anyway&amp;quot;. This will open a DOS window and run the TUFLOW executable.&lt;br /&gt;
[[Windows_Run_Anyway.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Close the TUFLOW DOS window.&lt;br /&gt;
&amp;lt;li&amp;gt; Restart Notepad++. The TUFLOW Run Option should now function correctly. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[NotepadPlusPlus_Tips | Back to Notepad ++ tips.]]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;TIP:&#039;&#039;&#039; The shortcuts can be found and edited in the shortcuts.xml file stored on your machine.  The easiest way to find this is to search for it, on my computer it is located here:&lt;br /&gt;
C:\Users\username\AppData\Roaming\Notepad++\&lt;br /&gt;
&lt;br /&gt;
This file includes all of the commands for the shortcuts in your &amp;quot;Run&amp;quot; menu. In this case the final entry is the TUFLOW entry.&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
    &amp;lt;UserDefinedCommands&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Launch in Firefox&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;88&amp;quot;&amp;gt;firefox &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Get php help&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;112&amp;quot;&amp;gt;https://www.php.net/%20$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Google Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;113&amp;quot;&amp;gt;https://www.google.com/search?q=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Wikipedia Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;114&amp;quot;&amp;gt;https://en.wikipedia.org/wiki/Special:Search?search=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;116&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file (relative)&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;32&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_DIRECTORY)/$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open in another instance&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;117&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD) -nosession -multiInst&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open containing folder&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;explorer $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open current dir cmd&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;cmd /K cd $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Send via Outlook&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;79&amp;quot;&amp;gt;outlook /a &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;TUFLOW 2011-09-w64-iSP&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;&amp;amp;quot;C:\TUFLOW\Releases\2011-09\w64\TUFLOW_iSP_w64.exe&amp;amp;quot; &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
    &amp;lt;/UserDefinedCommands&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44977</id>
		<title>NotepadPlusPlus Run TUFLOW</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44977"/>
		<updated>2025-09-26T06:52:52Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To run TUFLOW from Notepad++ we need to create a new Run option.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select the &#039;&#039;Run &amp;gt;&amp;gt;&amp;gt; Run&#039;&#039; menu items.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run dialogue select the three dots (...), navigate to and select the desired executable.  If there are spaces in the name this path should be enclosed in quotes.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the command line after the TUFLOW path enter &amp;quot;space&amp;quot; (without the quotes) and &amp;lt;tt&amp;gt;&amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/tt&amp;gt; (with the quotes).&amp;lt;br&amp;gt;&lt;br /&gt;
The line should be of the form as bellow where the executable path matches the location on your computer:&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;C:\TUFLOW\Releases\2020-10-AA\TUFLOW_iSP_w64.exe&amp;quot; &amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW1.png]]&lt;br /&gt;
&amp;lt;li&amp;gt;This tells notepad to pass the currently open file to TUFLOW as the input file.&lt;br /&gt;
&amp;lt;li&amp;gt;Select Save and give the item a sensible name e.g. TUFLOW 2020-10-AA-iSP.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;To run TUFLOW with the currently open TCF file, simply select the item from the Run menu (or set a shortcut if desired).&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW2.png]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&#039;&#039;&#039;Troubleshooting&#039;&#039;&#039;&lt;br /&gt;
If you receive a &amp;quot;ShellExecute  ERROR&amp;quot; further configuration is necessary.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:shell_execute_error.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows Exporer navigate to the folder location where you have saved the TUFLOW executable.&lt;br /&gt;
&amp;lt;li&amp;gt; Double left mouse click the TUFLOW executable. When the following protection pop-up appears, select &amp;quot;More info&amp;quot; &lt;br /&gt;
[[Windows_Protection.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;Run anyway&amp;quot;. This will open a DOS window and run the TUFLOW executable.&lt;br /&gt;
[[Windows_Run_Anyway.png|400px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; Close the TUFLOW DOS window.&lt;br /&gt;
&amp;lt;li&amp;gt; Restart Notepad++. The TUFLOW Run Option should now function correctly. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[NotepadPlusPlus_Tips | Back to Notepad ++ tips.]]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;TIP:&#039;&#039;&#039; The shortcuts can be found and edited in the shortcuts.xml file stored on your machine.  The easiest way to find this is to search for it, on my computer it is located here:&lt;br /&gt;
C:\Users\username\AppData\Roaming\Notepad++\&lt;br /&gt;
&lt;br /&gt;
This file includes all of the commands for the shortcuts in your &amp;quot;Run&amp;quot; menu. In this case the final entry is the TUFLOW entry.&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
    &amp;lt;UserDefinedCommands&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Launch in Firefox&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;88&amp;quot;&amp;gt;firefox &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Get php help&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;112&amp;quot;&amp;gt;https://www.php.net/%20$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Google Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;113&amp;quot;&amp;gt;https://www.google.com/search?q=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Wikipedia Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;114&amp;quot;&amp;gt;https://en.wikipedia.org/wiki/Special:Search?search=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;116&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file (relative)&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;32&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_DIRECTORY)/$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open in another instance&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;117&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD) -nosession -multiInst&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open containing folder&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;explorer $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open current dir cmd&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;cmd /K cd $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Send via Outlook&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;79&amp;quot;&amp;gt;outlook /a &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;TUFLOW 2011-09-w64-iSP&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;&amp;amp;quot;C:\TUFLOW\Releases\2011-09\w64\TUFLOW_iSP_w64.exe&amp;amp;quot; &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
    &amp;lt;/UserDefinedCommands&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=File:Windows_Run_Anyway.png&amp;diff=44976</id>
		<title>File:Windows Run Anyway.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=File:Windows_Run_Anyway.png&amp;diff=44976"/>
		<updated>2025-09-26T06:51:32Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=File:Windows_Protection.png&amp;diff=44975</id>
		<title>File:Windows Protection.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=File:Windows_Protection.png&amp;diff=44975"/>
		<updated>2025-09-26T06:51:22Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=File:Shell_execute_error.png&amp;diff=44974</id>
		<title>File:Shell execute error.png</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=File:Shell_execute_error.png&amp;diff=44974"/>
		<updated>2025-09-26T06:51:14Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44973</id>
		<title>NotepadPlusPlus Run TUFLOW</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44973"/>
		<updated>2025-09-26T06:50:59Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To run TUFLOW from Notepad++ we need to create a new Run option.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select the &#039;&#039;Run &amp;gt;&amp;gt;&amp;gt; Run&#039;&#039; menu items.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run dialogue select the three dots (...), navigate to and select the desired executable.  If there are spaces in the name this path should be enclosed in quotes.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the command line after the TUFLOW path enter &amp;quot;space&amp;quot; (without the quotes) and &amp;lt;tt&amp;gt;&amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/tt&amp;gt; (with the quotes).&amp;lt;br&amp;gt;&lt;br /&gt;
The line should be of the form as bellow where the executable path matches the location on your computer:&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;C:\TUFLOW\Releases\2020-10-AA\TUFLOW_iSP_w64.exe&amp;quot; &amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW1.png]]&lt;br /&gt;
&amp;lt;li&amp;gt;This tells notepad to pass the currently open file to TUFLOW as the input file.&lt;br /&gt;
&amp;lt;li&amp;gt;Select Save and give the item a sensible name e.g. TUFLOW 2020-10-AA-iSP.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;To run TUFLOW with the currently open TCF file, simply select the item from the Run menu (or set a shortcut if desired).&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW2.png]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Troubleshooting&#039;&#039;&#039;&lt;br /&gt;
If you receive a &amp;quot;ShellExecute  ERROR&amp;quot; further configuration is necessary.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:shell_execute_error.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows Exporer navigate to the folder location where you have saved the TUFLOW executable.&lt;br /&gt;
&amp;lt;li&amp;gt; Double left mouse click the TUFLOW executable. When the following protection pop-up appears, select &amp;quot;More info&amp;quot; &lt;br /&gt;
[[Windows_Protection.png ]] &lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;Run anyway&amp;quot;. This will open a DOS window and run the TUFLOW executable.&lt;br /&gt;
[[Windows_Run_Anyway.png]]&lt;br /&gt;
&amp;lt;li&amp;gt; Close the TUFLOW DOS window.&lt;br /&gt;
&amp;lt;li&amp;gt; Restart Notepad++. The TUFLOW Run Option should now function correctly. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[NotepadPlusPlus_Tips | Back to Notepad ++ tips.]]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;TIP:&#039;&#039;&#039; The shortcuts can be found and edited in the shortcuts.xml file stored on your machine.  The easiest way to find this is to search for it, on my computer it is located here:&lt;br /&gt;
C:\Users\username\AppData\Roaming\Notepad++\&lt;br /&gt;
&lt;br /&gt;
This file includes all of the commands for the shortcuts in your &amp;quot;Run&amp;quot; menu. In this case the final entry is the TUFLOW entry.&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
    &amp;lt;UserDefinedCommands&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Launch in Firefox&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;88&amp;quot;&amp;gt;firefox &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Get php help&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;112&amp;quot;&amp;gt;https://www.php.net/%20$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Google Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;113&amp;quot;&amp;gt;https://www.google.com/search?q=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Wikipedia Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;114&amp;quot;&amp;gt;https://en.wikipedia.org/wiki/Special:Search?search=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;116&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file (relative)&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;32&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_DIRECTORY)/$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open in another instance&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;117&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD) -nosession -multiInst&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open containing folder&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;explorer $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open current dir cmd&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;cmd /K cd $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Send via Outlook&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;79&amp;quot;&amp;gt;outlook /a &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;TUFLOW 2011-09-w64-iSP&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;&amp;amp;quot;C:\TUFLOW\Releases\2011-09\w64\TUFLOW_iSP_w64.exe&amp;amp;quot; &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
    &amp;lt;/UserDefinedCommands&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44972</id>
		<title>NotepadPlusPlus Run TUFLOW</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=NotepadPlusPlus_Run_TUFLOW&amp;diff=44972"/>
		<updated>2025-09-26T06:50:22Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;To run TUFLOW from Notepad++ we need to create a new Run option.&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Select the &#039;&#039;Run &amp;gt;&amp;gt;&amp;gt; Run&#039;&#039; menu items.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the Run dialogue select the three dots (...), navigate to and select the desired executable.  If there are spaces in the name this path should be enclosed in quotes.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;In the command line after the TUFLOW path enter &amp;quot;space&amp;quot; (without the quotes) and &amp;lt;tt&amp;gt;&amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/tt&amp;gt; (with the quotes).&amp;lt;br&amp;gt;&lt;br /&gt;
The line should be of the form as bellow where the executable path matches the location on your computer:&amp;lt;br&amp;gt;&lt;br /&gt;
: &amp;quot;C:\TUFLOW\Releases\2020-10-AA\TUFLOW_iSP_w64.exe&amp;quot; &amp;quot;$(FULL_CURRENT_PATH)&amp;quot;&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW1.png]]&lt;br /&gt;
&amp;lt;li&amp;gt;This tells notepad to pass the currently open file to TUFLOW as the input file.&lt;br /&gt;
&amp;lt;li&amp;gt;Select Save and give the item a sensible name e.g. TUFLOW 2020-10-AA-iSP.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;To run TUFLOW with the currently open TCF file, simply select the item from the Run menu (or set a shortcut if desired).&amp;lt;/li&amp;gt;&lt;br /&gt;
[[File:Notepad_RunTUFLOW2.png]]&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;Troubleshooting&#039;&#039;&#039;&lt;br /&gt;
If you receive a &amp;quot;ShellExecute  ERROR&amp;quot; further configuration is necessary.&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:shell_execute_error.png]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt; In Windows Exporer navigate to the folder location where you have saved the TUFLOW executable.&lt;br /&gt;
&amp;lt;li&amp;gt; Double left mouse click the TUFLOW executable. When the following protection pop-up appears, select &amp;quot;More info&amp;quot; &lt;br /&gt;
[[Windows_Protection.png ]] &lt;br /&gt;
&amp;lt;li&amp;gt; Select &amp;quot;Run anyway&amp;quot;. This will open a DOS window and run the TUFLOW executable.&lt;br /&gt;
[[Windows_Run_Anyway.png]]&lt;br /&gt;
&amp;lt;li&amp;gt; Close the TUFLOW DOS window.&lt;br /&gt;
&amp;lt;li&amp;gt; Restart Notepad++. The TUFLOW Run Option should now function correctly. &lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[NotepadPlusPlus_Tips | Back to Notepad ++ tips.]]&lt;br /&gt;
&lt;br /&gt;
&#039;&#039;&#039;TIP:&#039;&#039;&#039; The shortcuts can be found and edited in the shortcuts.xml file stored on your machine.  The easiest way to find this is to search for it, on my computer it is located here:&lt;br /&gt;
C:\Users\username\AppData\Roaming\Notepad++\&lt;br /&gt;
&lt;br /&gt;
This file includes all of the commands for the shortcuts in your &amp;quot;Run&amp;quot; menu. In this case the final entry is the TUFLOW entry.&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
    &amp;lt;UserDefinedCommands&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Launch in Firefox&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;88&amp;quot;&amp;gt;firefox &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Get php help&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;112&amp;quot;&amp;gt;https://www.php.net/%20$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Google Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;113&amp;quot;&amp;gt;https://www.google.com/search?q=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Wikipedia Search&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;114&amp;quot;&amp;gt;https://en.wikipedia.org/wiki/Special:Search?search=$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;116&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open file (relative)&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;32&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_DIRECTORY)/$(CURRENT_WORD)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open in another instance&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;117&amp;quot;&amp;gt;$(NPP_DIRECTORY)\notepad++.exe $(CURRENT_WORD) -nosession -multiInst&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open containing folder&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;explorer $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Open current dir cmd&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;cmd /K cd $(CURRENT_DIRECTORY)&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;Send via Outlook&amp;quot; Ctrl=&amp;quot;yes&amp;quot; Alt=&amp;quot;yes&amp;quot; Shift=&amp;quot;yes&amp;quot; Key=&amp;quot;79&amp;quot;&amp;gt;outlook /a &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
        &amp;lt;Command name=&amp;quot;TUFLOW 2011-09-w64-iSP&amp;quot; Ctrl=&amp;quot;no&amp;quot; Alt=&amp;quot;no&amp;quot; Shift=&amp;quot;no&amp;quot; Key=&amp;quot;0&amp;quot;&amp;gt;&amp;amp;quot;C:\TUFLOW\Releases\2011-09\w64\TUFLOW_iSP_w64.exe&amp;amp;quot; &amp;amp;quot;$(FULL_CURRENT_PATH)&amp;amp;quot;&amp;lt;/Command&amp;gt;&lt;br /&gt;
    &amp;lt;/UserDefinedCommands&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Naming_Convention&amp;diff=44589</id>
		<title>Naming Convention</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Naming_Convention&amp;diff=44589"/>
		<updated>2025-08-05T23:40:44Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Control and Input Files – Version Numbering Convention */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__TOC__&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The establishment of a sound naming convention is fundamental to the easy management of TUFLOW models and their associated files. A certain degree of flexibility regarding naming conventions is usually required due to differences between projects and users. However, early establishment of a system has the following benefits:&lt;br /&gt;
* Easier to understand modelling logic;&lt;br /&gt;
* Easier to check for errors;&lt;br /&gt;
* Traceability;&lt;br /&gt;
* Transferable between different users; and&lt;br /&gt;
* Ease of handover of the model to the Client or Authorities.&lt;br /&gt;
Additionally, a sound naming convention can significantly reduce the time taken to locate files, especially in folders where hundreds of files are present, which may be the case for large modelling projects. Once a naming and numbering convention is adopted, then a &amp;lt;u&amp;gt;[[TUFLOW_Modelling_Log|modelling log]]&amp;lt;/u&amp;gt; can more easily be kept.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
There is some simple advice on naming conventions in the &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt;.&amp;lt;br&amp;gt;&lt;br /&gt;
Currently, most modelling incorporates use of the TUFLOW scenario and event management feature. This allows for wildcards to be incorporated in the file name. &amp;lt;u&amp;gt;[[TUFLOW Example Models|Example models]]&amp;lt;/u&amp;gt; are available which demonstrate Scenario/Event management. A &amp;lt;u&amp;gt;[[ Run_TUFLOW_From_a_Batch-file#Looping_in_a_batch_file|batch file]]&amp;lt;/u&amp;gt; can then be set up to run various scenario combinations from the one TUFLOW Control File (TCF).&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The below sections provide information on the recommended naming convention for clearly identifying different types of TUFLOW input files. Guidance is also provided on a version numbering convention for control and input files during model development.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Input File Type – Prefix Naming Conventions=&lt;br /&gt;
As the bulk of the data input to TUFLOW is via GIS layers, efficient management of these datasets is essential. Different TUFLOW input files require different GIS attributes. For example, an initial water level input file only requires a single attribute on the GIS file (which is the initial water level), whereas, a 1D channel has a number of attributes (channel type, inverts etc.). Differentiating between these TUFLOW file types is therefore essential.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
TUFLOW input files are given different recommended prefixes depending on their purpose. An example of this is demonstrated in the table below. The complete list of recommended prefixes can be found in the &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt;. The TCF command &amp;lt;font color=&amp;quot;blue&amp;quot;&amp;gt;&amp;lt;tt&amp;gt;Write Empty GIS Files&amp;lt;/tt&amp;gt;&amp;lt;/font&amp;gt; can be used to automate the creation of the template (empty) files, which use these recommended prefixes. These empty files are created with the precise GIS file formats required for each input TUFLOW file. The &amp;lt;u&amp;gt;[[TUFLOW Empty Files]]&amp;lt;/u&amp;gt; page provides a reference list of the template (empty) GIS files, the associated TUFLOW command and a basic description of their function.&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
It is strongly recommended that the prefixes described in the &amp;lt;u&amp;gt;[https://docs.tuflow.com/classic-hpc/manual/latest/ TUFLOW Manual]&amp;lt;/u&amp;gt; be adhered to for all 1D and 2D GIS layers. This greatly enhances the data management efficiency and, importantly, allows for the differentiation of input files, making it easier for another modeller or reviewer to quickly interpret the model.&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; width=&amp;quot;75%&amp;quot;&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=20%| GIS Data Type&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=20%| Suggested File Prefix&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white&amp;quot; width=60%| Description&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;text-align: left;&amp;quot; | 2D Boundaries and 2D/1D Links&lt;br /&gt;
| style=&amp;quot;text-align: left;&amp;quot; | 2d_bc_ &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;(2d_hx_) &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;(2d_sx_) &lt;br /&gt;
|| Mandatory layer(s) defining the locations of 2D boundaries and 2D/1D dynamic links. For large models it may be wise to separate the boundary conditions from the 1D/2D links, in which case the 2d_bc prefix can be substituted with 2d_hx_ and 2d_sx. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;Cell code values may also be defined in this layer.&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
TUFLOW control files are structured to allow the majority of commands to be repeated and layered. Input file types of the same prefix may need to be used more than once. Hence, additional information such as a descriptor and a file version number is conventionally included in the input file name. An example of a typical file name for an input file is shown below: &lt;br /&gt;
&lt;br /&gt;
*GeoPackage:&lt;br /&gt;
:* Database for the entire model:&lt;br /&gt;
:::&#039;&#039;&#039;ModelName&#039;&#039;&#039;_&#039;&#039;&#039;FileVersion&#039;&#039;&#039;.gpkg&lt;br /&gt;
:::&#039;&#039;&#039;M01&#039;&#039;&#039;_&#039;&#039;&#039;001&#039;&#039;&#039;.gpkg&lt;br /&gt;
:* Database for GIS layer (multiple geometry types):&lt;br /&gt;
:::&#039;&#039;&#039;FileTypePrefix&#039;&#039;&#039;_&#039;&#039;&#039;FileDescriptor&#039;&#039;&#039;_&#039;&#039;&#039;FileVersion&#039;&#039;&#039;.gpkg&lt;br /&gt;
:::&#039;&#039;&#039;2d_bc&#039;&#039;&#039;_&#039;&#039;&#039;CreekInflow&#039;&#039;&#039;_&#039;&#039;&#039;001&#039;&#039;&#039;.gpkg&amp;lt;br&amp;gt;&lt;br /&gt;
:* Database for GIS layer (single geometry type):&lt;br /&gt;
:::&#039;&#039;&#039;FileTypePrefix&#039;&#039;&#039;_&#039;&#039;&#039;FileDescriptor&#039;&#039;&#039;_&#039;&#039;&#039;FileVersion&#039;&#039;&#039;_&#039;&#039;&#039;GeometryType&#039;&#039;&#039;.gpkg&lt;br /&gt;
:::&#039;&#039;&#039;2d_bc&#039;&#039;&#039;_&#039;&#039;&#039;CreekInflow&#039;&#039;&#039;_&#039;&#039;&#039;001&#039;&#039;&#039;_&#039;&#039;&#039;L&#039;&#039;&#039;.gpkg&amp;lt;br&amp;gt;&lt;br /&gt;
:* GeoPackage Layer (within a database):&lt;br /&gt;
:::&#039;&#039;&#039;gpkgDatabaseName&#039;&#039;&#039;_&#039;&#039;&#039;GeometryType&#039;&#039;&#039;&lt;br /&gt;
:::2d_bc_CreekInflow_001.gpkg &amp;gt;&amp;gt; &#039;&#039;&#039;2d_bc_CreekInflow&#039;&#039;&#039;_&#039;&#039;&#039;L&#039;&#039;&#039;&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*Shapefile layer:&lt;br /&gt;
:::&#039;&#039;&#039;FileTypePrefix&#039;&#039;&#039;_&#039;&#039;&#039;FileDescriptor&#039;&#039;&#039;_&#039;&#039;&#039;FileVersion&#039;&#039;&#039;_&#039;&#039;&#039;GeometryType&#039;&#039;&#039;.shp&lt;br /&gt;
:::&#039;&#039;&#039;2d_bc&#039;&#039;&#039;_&#039;&#039;&#039;CreekInflow&#039;&#039;&#039;_&#039;&#039;&#039;001&#039;&#039;&#039;_&#039;&#039;&#039;L&#039;&#039;&#039;.shp&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;b&amp;gt;Note:&amp;lt;/b&amp;gt; Only a single geometry type (points, lines or regions) can be included in a shapefile. Thus, for datasets made up of multiple geometries, for example points and lines, two separate files will be required. Therefore, the suggested file naming convention for shapefiles includes the geometry type (P for points, L for lines or R for regions).&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
*MIF formatted layer:&lt;br /&gt;
:::&#039;&#039;&#039;FileTypePrefix&#039;&#039;&#039;_&#039;&#039;&#039;FileDescriptor&#039;&#039;&#039;_&#039;&#039;&#039;FileVersion&#039;&#039;&#039;.mif&lt;br /&gt;
:::&#039;&#039;&#039;2d_bc&#039;&#039;&#039;_&#039;&#039;&#039;CreekInflow&#039;&#039;&#039;_&#039;&#039;&#039;001&#039;&#039;&#039;.mif&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Many iterations of the same input file may be created as the model is developed. A suggested approach for the use of version numbering of input and control files is provided below.&lt;br /&gt;
&lt;br /&gt;
=Control and Input Files – Version Numbering Convention=&lt;br /&gt;
&lt;br /&gt;
The version numbering convention described below is presented as guidance only. Users are free to deviate from that suggested, however, establishing a sound naming and numbering convention is highly recommended throughout the model development. This can aid in quality control, allowing modellers to revert back to an earlier version of the model input if required. &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
Version numbering convention of the TCF control file is particularly important as its name determines the prefix assigned for the results and check files. The TCF is used as the basis for version numbering, following the below convention:&lt;br /&gt;
*Increment the TCF version number sequentially each time a change is made anywhere in the model;&lt;br /&gt;
*If a change is made in a sub-control file such as the TUFLOW Geometry Control File (TGC), Boundary Control File (TBC) or Estry Control File (ECF), then the version number of that sub-control file should be incremented. However, the numbering of these files should be incremented to correspond to the revised TCF version number. Numbering for a given sub-control file is not necessarily sequential;&lt;br /&gt;
*Similarly, if a change is made to any input GIS files listed in any of the control files, then the version number of that input file should be incremented, corresponding to the revised TCF version number. Numbering for a given input file is not necessarily sequential.&lt;br /&gt;
&lt;br /&gt;
Generally, changes are made at the lowest level, i.e. the GIS input. That file, and all files in the hierarchy above it, are given a new version number consistent with the next TCF iteration. This provides an indication of at which point in the model development a GIS layer was introduced. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Each time a new element/s is introduced, the version number of the TCF is incremented. The above convention is demonstrated in the table below, showing file version numbering of input layers corresponding with the overarching control files. Each update is highlighted &#039;&#039;&#039;bold&#039;&#039;&#039;. The table below shows:&lt;br /&gt;
*When a new GIS layer is introduced or amendment made, a  new TCF  is created with the version number iterated up. The GIS layer is assigned the same version number as the TCF;&lt;br /&gt;
*The numbering of input layers doesn’t have to be sequential, as per the development Z shape and the 1d_nwk layers;&lt;br /&gt;
*Modifications can be made in a number of the sub-control files for a given TCF increment, as per Model_005.tcf.&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; width=&amp;quot;100%&amp;quot;&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=8%| TCF&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=8%| TGC&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white&amp;quot; width=15%| TGC Input Layers&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=8%| TBC&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white&amp;quot; width=12%| TBC Input Layers&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=8%| ECF&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white&amp;quot; width=8%| ECF Input Layers&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; | Model Amendments&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | MODEL_001.tcf&lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | MODEL_001.tgc &lt;br /&gt;
|| gis\2d_loc_EG00_001_L.shp&amp;lt;br&amp;gt; gis\2d_code_001_R.shp&amp;lt;br&amp;gt; grid\DEM_2mLidar_01.tif &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | MODEL_001.tbc&lt;br /&gt;
|| gis\2d_bc_EG00_001_L.shp &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &lt;br /&gt;
|| &lt;br /&gt;
|| Construct 2D only model  with base topography.&amp;lt;br&amp;gt; &lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &#039;&#039;&#039;MODEL_002.tcf&#039;&#039;&#039; &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &#039;&#039;&#039;MODEL_002.tgc&#039;&#039;&#039; &lt;br /&gt;
|| gis\2d_loc_EG00_001_L.shp&amp;lt;br&amp;gt; gis\2d_code_001_R.shp&amp;lt;br&amp;gt; grid\DEM_2mLidar_001.tif&amp;lt;br&amp;gt; &#039;&#039;&#039;gis\2d_zsh_Development_002_R.shp&#039;&#039;&#039; &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | MODEL_001.tbc&lt;br /&gt;
|| gis\2d_bc_EG00_001_L.shp &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &lt;br /&gt;
|| &lt;br /&gt;
|| Add topographic  amendments for development.&amp;lt;br&amp;gt; &lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &#039;&#039;&#039;MODEL_003.tcf&#039;&#039;&#039; &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | MODEL_002.tgc&lt;br /&gt;
|| gis\2d_loc_EG00_001_L.shp&amp;lt;br&amp;gt; gis\2d_code_001_R.shp&amp;lt;br&amp;gt; grid\DEM_2mLidar_001.tif&amp;lt;br&amp;gt; gis\2d_zsh_Development_002_R.shp &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | MODEL_001.tbc &lt;br /&gt;
|| gis\2d_bc_EG00_001_L.shp &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &#039;&#039;&#039;MODEL_003.ecf&#039;&#039;&#039; &lt;br /&gt;
|| &#039;&#039;&#039;1d_nwk_Pipes_003.shp&#039;&#039;&#039;&lt;br /&gt;
|| Add 1D elements.&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &#039;&#039;&#039;MODEL_004.tcf &#039;&#039;&#039;&lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | MODEL_002.tgc&lt;br /&gt;
|| gis\2d_loc_EG00_001_L.shp&amp;lt;br&amp;gt; gis\2d_code_001_R.shp&amp;lt;br&amp;gt; grid\DEM_2mLidar_001.tif&amp;lt;br&amp;gt; gis\2d_zsh_Development_002_R.shp &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &#039;&#039;&#039;MODEL_004.tbc&#039;&#039;&#039; &lt;br /&gt;
|| gis\2d_bc_EG00_001_L.shp&amp;lt;br&amp;gt; &#039;&#039;&#039;gis\2d_rf_004_R.shp&#039;&#039;&#039; &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | MODEL_003.ecf&lt;br /&gt;
|| 1d_nwk_003.shp&lt;br /&gt;
|| Add 2D rainfall polygon boundary condition.&amp;lt;br&amp;gt; &lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &#039;&#039;&#039;MODEL_005.tcf&#039;&#039;&#039; &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &#039;&#039;&#039;MODEL_005.tgc&#039;&#039;&#039; &lt;br /&gt;
|| gis\2d_loc_EG00_001_L.shp&amp;lt;br&amp;gt; gis\2d_code_001_R.shp&amp;lt;br&amp;gt; grid\DEM_2mLidar_001.tif&amp;lt;br&amp;gt;&#039;&#039;&#039;gis\2d_zsh_Development_005_R.shp&#039;&#039;&#039;  &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | MODEL_004.tbc &lt;br /&gt;
|| gis\2d_bc_EG00_001_L.shp&amp;lt;br&amp;gt; gis\2d_rf_004_R.shp &lt;br /&gt;
| style=&amp;quot;text-align: center;&amp;quot; | &#039;&#039;&#039;MODEL_005.ecf&#039;&#039;&#039;&lt;br /&gt;
|| &#039;&#039;&#039;1d_nwk_Pipes_005.shp&#039;&#039;&#039;&lt;br /&gt;
|| Make modifications to the original development + update the 1D elements.&amp;lt;br&amp;gt; &lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[TUFLOW_Modelling_Guidance | Back to TUFLOW Modelling Guidance]]&lt;br /&gt;
}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=ArcTUFLOW_Toolbox_and_Toolbar&amp;diff=44445</id>
		<title>ArcTUFLOW Toolbox and Toolbar</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=ArcTUFLOW_Toolbox_and_Toolbar&amp;diff=44445"/>
		<updated>2025-07-16T01:17:56Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Introduction */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Introduction=&lt;br /&gt;
A TUFLOW toolbox is available for ArcMap 10.1 and newer (if you are using ArcGIS Pro, please refer to &amp;lt;u&amp;gt;[[ArcGIS_TUFLOW_Toolbar | ArcGIS Pro TUFLOWToolbar]]&amp;lt;/u&amp;gt;). This toolbox helps with streamlining the process of creating and editing a TUFLOW model in ArcMap. A Toolbar has also been developed to accompany the toolbox to further increase efficiency and workflow. The toolbar shortcuts the opening of the toolbox utilities to a single click on an easily accessible toolbar.&lt;br /&gt;
&lt;br /&gt;
These utilities can be downloaded from the TUFLOW website: &lt;br /&gt;
* [https://www.tuflow.com/downloads/#utilities Download Link]&lt;br /&gt;
&lt;br /&gt;
The download contains both the .esriaddin and the ArcTUFLOW Toolbox. The .esriaddin is a stand alone toolbar add-in to ArcMap and (as suggested) is a stand alone item that does not need to be kept with the other contents of the download. The .tbx is the ArcTUFLOW Toolbox and should be kept with the other folders contained in the download.&lt;br /&gt;
&lt;br /&gt;
=Installation=&lt;br /&gt;
For instructions on how to install ArcTUFLOW Toolbox and Toolbar into ArcMap please see the following link:&lt;br /&gt;
* [[TUFLOW_ArcGIS_Toolbox_and_Toolbar_Installation | How to install ArcTUFLOW Toolbox and Toolbar]]&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=The Utilities: What are they and How to use them=&lt;br /&gt;
&lt;br /&gt;
The ArcTUFLOW Tools are intended to help the user with model initiation, setup and development, running, and checking and viewing results:&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_Toolbox_Toolbar_comb.PNG]]&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=2% | Model Stage&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=10% | Utilities&lt;br /&gt;
|-&lt;br /&gt;
|Start Model Build || 1. [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW (Required Initialization Step)]] &lt;br /&gt;
2. [[#Create_TUFLOW_Folders  | Create TUFLOW Folders]]&amp;lt;br&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|Model Build and Development || 3. [[#Import_Empty_(template)_TUFLOW_Files| Import Empty (template) TUFLOW Files]]&amp;lt;br&amp;gt;&lt;br /&gt;
4. [[#Insert_TUFLOW_Attributes | Insert TUFLOW Attributes]]&amp;lt;br&amp;gt;&lt;br /&gt;
5. [[#Increment_Layer | Increment Layer]]&amp;lt;br&amp;gt;&lt;br /&gt;
6. [[#Style_All_TUFLOW_Layers | Style All TUFLOW Layers]] - Toolbar only&amp;lt;br&amp;gt;&lt;br /&gt;
7. [[#Style_Selected_TUFLOW_Layers | Style Selected TUFLOW Layers]] - Toolbar only&amp;lt;br&amp;gt;&lt;br /&gt;
8. [[#Create_Breakline | Create Breakline]]&amp;lt;br&amp;gt;&lt;br /&gt;
9. [[#Change_Attribute_Data_Type | Change Attribute Data Type]]&amp;lt;br&amp;gt;&lt;br /&gt;
10. [[#Correct_Pipe_Direction | Correct Pipe Direction]]&amp;lt;br&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|Running TUFLOW || 11. [[#Run_TUFLOW_Simulation | Run TUFLOW Simulation]]&amp;lt;br&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|Loading and Viewing Results || 12. [[#Load_Simulation_Input_Files | Load Simulation Input Files]]&amp;lt;br&amp;gt;&lt;br /&gt;
13. [[#Label_Selected_Layer | Label Selected Layer]] - Toolbar only&amp;lt;br&amp;gt;&lt;br /&gt;
14. [[#TUPLOT | TUPLOT]] - Toolbar only&lt;br /&gt;
|-&lt;br /&gt;
|Miscellaneous || 15. [[#About | About]]&lt;br /&gt;
|}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Configure TUFLOW==&lt;br /&gt;
&lt;br /&gt;
The first item, “Configure TUFLOW”, creates a configuration file that will pre-populate items in other ArcTUFLOW tools based on the map document. The steps for running the configuration tool are outlined below:&lt;br /&gt;
* Open or save a map document before running. &lt;br /&gt;
* Select a TUFLOW folder for your model. This can be either the folder that contains the entire TUFLOW model folder structure or the folder that contains the TUFLOW subdirectories. For example, it can be either &amp;quot;D:\projects\Example\TUFLOW&amp;quot; or “D:\projects\Example\”. All of the following tools will use this location.&lt;br /&gt;
* Enter the file path to the TUFLOW executable&lt;br /&gt;
* Select the projection for the TUFLOW model &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:ArcTUFLOW_ConfigureTUFLOW.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Create TUFLOW Folders==&lt;br /&gt;
The tool &amp;quot;Create TUFLOW Folders&amp;quot; will create the standard TUFLOW folder structure and generate empty TUFLOW template files.&lt;br /&gt;
&lt;br /&gt;
This tool is best used if [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW]] has been run prior.&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_CreateTUFLOWFolders.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Import Empty (template) TUFLOW Files==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;Import Empty Template Files&amp;quot; can be used to import new shp files for editing. This tool will automatically delete the dummy &amp;quot;null&amp;quot; entry which otherwise requires manual deletion if an empty file loaded from the catalog.&lt;br /&gt;
*Select the object type (point, line or region)&lt;br /&gt;
*Select the desired template file&lt;br /&gt;
*Specify the run ID for the file. This will be added to the file name as a suffix. &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The ArcTUFLOW toolbox requires configuring prior to using this tool. Refer to [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW]] for more instructions. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:ArcGIS_Utility_007.jpg|400px]]&lt;br /&gt;
&lt;br /&gt;
==Insert TUFLOW Attributes==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;Insert TUFLOW Attributes&amp;quot; will insert a TUFLOW attribute template in front of an existing GIS layer. This is useful when transferring data from a database (e.g. council stormwater network) to TUFLOW format.&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
* Select the input file (the file to have TUFLOW attribues inserted into)&lt;br /&gt;
* Select the TUFLOW file format&lt;br /&gt;
* Specify a run ID for the file. This will be added to the name as a suffix&lt;br /&gt;
&lt;br /&gt;
This tool is best used if [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW]] has been run prior.&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_InsertTUFLOWattributes.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Increment Layer==&lt;br /&gt;
&lt;br /&gt;
The tool &amp;quot;Increment Layer&amp;quot; will increment up one or more TUFLOW layers to a new revision number and replace he existing layer in ArcMAP with the same style. Currently the limitation of the tool requires revision numbers to be 3 digits longs e.g. 001.&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
* Select desired TUFLOW layer to be incremented (these can be dragged and dropped from the TOC into the tool window)&lt;br /&gt;
* Specify the new revision number&lt;br /&gt;
* Choose to supersede the old layers (these will be placed in a &#039;SS&#039; folder in the same directory as the model layer)&lt;br /&gt;
* Choose to append revision number if none already exists&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_IncrementLayer.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Style All TUFLOW Layers==&lt;br /&gt;
&lt;br /&gt;
This button will apply TUFLOW stylings onto all TUFLOW related layers in the TOC.&lt;br /&gt;
&lt;br /&gt;
==Style Selected TUFLOW Layers==&lt;br /&gt;
&lt;br /&gt;
This button will apply TUFLOW stylings to the selected layer in the TOC.&lt;br /&gt;
&lt;br /&gt;
==Create Breakline==&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;Create Breakline&amp;quot; tool will create a 2d_zsh breakline from a user input polyline and DEM. The user has a number of options, such as:&lt;br /&gt;
* Vertice placement along line - the user can specify additional intervals at which to extract elevations, or use only the line vertices&lt;br /&gt;
* Elevation extraction - extract straight from DEM, or use a statistical approach by looking at surrounding elevation values&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
* Specify the input polyline from which a breakline will be created from&lt;br /&gt;
* Select if the user only wants to extract points at a specified chainage (ignore line vertices) - otherwise points will be extracted at defined chainage and vertices&lt;br /&gt;
* Specify an interval at which to insert additional elevation extraction points along line - leave blank to output at line vertices only&lt;br /&gt;
* Specify the underlying DEM to use to for elevation extraction&lt;br /&gt;
* Specify a search radius for considering neighbouring elevation values if using a statistical approach to elevation extraction - leave blank to extract elevation from immediate cell&lt;br /&gt;
* Specify a statistical operation (must be coupled with a search radius). Options include:&lt;br /&gt;
** &#039;MAXIMUM&#039;&lt;br /&gt;
** &#039;MINIMUM&#039;&lt;br /&gt;
** &#039;MEAN&#039;&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_CreateBreakline.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Change Attribute Data Type==&lt;br /&gt;
&lt;br /&gt;
This tool allows you to modify a shapefile attribute (field) type whist keeping the attribute order intact. An example of its use is the modification of the pBlockage attribute in a 1d_nwk layer from &#039;double&#039; to &#039;text&#039; for the new Australian Rainfall and Runoff blockage scenarios. Please note that at present the script only allows for the change of attributes to type text. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Firstly select the &#039;Change Attribute Type Script&#039; from the ArcTUFLOW toolbox. &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Arc_Change_att_tool.JPG|300px]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Populate the tool dialogue and run. You can find help information on the various inputs on the tool info panel.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Arc_Change_att_tool_iface.JPG|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Correct Pipe Direction==&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;Correct Pipe Direction&amp;quot; tool will reverse the direction of all lines within a layer based on the upstream and downstream invert levels. Based on the invert levels, the tool will reverse any line that has an adverse gradient, with the assumption that the line has been digitised in the wrong direction. It will also switch the upstream and downstream invert attributes to correct them after reversing the line direction.&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
* Select an input pipe layer&lt;br /&gt;
* Select the fields which represent the upstream and downstream invert levels&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_CorrectPipeDir.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Run TUFLOW Simulation==&lt;br /&gt;
&lt;br /&gt;
* Enter the simulation tcf reference&lt;br /&gt;
* Define the path to the TUFLOW executable&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The ArcTUFLOW toolbox requires configuring prior to using this tool. Refer to [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW]] for more instructions. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:ArcGIS_Utility_008.jpg|400px]]&lt;br /&gt;
&lt;br /&gt;
==Load Simulation Input Files==&lt;br /&gt;
&lt;br /&gt;
This tool loads all input shp files from a model simulation into a common ArcGIS Map window.&amp;lt;br&amp;gt;&lt;br /&gt;
The user has the option of which files to import from the simulation.&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW ImportSimFiles.PNG]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The shp files will be loaded using a predefined symbology for common TUFLOW input file types. This is determined based on the prefix of the file name. For example, the symbology for 2d_code and 2d_zsh files are shown below.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:arcTUFLOW_Load_Simulation_File_Symbology.JPG|200px]]&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
This tool is courtesy of Wood Rodgers, Inc.  (www.woodrodgers.com)&lt;br /&gt;
&lt;br /&gt;
==Label Selected Layer==&lt;br /&gt;
&lt;br /&gt;
This tool will auto label the selected layer in the TOC. If the selected layer is a TUFLOW layer (e.g. 1d_nwk) the tool will automatically apply an expression, displaying useful information about the layer. It can also be used on non-TUFLOW layers, however will only label the first attribute. The user also has the option of changing the label colour from the adjacent drop down box (default is black if no colour is selected).&lt;br /&gt;
&lt;br /&gt;
This tool is useful for reviewing models as well as building.&lt;br /&gt;
&lt;br /&gt;
==TUPLOT==&lt;br /&gt;
&lt;br /&gt;
TUPLOT is a 1D and 2D time series results viewer. A full description on how to use it is below:&lt;br /&gt;
* [[TUPLOT_External | How to use TUPLOT]]&lt;br /&gt;
&lt;br /&gt;
==About==&lt;br /&gt;
Displays version of ArcTUFLOW.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[ArcGis_Tips | Back to ArcGIS]]}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=ArcTUFLOW_Toolbox_and_Toolbar&amp;diff=44444</id>
		<title>ArcTUFLOW Toolbox and Toolbar</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=ArcTUFLOW_Toolbox_and_Toolbar&amp;diff=44444"/>
		<updated>2025-07-16T01:17:46Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;=Introduction=&lt;br /&gt;
A TUFLOW toolbox is available for ArcMap 10.1 and newer (If you are using ArcGIS Pro, please refer to &amp;lt;u&amp;gt;[[ArcGIS_TUFLOW_Toolbar | ArcGIS Pro TUFLOWToolbar]]&amp;lt;/u&amp;gt;). This toolbox helps with streamlining the process of creating and editing a TUFLOW model in ArcMap. A Toolbar has also been developed to accompany the toolbox to further increase efficiency and workflow. The toolbar shortcuts the opening of the toolbox utilities to a single click on an easily accessible toolbar.&lt;br /&gt;
&lt;br /&gt;
These utilities can be downloaded from the TUFLOW website: &lt;br /&gt;
* [https://www.tuflow.com/downloads/#utilities Download Link]&lt;br /&gt;
&lt;br /&gt;
The download contains both the .esriaddin and the ArcTUFLOW Toolbox. The .esriaddin is a stand alone toolbar add-in to ArcMap and (as suggested) is a stand alone item that does not need to be kept with the other contents of the download. The .tbx is the ArcTUFLOW Toolbox and should be kept with the other folders contained in the download.&lt;br /&gt;
&lt;br /&gt;
=Installation=&lt;br /&gt;
For instructions on how to install ArcTUFLOW Toolbox and Toolbar into ArcMap please see the following link:&lt;br /&gt;
* [[TUFLOW_ArcGIS_Toolbox_and_Toolbar_Installation | How to install ArcTUFLOW Toolbox and Toolbar]]&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=The Utilities: What are they and How to use them=&lt;br /&gt;
&lt;br /&gt;
The ArcTUFLOW Tools are intended to help the user with model initiation, setup and development, running, and checking and viewing results:&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_Toolbox_Toolbar_comb.PNG]]&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=2% | Model Stage&lt;br /&gt;
! style=&amp;quot;background-color:#005581; font-weight:bold; color:white;&amp;quot; width=10% | Utilities&lt;br /&gt;
|-&lt;br /&gt;
|Start Model Build || 1. [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW (Required Initialization Step)]] &lt;br /&gt;
2. [[#Create_TUFLOW_Folders  | Create TUFLOW Folders]]&amp;lt;br&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|Model Build and Development || 3. [[#Import_Empty_(template)_TUFLOW_Files| Import Empty (template) TUFLOW Files]]&amp;lt;br&amp;gt;&lt;br /&gt;
4. [[#Insert_TUFLOW_Attributes | Insert TUFLOW Attributes]]&amp;lt;br&amp;gt;&lt;br /&gt;
5. [[#Increment_Layer | Increment Layer]]&amp;lt;br&amp;gt;&lt;br /&gt;
6. [[#Style_All_TUFLOW_Layers | Style All TUFLOW Layers]] - Toolbar only&amp;lt;br&amp;gt;&lt;br /&gt;
7. [[#Style_Selected_TUFLOW_Layers | Style Selected TUFLOW Layers]] - Toolbar only&amp;lt;br&amp;gt;&lt;br /&gt;
8. [[#Create_Breakline | Create Breakline]]&amp;lt;br&amp;gt;&lt;br /&gt;
9. [[#Change_Attribute_Data_Type | Change Attribute Data Type]]&amp;lt;br&amp;gt;&lt;br /&gt;
10. [[#Correct_Pipe_Direction | Correct Pipe Direction]]&amp;lt;br&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|Running TUFLOW || 11. [[#Run_TUFLOW_Simulation | Run TUFLOW Simulation]]&amp;lt;br&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
|Loading and Viewing Results || 12. [[#Load_Simulation_Input_Files | Load Simulation Input Files]]&amp;lt;br&amp;gt;&lt;br /&gt;
13. [[#Label_Selected_Layer | Label Selected Layer]] - Toolbar only&amp;lt;br&amp;gt;&lt;br /&gt;
14. [[#TUPLOT | TUPLOT]] - Toolbar only&lt;br /&gt;
|-&lt;br /&gt;
|Miscellaneous || 15. [[#About | About]]&lt;br /&gt;
|}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Configure TUFLOW==&lt;br /&gt;
&lt;br /&gt;
The first item, “Configure TUFLOW”, creates a configuration file that will pre-populate items in other ArcTUFLOW tools based on the map document. The steps for running the configuration tool are outlined below:&lt;br /&gt;
* Open or save a map document before running. &lt;br /&gt;
* Select a TUFLOW folder for your model. This can be either the folder that contains the entire TUFLOW model folder structure or the folder that contains the TUFLOW subdirectories. For example, it can be either &amp;quot;D:\projects\Example\TUFLOW&amp;quot; or “D:\projects\Example\”. All of the following tools will use this location.&lt;br /&gt;
* Enter the file path to the TUFLOW executable&lt;br /&gt;
* Select the projection for the TUFLOW model &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:ArcTUFLOW_ConfigureTUFLOW.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Create TUFLOW Folders==&lt;br /&gt;
The tool &amp;quot;Create TUFLOW Folders&amp;quot; will create the standard TUFLOW folder structure and generate empty TUFLOW template files.&lt;br /&gt;
&lt;br /&gt;
This tool is best used if [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW]] has been run prior.&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_CreateTUFLOWFolders.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Import Empty (template) TUFLOW Files==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;Import Empty Template Files&amp;quot; can be used to import new shp files for editing. This tool will automatically delete the dummy &amp;quot;null&amp;quot; entry which otherwise requires manual deletion if an empty file loaded from the catalog.&lt;br /&gt;
*Select the object type (point, line or region)&lt;br /&gt;
*Select the desired template file&lt;br /&gt;
*Specify the run ID for the file. This will be added to the file name as a suffix. &lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The ArcTUFLOW toolbox requires configuring prior to using this tool. Refer to [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW]] for more instructions. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:ArcGIS_Utility_007.jpg|400px]]&lt;br /&gt;
&lt;br /&gt;
==Insert TUFLOW Attributes==&lt;br /&gt;
&lt;br /&gt;
&amp;quot;Insert TUFLOW Attributes&amp;quot; will insert a TUFLOW attribute template in front of an existing GIS layer. This is useful when transferring data from a database (e.g. council stormwater network) to TUFLOW format.&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
* Select the input file (the file to have TUFLOW attribues inserted into)&lt;br /&gt;
* Select the TUFLOW file format&lt;br /&gt;
* Specify a run ID for the file. This will be added to the name as a suffix&lt;br /&gt;
&lt;br /&gt;
This tool is best used if [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW]] has been run prior.&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_InsertTUFLOWattributes.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Increment Layer==&lt;br /&gt;
&lt;br /&gt;
The tool &amp;quot;Increment Layer&amp;quot; will increment up one or more TUFLOW layers to a new revision number and replace he existing layer in ArcMAP with the same style. Currently the limitation of the tool requires revision numbers to be 3 digits longs e.g. 001.&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
* Select desired TUFLOW layer to be incremented (these can be dragged and dropped from the TOC into the tool window)&lt;br /&gt;
* Specify the new revision number&lt;br /&gt;
* Choose to supersede the old layers (these will be placed in a &#039;SS&#039; folder in the same directory as the model layer)&lt;br /&gt;
* Choose to append revision number if none already exists&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_IncrementLayer.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Style All TUFLOW Layers==&lt;br /&gt;
&lt;br /&gt;
This button will apply TUFLOW stylings onto all TUFLOW related layers in the TOC.&lt;br /&gt;
&lt;br /&gt;
==Style Selected TUFLOW Layers==&lt;br /&gt;
&lt;br /&gt;
This button will apply TUFLOW stylings to the selected layer in the TOC.&lt;br /&gt;
&lt;br /&gt;
==Create Breakline==&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;Create Breakline&amp;quot; tool will create a 2d_zsh breakline from a user input polyline and DEM. The user has a number of options, such as:&lt;br /&gt;
* Vertice placement along line - the user can specify additional intervals at which to extract elevations, or use only the line vertices&lt;br /&gt;
* Elevation extraction - extract straight from DEM, or use a statistical approach by looking at surrounding elevation values&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
* Specify the input polyline from which a breakline will be created from&lt;br /&gt;
* Select if the user only wants to extract points at a specified chainage (ignore line vertices) - otherwise points will be extracted at defined chainage and vertices&lt;br /&gt;
* Specify an interval at which to insert additional elevation extraction points along line - leave blank to output at line vertices only&lt;br /&gt;
* Specify the underlying DEM to use to for elevation extraction&lt;br /&gt;
* Specify a search radius for considering neighbouring elevation values if using a statistical approach to elevation extraction - leave blank to extract elevation from immediate cell&lt;br /&gt;
* Specify a statistical operation (must be coupled with a search radius). Options include:&lt;br /&gt;
** &#039;MAXIMUM&#039;&lt;br /&gt;
** &#039;MINIMUM&#039;&lt;br /&gt;
** &#039;MEAN&#039;&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_CreateBreakline.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Change Attribute Data Type==&lt;br /&gt;
&lt;br /&gt;
This tool allows you to modify a shapefile attribute (field) type whist keeping the attribute order intact. An example of its use is the modification of the pBlockage attribute in a 1d_nwk layer from &#039;double&#039; to &#039;text&#039; for the new Australian Rainfall and Runoff blockage scenarios. Please note that at present the script only allows for the change of attributes to type text. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;li&amp;gt;Firstly select the &#039;Change Attribute Type Script&#039; from the ArcTUFLOW toolbox. &amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Arc_Change_att_tool.JPG|300px]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Populate the tool dialogue and run. You can find help information on the various inputs on the tool info panel.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:Arc_Change_att_tool_iface.JPG|600px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Correct Pipe Direction==&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;Correct Pipe Direction&amp;quot; tool will reverse the direction of all lines within a layer based on the upstream and downstream invert levels. Based on the invert levels, the tool will reverse any line that has an adverse gradient, with the assumption that the line has been digitised in the wrong direction. It will also switch the upstream and downstream invert attributes to correct them after reversing the line direction.&lt;br /&gt;
&lt;br /&gt;
The steps are:&lt;br /&gt;
* Select an input pipe layer&lt;br /&gt;
* Select the fields which represent the upstream and downstream invert levels&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW_CorrectPipeDir.PNG]]&lt;br /&gt;
&lt;br /&gt;
==Run TUFLOW Simulation==&lt;br /&gt;
&lt;br /&gt;
* Enter the simulation tcf reference&lt;br /&gt;
* Define the path to the TUFLOW executable&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The ArcTUFLOW toolbox requires configuring prior to using this tool. Refer to [[ArcTUFLOW_Configure_TUFLOW | Configure TUFLOW]] for more instructions. &amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:ArcGIS_Utility_008.jpg|400px]]&lt;br /&gt;
&lt;br /&gt;
==Load Simulation Input Files==&lt;br /&gt;
&lt;br /&gt;
This tool loads all input shp files from a model simulation into a common ArcGIS Map window.&amp;lt;br&amp;gt;&lt;br /&gt;
The user has the option of which files to import from the simulation.&lt;br /&gt;
&lt;br /&gt;
[[File: ArcTUFLOW ImportSimFiles.PNG]]&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
The shp files will be loaded using a predefined symbology for common TUFLOW input file types. This is determined based on the prefix of the file name. For example, the symbology for 2d_code and 2d_zsh files are shown below.&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
[[File:arcTUFLOW_Load_Simulation_File_Symbology.JPG|200px]]&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
This tool is courtesy of Wood Rodgers, Inc.  (www.woodrodgers.com)&lt;br /&gt;
&lt;br /&gt;
==Label Selected Layer==&lt;br /&gt;
&lt;br /&gt;
This tool will auto label the selected layer in the TOC. If the selected layer is a TUFLOW layer (e.g. 1d_nwk) the tool will automatically apply an expression, displaying useful information about the layer. It can also be used on non-TUFLOW layers, however will only label the first attribute. The user also has the option of changing the label colour from the adjacent drop down box (default is black if no colour is selected).&lt;br /&gt;
&lt;br /&gt;
This tool is useful for reviewing models as well as building.&lt;br /&gt;
&lt;br /&gt;
==TUPLOT==&lt;br /&gt;
&lt;br /&gt;
TUPLOT is a 1D and 2D time series results viewer. A full description on how to use it is below:&lt;br /&gt;
* [[TUPLOT_External | How to use TUPLOT]]&lt;br /&gt;
&lt;br /&gt;
==About==&lt;br /&gt;
Displays version of ArcTUFLOW.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[ArcGis_Tips | Back to ArcGIS]]}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=MiTools_Tips&amp;diff=44443</id>
		<title>MiTools Tips</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=MiTools_Tips&amp;diff=44443"/>
		<updated>2025-07-16T01:08:50Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Description */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;= Description =&lt;br /&gt;
MapInfo and TUFLOW Productivity Utilities (miTools) is a MapInfo add-on that is available for download from the &amp;lt;u&amp;gt;[https://www.tuflow.com/downloads/#gis_tools TUFLOW website]&amp;lt;/u&amp;gt;. MiTools have been developed specifically to improve the efficiency of setting up and reviewing TUFLOW models, as well as improving the day to day ease of using MapInfo Professional (MI Pro). The suite of utilities enables ‘automation’ of many of the common repetitive tasks, saving valuable time and therefore money. The utilities also allow the efficient creation and visualisation of key TUFLOW model inputs/outputs within the MapInfo environment. Other tools provide data checking and quality assurance functionality, thus helping to minimise modeling errors.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
[[File: miTools_001.JPG]]&lt;br /&gt;
[[File: miTools_000.JPG|350px]]&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== General MapInfo Capabilities ==&lt;br /&gt;
* Efficiently manipulate MapInfo’s Layer Control without having to scroll through countless layers. Based on selected object(s), switch the layer on, make it editable, make it non-selectable, close it or open the table in a browser window. Filter the Layer Control to remove unused layers and/or close unused tables and/or delete selected objects without having to make then layer editable.&lt;br /&gt;
* Batch import MID/MIF files and automatically add them to Layer Control &lt;br /&gt;
* Import a MID/MIF file and automatically add it to the Layer Control as the top-layer and set it to editable. If it is a TUFLOW layer, apply the user defined default object styles&lt;br /&gt;
* Batch export MID/MIF files, as well as prompt for packing, saving edits, etc.&lt;br /&gt;
&lt;br /&gt;
== Other Capabilities ==&lt;br /&gt;
* A cross-section editor to view and edit CSV format cross-sections. The utility includes a data management tool that tracks changes to the cross-section properties, as well saving backup files following each subsequent change.&lt;br /&gt;
* A range of Flood Modeller-TUFLOW related utilities (especially for UK customers) including a utility to extract cross-sections from an Flood Modeller DAT format file into individual ESTRY format CSV files and a utility to name Flood Modeller 1d_nwk channels the same as the upstream node ID.&lt;br /&gt;
&lt;br /&gt;
== TUFLOW Capabilities ==&lt;br /&gt;
* MapInfo interfaces for common TUFLOW utilities TUFLOW_to_GIS and ASC_to_ASC.&lt;br /&gt;
* MapInfo interface to run TUFLOW, create and run TUFLOW batch files, and to test and package models.&lt;br /&gt;
* Automatically apply predefined MapInfo object styles to TUFLOW layers.&lt;br /&gt;
* Enhanced single and batch MIF import and export utilities.&lt;br /&gt;
* Automatically create and trim TUFLOW Water Level Lines(WLL), as well as cross-section (XS) lines. &lt;br /&gt;
* Extract multiple TUFLOW CSV format cross-sections from a Vertical Mapper DEM, and automatically assign roughness’s from a materials or Manning’s table.&lt;br /&gt;
* CSV Cross-section editor with inbuilt version and edit tracking.&lt;br /&gt;
* Automatically draw, attribute and snap TUFLOW CN Lines.&lt;br /&gt;
* Batch split a polyline, such as a river centreline, using a table of cross-sections. The utility is extremely useful for quickly setting up 1d networks where existing cross-section and river centreline/long-section data are available.&lt;br /&gt;
* Graph the TUFLOW MID/MIF time-series (TS) results data for selected TS objects within MapInfo. Summarise the maximum and minimum of the saved TS values for the active TS Graph window. Filter the graphs - i.e. to display only a sub-set of all the TS objects selected, such as the flows (Q) only.&lt;br /&gt;
* Plot TUFLOW CSV format cross-sections within MapInfo. Include TUFLOW water level results if required.&lt;br /&gt;
* Create long-section plots within MapInfo. Plot pipe obvert levels, minimum cover levels and highlight pits where the outlet level is higher than the lowest inlet(s), i.e. an error in the data.&lt;br /&gt;
* Region/polygon editing tools to speed up snapping, trimming and splitting region objects while also ensuring the resulting objects are truly snapped together.&lt;br /&gt;
* ‘Increment’ the selected TUFLOW layer: The utility assists to ensure TUFLOW MI layers are correctly renamed and setup for editing in an efficient manner.&lt;br /&gt;
* Label selected TUFLOW layer with associated elevation or invert data, to user specified formats with the click of a single button. The user can customise the number ofdecimal places displayed, the label styles (colour, options, size, font), as well as the visibility options for the labels (eg the zoom display range).&lt;br /&gt;
* Filter TUFLOW layers: a utility to assist in dealing with large and complicated TUFLOW models. The utility will turn on or a specific layer types, as well as DEMs and images. The utility also has an option to group and sort TUFLOW layers in the current map window, based on the file type order specified in a customisable .ini file.&lt;br /&gt;
* Quickly turn on the borders of thematically mapped grid cells.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{{Tips Navigation&lt;br /&gt;
|uplink=[[MapInfo_Tips | Back to MapInfo Tips]]}}&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44436</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44436"/>
		<updated>2025-07-15T02:04:09Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Using PowerShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path, use single quotations around the entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run_TUFLOW_simulations.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_Edited.mp4|width=850}}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A Windows batch file can also be used to execute a PowerShell script, avoiding the need to work in the PowerShell command line.&lt;br /&gt;
* Create a text file with a *.bat file extension, saved in your TUFLOW\runs folder (alongside your TCF)&lt;br /&gt;
* Add the following syntax to the batch file (if your ps1 file uses a different name, specify it instead of run_TUFLOW_simulations.ps1): &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
@powershell -File .\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Double left mouse click the batch file from Window Explorer to execute the batch file that calls the PowerShell script&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppress the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, where TUFLOW runs a simulation for all combinations of scenarios and events.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the simulation TLF or _ TUFLOW Simulations.log) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44435</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44435"/>
		<updated>2025-07-15T02:03:51Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Using PowerShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path, use single quotations around the entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run_TUFLOW_simulations.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_Edited.mp4|width=850}}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A Windows batch file can also be used to execute a PowerShell script, avoiding the need to work in the PowerShell command line.&lt;br /&gt;
* Create a text file with a *.bat file extension, saved in your TUFLOW\runs folder (alongside your TCF)&lt;br /&gt;
* Add the following syntax to the batch file (if your ps1 file uses a different name, specify it instead of run_TUFLOW_simulations.ps1): &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
@powershell -File .\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Double left mouse click the batch file from Window Explorer to execute the batch file that calls the PowerShell script&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppress the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, where TUFLOW runs a simulation for all combinations of scenarios and events.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the simulation TLF or _ TUFLOW Simulations.log) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44434</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44434"/>
		<updated>2025-07-15T02:03:00Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Using PowerShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path, use single quotations around the entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run_TUFLOW_simulations.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_Edited.mp4|width=850}}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A Windows batch file can also be used to execute a PowerShell script, avoiding the need to work in the PowerShell command line.&lt;br /&gt;
* Create a text file with a *.bat file extension, saved in your TUFLOW\runs folder (alongside your TCF)&lt;br /&gt;
* Add the following syntax to the batch file: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
@powershell -File .\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Double left mouse click the batch file from Window Explorer to execute the batch file that calls the PowerShell script&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppress the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, where TUFLOW runs a simulation for all combinations of scenarios and events.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the simulation TLF or _ TUFLOW Simulations.log) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44433</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44433"/>
		<updated>2025-07-15T02:02:38Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Using PowerShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path, use single quotations around the entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run_TUFLOW_simulations.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_Edited.mp4|width=850}}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A Windows batch file can also be used to execute a PowerShell script, avoiding the need to work in the PowerShell command line.&lt;br /&gt;
* Create a text file with a *.bat file extension, saved in your TUFLOW/runs folder (alongside your TCF)&lt;br /&gt;
* Add the following syntax to the batch file: &lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
@powershell -File .\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
* Double left mouse click the batch file from Window Explorer to execute the batch file that calls the PowerShell script&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppress the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, where TUFLOW runs a simulation for all combinations of scenarios and events.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the simulation TLF or _ TUFLOW Simulations.log) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44432</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44432"/>
		<updated>2025-07-15T01:59:22Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Using PowerShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path, use single quotations around the entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run_TUFLOW_simulations.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_Edited.mp4|width=850}}&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
A Windows batch file can also be used to execute a PowerShell script, avoiding the need to work in the PowerShell command line.&lt;br /&gt;
* Create a text file with a *.bat file extension&lt;br /&gt;
* Add the following syntax to the batch file: &amp;quot;@powershell -File .\run_TUFLOW_simulations.ps1&amp;quot;&lt;br /&gt;
* Double left mouse click the batch file from Window Explorer to execute the batch file that calls the PowerShell script&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppress the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, where TUFLOW runs a simulation for all combinations of scenarios and events.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the simulation TLF or _ TUFLOW Simulations.log) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44227</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44227"/>
		<updated>2025-06-30T02:56:28Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Using PowerShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path, use single quotations around the entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run_TUFLOW_simulations.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_Edited.mp4|width=850}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppresses the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -x -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, so that TUFLOW runs a simulation for all combinations of scenario and event.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the simulation TLF or _ TUFLOW Simulations.log) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44226</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44226"/>
		<updated>2025-06-29T23:39:55Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Email Notifications */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path, use single quotations around the entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_Edited.mp4|width=850}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppresses the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -x -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, so that TUFLOW runs a simulation for all combinations of scenario and event.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the simulation TLF or _ TUFLOW Simulations.log) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44225</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44225"/>
		<updated>2025-06-29T23:38:28Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Using PowerShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path, use single quotations around the entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_Edited.mp4|width=850}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppresses the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -x -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, so that TUFLOW runs a simulation for all combinations of scenario and event.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the TLF) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44224</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44224"/>
		<updated>2025-06-29T23:38:13Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Using PowerShell */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path, use single quotations around entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_Edited.mp4|width=850}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppresses the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -x -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, so that TUFLOW runs a simulation for all combinations of scenario and event.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the TLF) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44196</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44196"/>
		<updated>2025-06-27T01:53:11Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Adding Switches */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path use single quotations around entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_002.mp4|width=1350}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppresses the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -x -s1 5m -s2 D01 model_~s1~_~s2~_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, so that TUFLOW runs a simulation for all combinations of scenario and event.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the TLF) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44195</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44195"/>
		<updated>2025-06-27T01:46:30Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Adding Switches */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path use single quotations around entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_002.mp4|width=1350}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppresses the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -x -s1 5m -s2 D01 &#039;model_~s1~_~s2~_001.tcf&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, so that TUFLOW runs a simulation for all combinations of scenario and event.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the TLF) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
	<entry>
		<id>https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44194</id>
		<title>Run TUFLOW From PowerShell</title>
		<link rel="alternate" type="text/html" href="https://wiki.tuflow.com/w/index.php?title=Run_TUFLOW_From_PowerShell&amp;diff=44194"/>
		<updated>2025-06-27T01:44:50Z</updated>

		<summary type="html">&lt;p&gt;Chris Huxley: /* Looping */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;PowerShell is a modern scripting language and command interpreter for Windows that can be used as an alternative to more traditional batch files.&lt;br /&gt;
When creating a PowerShell script to run TUFLOW, much of the functionality will be similar to batch files, but PowerShell offers some additional benefits such as a more modern syntax and the ability to better interact with other features of the Windows operating system. Perhaps one of the most useful features would be the ability to send an email once a TUFLOW simulation has finished. This would allow, for example, a script running a TUFLOW simulation on a server to inform a user on their own computer that a simulation has finished, and details of that simulation to be sent within the email too.&lt;br /&gt;
&lt;br /&gt;
Unlike batch files, a PowerShell script will not run by default when double clicking it in File Explorer. Instead, a user can run the PowerShell script via the command line, for example by searching and opening “PowerShell” from the Windows start menu.&lt;br /&gt;
&lt;br /&gt;
A PowerShell script can be created in a similar way to a batch file. For example, right click in File Explorer, then click New &amp;gt; Text Document, and then provide a file name and extension (.ps1 for PowerShell). Alternatively, when using the [[Create_TUFLOW_Project|Create TUFLOW Project Tool in QGIS]], a PowerShell script is automatically generated in addition to a batch file.&lt;br /&gt;
&lt;br /&gt;
=Using PowerShell=&lt;br /&gt;
Open Windows PowerShell from the Windows start menu. When running a script via the PowerShell command line, the current working directory should typically be set to the same directory as the location of the script and TCF file. To change the current working directory, use the “cd” command. If there are spaces in your folder path use single quotations around entry (&#039; &#039;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
cd &#039;&amp;lt;Path-to-Tuflow-Runs-Folder&amp;gt;&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Assuming the PowerShell script filename is run.ps1, this can be run from the PowerShell command line with this command:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
.\run_TUFLOW_simulations.ps1&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Video|name=TUFLOW Run_002.mp4|width=1350}}&amp;lt;br&amp;gt;&lt;br /&gt;
&amp;lt;br&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Simple Example=&lt;br /&gt;
&lt;br /&gt;
A simple PowerShell script to run a single simulation is as follows:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If there are spaces in your executable path, use single quotations around the executable entry (&#039; &#039;) and prefix the reference with &amp;amp;. For example:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
&amp;amp; &#039;C:\bin\TUFLOW Example\2025.0.3\TUFLOW_iSP_w64.exe&#039; model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Multiple Simulations=&lt;br /&gt;
Running multiple simulations in series can be handled by adding new lines to run.ps1. Use a –b (batch) switch to suppresses the need to press the return key at the end of each simulation:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_001.tcf&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b model_002.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Adding Switches=&lt;br /&gt;
To alter the behaviour of TUFLOW, switches can be used in the same way as a batch file (see &amp;lt;u&amp;gt;[[Run_TUFLOW_From_a_Batch-file#TUFLOW_switches_in_a_batch_file | Batch File Switches]]&amp;lt;/u&amp;gt;):&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -t model_001.tcf&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When specifying a tcf file that includes scenarios and/or events within the filename use single quotations around the tcf file reference (&#039; &#039;).&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -x -s1 5m -s2 D01 &#039;model_~s1~_~s2~_001.tcf&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This example demonstrates how to package a copy of a project milestone model (including all possible scenario and event inputs) for archiving:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -pmAll -xf0 -s1 5m -s2 D01 -e1 Q100 -e2 2hr &#039;model_~s1~_~s2~_~e1~_~e2~_001.tcf&#039;&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Looping=&lt;br /&gt;
Looping is undertaken in a similar way to batch files. The following PowerShell script contains a nested loop, so that TUFLOW runs a simulation for all combinations of scenario and event.&lt;br /&gt;
Comments can be added using #.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
#TUFLOW RUN VARIABLES&lt;br /&gt;
$scenarios = @(&amp;quot;1m&amp;quot;, &amp;quot;2m&amp;quot;, &amp;quot;5m&amp;quot;)&lt;br /&gt;
$events = @(&amp;quot;1hr&amp;quot;, &amp;quot;2hr&amp;quot;, &amp;quot;5hr&amp;quot;)&lt;br /&gt;
&lt;br /&gt;
#SIMULATION EXECUTION LOOP&lt;br /&gt;
foreach ($scenario in $scenarios){&lt;br /&gt;
    foreach ($event in $events){&lt;br /&gt;
        C:\bin\TUFLOW\2025.0.3\TUFLOW_iSP_w64.exe -b -s1 $scenario -e1 $event model_~s1~_~e1~.tcf&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=Email Notifications=&lt;br /&gt;
An email can be sent using PowerShell to inform the user that a TUFLOW run has completed (successfully or otherwise). The following approach requires that Outlook is already set up on the computer running TUFLOW:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Outlook = New-Object -ComObject Outlook.Application&lt;br /&gt;
$Mail = $Outlook.CreateItem(0)&lt;br /&gt;
$Mail.Subject = &amp;quot;TUFLOW Simulation Finished&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;first_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.To = &amp;quot;second_recipient_email_address_here&amp;quot;&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
It is also possible to send the contents of a log file (for example, the TLF) as the body of the email. To do this, you must pre-empt the name and path of the TLF file that will be produced:&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
$Mail.Body = Get-Content -Raw .\log\model_001.tlf&lt;br /&gt;
$Mail.Send()&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;/div&gt;</summary>
		<author><name>Chris Huxley</name></author>
	</entry>
</feed>