DMIs to Import and Export Data
The Data Management Interface (DMI) can be used to import or export data from a model to an external data repository or database. There are two types of DMIs:
• Control File/Executable. Provide a link to any external database or repository
• Database DMIs. Provide an automated connection to HEC‑DSS and HDB.
The USACE‑SWD uses DSS as it data repository, so this section will focus on the use of the Database DMI connection to DSS. In USACE‑SWD models, DMIs are used to import the following:
• Table and scalar data used to define the model
• Initial values
• Time series data representing uncontrolled area flows, evaporation, power demands, etc.
• Observed or existing data used for comparison
After a run is made, DMIs are used to export data to the DSS file to store the results of the run. The following section provides links to the DMI interface, the utility to record invocations of each DMI and then clear the values set by the DMI, and documentation on the interaction of RiverWare and CWMS.
Database DMI-DSS Interface
The Database DMI interface allows the user to configure Name Maps and Datasets, and then define a Database DMI that uses them. See
Database DMI Overview in Data Management Interface (DMI) for details on the database DMI interface.
DMI Invocations and Clearing Input DMI Values
The USACE‑SWD uses DMIs to bring large volumes of table and series data into the model. Frequently, a previously developed model will be used for a study, but all of the data will be replaced with new data. To prevent using any of the previous data, a utility was developed to allow the user to clear out values set by a DMI. This utility has two parts, recording an invocation of the DMI and then clearing values set during that invocation. Following is an overview of the process a user would take. See
DMI Invocation Manager Dialog in Data Management Interface (DMI) for details on this utility.
1. Within the DMI manager, the user configures that an input DMI should record invocations. With this toggle enabled, the DMI will record every time the DMI is invoked and the slots set.
2. The user executes the input DMI and the invocation is recorded. Also, with invocations enabled, all of the data that is set is given the “Z” flag instead of the “I” flag.
Note: The Z flag behaves identically to the I flag.The user then performs the run as usual.
3. When the user decides that they want to start a new study with new data, the user opens the Invocation Manager and selects the appropriate invocation. The user then selects the Edit, then Clear Selected Values menu and any data that was set by that DMI is cleared out (i.e. set to NaN).
4. In this way, the user can go through all of the input DMIs and clear out any value that was set by a DMI.
To summarize, to clear out all imported data in the model, the user should make sure that all DMIs have the Record Invocations toggle enabled. Then, when it is time to clear out the data the Invocation Manager can be used.