schizophrenicmaniac opened a new pull request, #40646:
URL: https://github.com/apache/beam/pull/40646
`ModelManager._spawn_new_model` was recording `peak_during_load -
baseline_snap` as an observation for `{tag: 1}`, while `release_model` records
total peak memory for the snapshot of all loaded models. Since
`ResourceEstimator._solve` fits `Σ count·cost + bias ≈ reading`, the delta rows
and total rows contradict each other. With a single model loaded, both kinds
even end up in the same history bucket. The delta was also noisy, because the
peak window isn't reset before a load.
This removes the spawn-time observation, so the estimator now only sees
total memory readings with the full model snapshot from `release_model`.
Profiling unknown models in isolation mode is unchanged, since the initial
estimate is still set on release from the isolation baseline.
I added a test that loads two known models at the same time and checks that
the estimator history only contains total readings for the combined snapshot.
It fails on master, where a 2000 MB delta is recorded for `{model_b: 1}` while
3000 MB is in use.
Fixes #40636
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]