sciline.compute_mapped#

sciline.compute_mapped(pipeline, base_name, *, index_names=None)[source]#

Given a graph with a mapped node with given base_name, return a series of computed results.

This is meant to be used in combination with Pipeline.map(). If the mapped node depends on multiple indices, the index of the returned series will have a multi-index.

Note that Pandas is not a dependency of Sciline and must be installed separately.

Parameters:
  • graph – The data graph to get the mapped node names from.

  • base_name (type) – The base name of the mapped node to get the names for.

  • index_names (Optional[Sequence[Hashable]], default: None) – Specifies the names of the indices of the mapped node. If not given this is inferred from the graph, but the argument may be required to disambiguate multiple mapped nodes with the same name.

Returns:

Series – The series of computed results corresponding to the mapped node.