Reduce pitfalls of `Model::create_am_dset`
As part of !267 (merged), the create_am_dset
method suggested in #236 (closed) was implemented. However, @JulianWeninger highlighted some pitfalls that may need to be addressed:
- If the agent number does not match the dataset capacity, writing may fail (too many agents) or data may be wrong (too few agents and no fill value)
- Association between agent and their respective coordinate label may be wrong if there is an agent turnover (with the overall number of agents remaining the same)
Effectively, the create_am_dset
method only works reliably in the simplest case: Fixed set of agents without ID changes.
The above pitfalls could be addressed by adding an additional trait to AgentManager
that denotes this "fixed" mode and restricts the interface correspondingly; the create_am_dset
method could then be adapted to only work with AgentManager
s that have this "fixed" trait.