Skip to content

Commit

Permalink
UPDATE: use **params for learning in pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
MarekWadinger committed Mar 24, 2024
1 parent f84ed46 commit d67ffbd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions river/compose/pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -471,11 +471,11 @@ def learn_one(self, x: dict, y=None, **params):
# Here the step is not a transformer, and it's supervised, such as a LinearRegression.
# This is usually the last step of the pipeline.
elif step._supervised:
step.learn_one(x=x, y=y)
step.learn_one(x=x, y=y, **params)
# Here the step is not a transformer, and it's unsupervised, such as a KMeans. This
# is also usually the last step of the pipeline.
else:
step.learn_one(x=x)
step.learn_one(x=x, **params)

def _transform_one(self, x: dict):
"""This methods takes care of applying the first n - 1 steps of the pipeline, which are
Expand Down

0 comments on commit d67ffbd

Please sign in to comment.