Batching enhancements - #2029
Open
lbluque wants to merge 23 commits into
Open
Conversation
- Replace _batch_serve.py with batch_server.py (matches main's rename) - Move AutobatchConfig, AutobatchResult, and probe_optimal_batch_size into batch_server.py - Add _PredictWorker and MLIPWorkerPredictUnit to predict.py (appended after main's BatchServerPredictUnit) - Restore ProcessPoolExecutor and RayActorPoolExecutor backends in _batch.py alongside main's new features (uuid deployment names, autoscaling_config, update_checkpoint, delete, shutdown_ray) - Adapt tests to main's fixture pattern (ray_session, ray_controlled) while preserving branch's backend and autobatch tests
# Conflicts: # src/fairchem/core/calculate/__init__.py # src/fairchem/core/calculate/_batch.py # src/fairchem/core/calculate/_batch_server.py # src/fairchem/core/components/batch_server.py # src/fairchem/core/units/mlip_unit/batch_server.py # tests/core/units/mlip_unit/test_inference_serve.py # tests/core/units/mlip_unit/test_predict.py
…airchem into batching-enhancements
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This branch extends the Ray Serve batched inference stack with runtime autobatch probing, broader concurrency backend support, and InferenceBatcher usability tweaks. It aligns the earlier batching-enhancements work with main's refactored batch_server layout, makes OOM splitting opt-in, and adds a configure-at-runtime API.
Main changes
src/fairchem/core/calculate/_batch.py — InferenceBatcher
src/fairchem/core/components/batch_server.py
tests/core/calculate/test_batcher.py
Out of scope for the committed diff: local untracked examples/batching_inference_example.py and uncommitted config edits in configs/uma/...