The use of the Model() class as both input and output is a bit confusing, because at the moment certain attributes (such as grid) only work if the model is input or output, so it would be better to distinguish between model input and model output. One possibility is to have for example a ModelInput and ModelOutput class, and have a typical workflow be:
m = ModelInput('test')
...
m_out = m.run(...)
where m_out is a ModelOutput instance. One could then also do:
m_out = ModelOutput('test.rtout')
We also need to get rid of the assumption that the input and output files have the same name other than the extension, otherwise there would be no point in asking the user for an input and an output name.
The use of the Model() class as both input and output is a bit confusing, because at the moment certain attributes (such as grid) only work if the model is input or output, so it would be better to distinguish between model input and model output. One possibility is to have for example a
ModelInput
andModelOutput
class, and have a typical workflow be:where
m_out
is aModelOutput
instance. One could then also do:We also need to get rid of the assumption that the input and output files have the same name other than the extension, otherwise there would be no point in asking the user for an input and an output name.