Skip to content

Commit

Permalink
Spawn serialization of executable graphs
Browse files Browse the repository at this point in the history
  • Loading branch information
wjsi committed Dec 9, 2020
1 parent 0f2c63e commit aae932e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions mars/dataframe/reduction/aggregation.py
Original file line number Diff line number Diff line change
Expand Up @@ -605,7 +605,11 @@ def _execute_map(cls, ctx, op: "DataFrameAggregate"):

# map according to map groups
ret_map_dfs = dict()
in_cols_set = set(in_data.columns) if in_data.ndim == 2 else None
for input_key, output_key, cols, func in op.pre_funcs:
if cols and in_cols_set == set(cols):
cols = None

src_df = in_data if cols is None else in_data[cols]
if input_key == output_key:
ret_map_dfs[output_key] = src_df
Expand Down
2 changes: 1 addition & 1 deletion mars/dataframe/reduction/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -870,7 +870,7 @@ def compile(self) -> ReductionSteps:

for key, step in self._output_key_to_post_steps.items():
cols = self._output_key_to_post_cols[key]
if set(cols) == set(referred_cols):
if cols and set(cols) == set(referred_cols):
post_cols = None
else:
post_cols = cols
Expand Down

0 comments on commit aae932e

Please sign in to comment.