question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How to use conditionals in composed pipelines

See original GitHub issue

My use case is the following: i want to use an ARIMA model to do timeseries forcasting, but i dont want outliers to “pollute” the forecast quality. Those outliers are usally bad sampled data deriving from bad sensor settings or maintenance and are in generally easy to figure out (sudden drops in values, or so)

So the idea would be to use pipe an anomaly detector before the arima model and when an anomaly is detected then the model.learn function is not called.

Sure enough i could implement those 2 models as independent models and an if/else statement in betwee, but i was wondering if it is possible to have all of it into a single pipeline.

Like:

StandardScaler --> AnomaliesDetector --> Thresholder -->  If(isNotAnomaly) --------- true -----> ArimaModel --> done
                                                               |----- false ------> skip learning

Is this possible in river ?

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:17 (17 by maintainers)

github_iconTop GitHub Comments

1reaction
MaxHalfordcommented, May 27, 2022

I’m on my phone so I can’t give you details instructions. It actually happens with pip, it’s just that you have to tell pip to install from sources on GitHub. There are I strictions in the installation section in the docs.

1reaction
MaxHalfordcommented, May 18, 2022

River doesn’t provide any such functionality, but maybe you’ll find what you need in pandas.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Conditional workflow execution in CI/CD pipelines - CircleCI
You executed a job in a CircleCI pipeline based on the condition that the first job must pass before the second one can...
Read more >
Conditionals in a Declarative Pipeline Jenkinsfile - Michael Kutz
In this article I'll show how to express conditionals — like if, else or switch — in a Jenkinsfile using the declarative pipeline...
Read more >
Conditions - Azure Pipelines | Microsoft Learn
Enable a custom condition​​ Conditions are written as expressions in YAML pipelines. The agent evaluates the expression beginning with the ...
Read more >
Converting Conditional Build Steps to Jenkins Pipeline
In this post, we'll take a look at how we might converting Freestyle jobs that include conditional build steps to Jenkins Pipeline.
Read more >
Create Conditional Statements — Rok 2.0 documentation
Using pipeline parameters in your conditional statements, instead of constant values, is particularly useful for quick iteration and experimentation. You can ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found