Skip to content

Commit

Permalink
lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
wilsonbb committed Dec 21, 2023
1 parent 9f94c69 commit 7521c55
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions src/tape/ensemble.py
Original file line number Diff line number Diff line change
Expand Up @@ -1008,7 +1008,18 @@ def bin_sources(
self.source.set_dirty(True)
return self

def batch(self, func, *args, meta=None, by_band=False, use_map=True, on=None, sort_by_time=True, label="", **kwargs):
def batch(
self,
func,
*args,
meta=None,
by_band=False,
use_map=True,
on=None,
sort_by_time=True,
label="",
**kwargs,
):
"""Run a function from tape.TimeSeries on the available ids
Parameters
Expand Down Expand Up @@ -1175,9 +1186,7 @@ def convert_and_sort(y, sort, id_col, time_col):
)
else: # use groupby
batch = source_to_batch.groupby(on, group_keys=False).apply(
lambda x: func(
*convert_and_sort(x, sort_by_time, id_col, time_col), **kwargs
),
lambda x: func(*convert_and_sort(x, sort_by_time, id_col, time_col), **kwargs),
meta=meta,
)

Expand Down

0 comments on commit 7521c55

Please sign in to comment.