Landlab Framework#
Submodules#
landlab.framework.component module#
Utility functions for loading components for The Landlab.
- iscomponent(value, cls)[source]#
Check if value is a component for The Landlab. value is a component if it implements the cls or it is an instance of cls.
Returns
True
if value is a component, otherwiseFalse
.
- load_components(cls, paths=None)[source]#
Load components from a series of directories.
Components found earlier in the search path order override those discovered later. Use the paths keyword to specify a list of paths to search for components.
See also
- load_components_from_dir(path, cls)[source]#
Look for components for Landlab in path.
Identify components as being an instance of cls. Returns a dictionary of discovered component names as keys and component classes as values.
- load_landlab_components(paths=None)[source]#
Load components for The Landlab. These are classes that implement BmiBase. See
load_components_from_dir
for the meaning of paths keyword.See also
landlab.framework.decorators module#
Decorators for TheLandlab package.
- camel_case(text, sep=None)[source]#
Convert to camel case.
Convert text to camel case. Use the sep keyword to specify the word separator. The default is to split on whitespace.
>>> from landlab.framework.decorators import camel_case >>> camel_case("eric idle") 'EricIdle' >>> camel_case("terry_gilliam", sep="_") 'TerryGilliam' >>> camel_case("MONTY Python") 'MONTYPython' >>> camel_case("GrahamChapman") 'GrahamChapman'
landlab.framework.interfaces module#
The Basic Modeling Interface.
- exception BadVarNameError(name)[source]#
Bases:
Error
Exception to indicate a bad input/output variable name.
- class BmiBase[source]#
Bases:
object
Definition of the Basic Modeling Interface.
- get_input_var_names()[source]#
Get names of input variables to the model as standard names.
- Returns:
A list of input standard names as strings
- class BmiGridType(code, name)[source]#
Bases:
int
Base type to indicate the type of a BMI model’s grid.
- Code:
Grid type code as an int
- Name:
Name of the grid type as a string
- class BmiUniformRectilinear[source]#
Bases:
object
BMI for a model that exposes a uniform rectilinear grid.
- exception FatalError[source]#
Bases:
Exception
Raise this exception if an unrecoverable error was found.
Module contents#
The Landlab modeling framework.