csdms / pymt

A Python toolkit for running and coupling Earth surface models
https://csdms.colorado.edu/wiki/PyMT
MIT License
51 stars 19 forks source link

Add ModelCollection #128

Closed mcflugen closed 3 years ago

mcflugen commented 3 years ago

This pull request introduces a new class, ModelCollection, and an instance of that class, pymt.MODELS to hold the loaded models. This is similar to the pymt.models module but MODELS is a dict-like object of the loaded models, which allows a user to more easily see what models are available and to programmatically iterate over them. Models can be accessed either through properties (i.e. MODELS.Child) or dict-style (i.e. MODELS["Child"]).