This commit is contained in:
Chris Wilhelm 2025-03-13 14:10:55 -07:00
parent 671e4a7dae
commit 7e8492059c
4 changed files with 9 additions and 20 deletions

View File

@ -51,7 +51,6 @@ Changelog = "https://github.com/allenai/olmocr/blob/main/CHANGELOG.md"
gpu = [ gpu = [
"sgl-kernel==0.0.3.post1", "sgl-kernel==0.0.3.post1",
"sglang[all]==0.4.2", "sglang[all]==0.4.2",
"flashinfer"
] ]
dev = [ dev = [

View File

@ -32,5 +32,6 @@ RUN /install.sh && rm /install.sh
WORKDIR /root WORKDIR /root
COPY gpu-ci-script.sh .
ENV PYTHONUNBUFFERED=1 ENV PYTHONUNBUFFERED=1

15
scripts/beaker/gpu-ci-script.sh Normal file → Executable file
View File

@ -1,14 +1,15 @@
#/usr/bin/bash
set -ex set -ex
git clone git@github.com:allenai/olmocr.git olmocr \ git clone https://github.com/allenai/olmocr.git olmocr \
&& cd olmocr \ && cd olmocr \
&& git checkout $GIT_REVISION \ && git checkout $GIT_REVISION \
&& /root/.local/bin/uv pip install --system --no-cache . \ && /root/.local/bin/uv pip install --system --no-cache \
&& /root/.local/bin/uv pip install --system --no-cache sgl-kernel==0.0.3.post1 --force-reinstall --no-deps \ .[gpu] \
&& /root/.local/bin/uv pip install --system --no-cache "sglang[all]==0.4.2" --find-links https://flashinfer.ai/whl/cu124/torch2.4/flashinfer/ pytest \
&& /root/.local/bin/uv pip install --system --no-cache pytest \ --find-links https://flashinfer.ai/whl/cu124/torch2.4/flashinfer/ \
&& python -m olmocr.pipeline ./localworkspace --pdfs tests/gnarly_pdfs/*.pdf \ && pytest tests/gnarly_pdfs/test_evaluate_gnarly_pdfs.py
&& python tests/gnarly_pdfs/evaluate_gnarly_pdfs.py

View File

@ -1,12 +0,0 @@
from setuptools import setup
setup(
extras_require={
"gpu": [
"sgl-kernel==0.0.3.post1",
"sglang[all]==0.4.2",
"flashinfer"
],
},
dependency_links=["https://flashinfer.ai/whl/cu124/torch2.4/flashinfer/"],
)