Kraysent / OMTool

Modeling N-Body problem in galactic evolution application.
https://omtool.readthedocs.io/en/latest/
Apache License 2.0
0 stars 0 forks source link

Tasks should return arbitrary number of parameters #107

Closed Kraysent closed 2 years ago

Kraysent commented 2 years ago

Now tasks can only return two arrays of data. It makes impossible for the user to do some basic tasks: for example, if one needs to create heatmap (which has input of 3 arrays - x, y and weight).

The goal of this ticket is to make tasks return dictionary dict[str, np.ndarray]. The keys are the indentificators, values are actual results of the task. For example, scatter task would return

{
  'x': x / x.unit
  'y': y / y.unit
}

and then pass parameters { 'x': 'x', 'y': 'y' }into visualizer.

Kraysent commented 2 years ago

Should also fix tests