pytuflow.TCFRunState

pytuflow.TCFRunState#

class TCFRunState(build_state, context, parent)#

Bases: ControlFileRunState, TCFBase

Class for storing the run state of a TCF file.

This class should not be instantiated directly, but rather it should be created from an instance of a BuildState class using the context() method of the BuildState class.

Parameters:
  • build_state (TCF) – The TCF build state instance that the RunState object is based on.

  • context (Context) – The context instance that will be used to resolve the build state.

  • parent (ControlFileRunState) – The parent control file run state.

__init__(build_state, context, parent)#
Parameters:
  • build_state (BuildState) – The BuildState object that the RunState object is based on.

  • context (Context) – The context object that the RunState object is based on.

  • parent (ControlFile) – The parent control file.

Methods

bc_dbase

Returns the model's BCDatabaseRunState instance.

context

Returns the ScopeList that makes up the objects Context for the given RunState Object.

ecf

Returns the model's ECF ControlFileRunState instance.

event_database

Returns the EventDatabase object.

find_input

Find a particular input(s) using a search filter.

input

Returns the input with the given UUID.

log_folder_path

Returns the log folder path.

mat_file

Returns the model's MatDatabaseRunState instance.

output_folder_1d

Returns the 1D output folder.

output_folder_2d

Returns the 2D output folder.

output_name

Returns the file name of the result file without any extension.

rainfall_dbase

Returns the model's rainfall database instance.

run

Run the control file in context using the specified TUFLOW binary.

soils_file

Returns the model's SoilDatabase instance.

tbc

Returns the model's TBC ControlFileRunState instance.

tef

Returns the model's TEFRunState instance.

test

Run the control file in context using the specified TUFLOW binary in test mode.

tgc

Returns the model's TGC ControlFileRunState instance.

tlf_path

Returns the path to the expected tlf file.

tpc

Returns the TPC result from the simulation.

tpc_path

Returns the path to the expected tpc file.

tscf

Returns the model's TSCF ControlFileRunState instance.

Attributes

TUFLOW_TYPE

Return the TUFLOW type of the input.

scope

List of scopes associated with the object.

tcf

The parent TCF control file object

bs

the BuildState object that the RunState object is based on.

proc

the process that is running the TUFLOW simulation.

parent

the parent control file

fpath

the path to the control file

config

the configuration settings for the model.

inputs

list of inputs and comments in the control file

loaded

whether the control file has been loaded from disk or not.

ctx

the context object that the RunState object is based on.