# Path: topoflow/framework/time_interpolation.py
# class time_interp_data():
# class time_interpolator():
#     def __init__( self, v1=None, t1=None, long_var_name=None ):
#     def update( self, v2=None, t2=None ):
#     def __init__( self, comp_set, comp_names, vars_provided,
#                   method='Linear' ):
#     def initialize( self ):
#     def update2( self, comp_name ):
#     def update_all( self, time ):
#     def get_values( self, long_var_name, comp_name, time ):
#     def convert_time_units( self, in_time, in_units ):
#         DEBUG = False


import numpy as np
import os
import time
import xml.dom.minidom
import sys    #### for testing
from topoflow.framework import time_interpolation    # (time_interpolator class)
        # (2/18/13) Previous version of framework class initialized
        # and then connected the components in the comp_set using
        # embedded references.  In this version we will call a
        # "get_required_vars()" method within the time loop, which
        # will in turn call the get_values() and set_values()
        # methods.  But we still need to initialize the comp set.
        #------------------------------------------------------------
        ## OK = self.initialize_comp_set( REPORT=True )
        OK = self.initialize_comp_set( REPORT=False )
        if not(OK):
            return
        
        #---------------------------------------
        # Set mode of the driver component.
        # Note: Must happen before next block.
        #---------------------------------------
        driver = self.comp_set[ driver_comp_name ]
        driver.mode = 'driver'
        print 'Driver component name =', driver_comp_name
        print ' '
        
        #-----------------------------------
        # Initialize all time-related vars
        #-----------------------------------
        self.initialize_time_vars()
        self.initialize_framework_dt()

        #------------------------------------
        # Instantiate a "time_interpolator"
        #------------------------------------

# Path: topoflow/framework/time_interpolation.py
# class time_interp_data():
# class time_interpolator():
#     def __init__( self, v1=None, t1=None, long_var_name=None ):
#     def update( self, v2=None, t2=None ):
#     def __init__( self, comp_set, comp_names, vars_provided,
#                   method='Linear' ):
#     def initialize( self ):
#     def update2( self, comp_name ):
#     def update_all( self, time ):
#     def get_values( self, long_var_name, comp_name, time ):
#     def convert_time_units( self, in_time, in_units ):
#         DEBUG = False


# Path: topoflow/framework/emeli.py
import numpy as np
import os
import time
import xml.dom.minidom
import sys    #### for testing
from topoflow.framework import time_interpolation    # (time_interpolator class)

        # (2/18/13) Previous version of framework class initialized
        # and then connected the components in the comp_set using
        # embedded references.  In this version we will call a
        # "get_required_vars()" method within the time loop, which
        # will in turn call the get_values() and set_values()
        # methods.  But we still need to initialize the comp set.
        #------------------------------------------------------------
        ## OK = self.initialize_comp_set( REPORT=True )
        OK = self.initialize_comp_set( REPORT=False )
        if not(OK):
            return
        
        #---------------------------------------
        # Set mode of the driver component.
        # Note: Must happen before next block.
        #---------------------------------------
        driver = self.comp_set[ driver_comp_name ]
        driver.mode = 'driver'
        print 'Driver component name =', driver_comp_name
        print ' '
        
        #-----------------------------------
        # Initialize all time-related vars
        #-----------------------------------
        self.initialize_time_vars()
        self.initialize_framework_dt()

        #------------------------------------
        # Instantiate a "time_interpolator"
        #------------------------------------

        time_interpolator = time_interpolation.time_interpolator(