[Numpy-discussion] design patterns for computing
Alan G Isaac
aisaac at american.edu
Wed Oct 17 11:36:25 EDT 2007
It sounds to me like you have something closer to the
following.
class Problem
- initialized with an Input instance and an Analysis instance
- has a ``get_results`` method that asks the Analysis instance to
- call ``get_input`` on Input instance
- run analysis on the provided input
- create and return and instance of a Results class
Instances of the Input class can then produce input anyway
you like---e.g., as data containers or as data fetchers---as
long as they provide it in a standard format
in response to ``get_input``.
fwiw,
Alan Isaac
More information about the NumPy-Discussion
mailing list