Note: This is documentation for version 5.4 of Source. For a different version of Source, select the relevant space by using the Spaces menu in the toolbar above

SourcePlugin.SWATCustomAutoAssignInputs

This plugin has been designed to modify the Data Transfer Tool (DTT) converted SWAT outputs, such as Flow, SLOAD, ORGNLOAD, ORGPLOAD (tons,kg) to a concentration which can then be imported into 'eWater Source'.

Example workflow:

Preparing the data with the DTT

Set SWAT as the source application and eWater_Source as the destination application and pointing it to your desired file locations and choose 'Next >>'. I have attached an example output.sub and screenshot below illustrating the configuration.

In the screenshot below you will see it has loaded up all the available time series from the input SWAT file we selected before. Pay attention to the 'Feature' and 'Parameter' columns in the top section.

In the screenshot below I have selected Parameter's: Flow, SLOAD and ORGNLOAD for Feature: 1 and 2 and clicked 'Add to destination'

In the screenshot below I have checked the box update empty destination sitename to source sitename and clicked update. In 'eWater_Source' Node name refers to sitename and the Recorder name refers to parameter.You can set the Node name to anything, as long as it matches the Node name of the other parameters(reco that you wish to be combined into a concentration.

Note: In order for our plugin to be able to convert our 'LOAD's to a concentration, we need to export each the data into a res.csv file with the mapped 'LOAD'(e.g. ORGNLOAD and SLOAD) and corresponding 'Flow' timeseries. So to make sure our plugin can find a match, we need to make sure the corresponding flow and load time series have matching Node name's.

You  can save these configurations for future use by clicking the "save csv node link list'. I have attached an example dttnodelink.csv

I have attached an example of what the exported multiple inputs.res.csv file should look like.

Running the Plugin

Open Source (only version 3.8.15.3269 and above will work),

Tools > Plugin manager add the plugin: 'SourcePlugin.SWATCustomAutoAssignInputs'

Create or load an existing project.

Tools > Plugins > SourcePlugin.SWATCustomAutoAssignInputs > SWAT Custom Auto Assign Inputs

You should see the dialog as shown in the screenshot below

Change the textbox to the path of your desired inputs.res.csv file which will contain data as prepared in the steps above.

Simply click 'Load concentrations' and you will see the concentrations added to DataSources as illustrated in the screenshot below.

After 'Loading concentrations' you should notice an output.res.csv file which contains this converted data in the same folder as the specified inputs.res.csv file.