Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ML] Optimize inference step when there are no test docs #74315

Conversation

dimitris-athanasiou
Copy link
Contributor

@dimitris-athanasiou dimitris-athanasiou commented Jun 18, 2021

In data frame analytics, when the analysis supports inference,
training_percent is set to 100, and there are no test docs
(i.e. docs missing a value for their dependent variable),
there is no need to load the model in memory only to realize
there are no documents to run inference on.

This commit optimizes the inference step in this scenario.

In data frame analytics, when the analysis supports inference
and `training_percent` is set to `100`, there is no need to
load the model in memory only to realize there are no documents
to run inference on.

This commit optimizes the inference step in this scenario.
@elasticmachine elasticmachine added the Team:ML Meta label for the ML team label Jun 18, 2021
@elasticmachine
Copy link
Collaborator

Pinging @elastic/ml-core (Team:ML)

Copy link
Contributor

@droberts195 droberts195 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dimitris-athanasiou dimitris-athanasiou changed the title [ML] Optimize inference step when training_percent is 100 [ML] Optimize inference step when there are no test docs Jun 18, 2021
@dimitris-athanasiou
Copy link
Contributor Author

@droberts195 I had to change the implementation for this as the tests reminded me that it's not sufficient to check training_percent is 100. Instead, we need to verify there are no test docs as it could be training_percent was 100 but there are docs without a value for the dependent variable.

@dimitris-athanasiou dimitris-athanasiou merged commit 18a6cc4 into elastic:master Jun 22, 2021
@dimitris-athanasiou dimitris-athanasiou deleted the skip-inference-step-when-training-percent-is-100 branch June 22, 2021 07:47
dimitris-athanasiou added a commit that referenced this pull request Jun 22, 2021
#74398)

In data frame analytics, when the analysis supports inference,
`training_percent` is set to `100`, and there are no test docs
(i.e. docs missing a value for their dependent variable),
there is no need to load the model in memory only to realize
there are no documents to run inference on.

This commit optimizes the inference step in this scenario.

Backport of #74315
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>enhancement :ml Machine learning Team:ML Meta label for the ML team v7.14.0 v8.0.0-alpha1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants