Repository navigation
feat: CUDA kernel warmup to fix cold-start latency - #11
Open
abimaelmartell wants to merge 8 commits into
Open
abimaelmartell wants to merge 8 commits into
abimaelmartell wants to merge 8 commits into
Conversation
Pre-compile CUDA/cuDNN kernels at startup by running synthetic inference and warming all ~255 OCR-det resolution shapes. Pins inference to a dedicated GPU thread so warmed caches are reused on real requests.
- batch_sizes.patch: Increases YOLO_LAYOUT_BASE_BATCH_SIZE and MFD_BASE_BATCH_SIZE from 1 to 8 for better GPU utilization on the first two pipeline stages (~3-4s savings on 53 pages). - wired_table_cuda.patch: Enables CUDAExecutionProvider for the wired table UNet ONNX model which was running CPU-only. This moves table structure inference from CPU to GPU, reducing the 16s table-wired bottleneck significantly.
RunPod serverless starts its HTTP server on port 8000 only after model loading and CUDA warmup complete. The healthcheck lets RunPod know when the worker is ready to accept requests. 10-minute start-period covers the warmup phase.
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