allenai / allenai/olmocr

I have a hard time reproducing the benchmark code

未关闭
#305 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
bug
主要语言
Python
星标
19.5k
派生
1.6k
PR 合并指标
30 天内没有已合并 PR

描述

### 🐛 Describe the bug

I get this error:

```
(olmocr) brigal@c6b03d89ae44 /workspace/perso/dolma (main) $ python -m olmocr.bench.convert olmocr_pipeline --dir /data_project/data/docparser/benchmarks/olmocr_bench2/bench_data/
Traceback (most recent call last):
File "", line 198, in _run_module_as_main
File "", line 88, in _run_code
File "/data_project/data/venvs/olmocr/lib/python3.12/site-packages/olmocr/bench/convert.py", line 246, in
module = importlib.import_module(module_path)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/ldap/brigal/.local/share/uv/python/cpython-3.12.11-linux-x86_64-gnu/lib/python3.12/importlib/__init__.py", line 90, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 1387, in _gcd_import
File "", line 1360, in _find_and_load
File "", line 1331, in _find_and_load_unlocked
File "", line 935, in _load_unlocked
File "", line 999, in exec_module
File "", line 488, in _call_with_frames_removed
File "/data_project/data/venvs/olmocr/lib/python3.12/site-packages/olmocr/bench/runners/run_olmocr_pipeline.py", line 7, in
from olmocr.pipeline import (
ImportError: cannot import name 'sglang_server_host' from 'olmocr.pipeline' (/data_project/data/venvs/olmocr/lib/python3.12/site-packages/olmocr/pipeline.py). Did you mean: 'vllm_server_host'?
```

Apparently, sglang need to be replaced with vllm

### Versions
Python 3.12.11
Using Python 3.12.11 environment at: /data_project/data/venvs/olmocr
aiohappyeyeballs==2.6.1
aiohttp==3.12.15
aiosignal==1.4.0
airportsdata==20250811
annotated-types==0.7.0
anyio==4.10.0
astor==0.8.1
attrs==25.3.0
beaker-py==2.4.7
beautifulsoup4==4.13.4
blake3==1.0.5
bleach==6.2.0
blinker==1.9.0
boto3==1.40.9
botocore==1.40.9
cached-path==1.7.3
cachetools==5.5.2
certifi==2025.8.3
cffi==1.17.1
charset-normalizer==3.4.3
click==8.2.1
cloudpickle==3.1.1
compressed-tensors==0.10.2
cryptography==45.0.6
cupy-cuda12x==13.5.1
defusedxml==0.7.1
deprecated==1.2.18
depyf==0.18.0
dill==0.4.0
diskcache==5.6.3
distro==1.9.0
dnspython==2.7.0
einops==0.8.1
email-validator==2.2.0
eval-type-backport==0.2.2
fastapi==0.116.1
fastapi-cli==0.0.8
fastapi-cloud-cli==0.1.5
fastjsonschema==2.21.1
fastrlock==0.8.3
filelock==3.18.0
flashinfer-python @ https://download.pytorch.org/whl/cu128/flashinfer/flashinfer_python-0.2.5%2Bcu128torch2.7-cp38-abi3-linux_x86_64.whl
flask==3.1.1
frozenlist==1.7.0
fsspec==2025.7.0
ftfy==6.3.1
fuzzysearch==0.8.0
gguf==0.17.1
google-api-core==2.25.1
google-auth==2.40.3
google-cloud-core==2.4.3
google-cloud-storage==2.19.0
google-crc32c==1.7.1
google-genai==1.30.0
google-resumable-media==2.7.2
googleapis-common-protos==1.70.0
greenlet==3.2.4
grpcio==1.74.0
h11==0.16.0
hf-xet==1.1.7
httpcore==1.0.9
httptools==0.6.4
httpx==0.28.1
huggingface-hub==0.34.4
idna==3.10
img2pdf==0.6.1
interegular==0.3.3
itsdangerous==2.2.0
jinja2==3.1.6
jiter==0.10.0
jmespath==1.0.1
jsonschema==4.25.0
jsonschema-specifications==2025.4.1
jupyter-client==8.6.3
jupyter-core==5.8.1
jupyterlab-pygments==0.3.0
lark==1.2.2
lingua-language-detector==2.1.1
llguidance==0.7.30
llvmlite==0.44.0
lm-format-enforcer==0.10.12
lxml==6.0.0
markdown-it-py==4.0.0
markdown2==2.5.4
markupsafe==3.0.2
mdurl==0.1.2
mistral-common==1.8.3
mistralai==1.9.3
mistune==3.1.3
mpmath==1.3.0
msgpack==1.1.1
msgspec==0.19.0
multidict==6.6.4
nbclient==0.10.2
nbconvert==7.16.6
nbformat==5.10.4
nest-asyncio==1.6.0
networkx==3.5
ninja==1.13.0
numba==0.61.2
numpy==2.2.6
nvidia-cublas-cu12==12.6.4.1
nvidia-cuda-cupti-cu12==12.6.80
nvidia-cuda-nvrtc-cu12==12.6.77
nvidia-cuda-runtime-cu12==12.6.77
nvidia-cudnn-cu12==9.5.1.17
nvidia-cufft-cu12==11.3.0.4
nvidia-cufile-cu12==1.11.1.6
nvidia-curand-cu12==10.3.7.77
nvidia-cusolver-cu12==11.7.1.2
nvidia-cusparse-cu12==12.5.4.2
nvidia-cusparselt-cu12==0.6.3
nvidia-nccl-cu12==2.26.2
nvidia-nvjitlink-cu12==12.6.85
nvidia-nvtx-cu12==12.6.77
olmocr==0.3.0
openai==1.90.0
opencv-python-headless==4.12.0.88
orjson==3.11.2
outlines==0.1.11
outlines-core==0.1.26
packaging==25.0
pandocfilters==1.5.1
partial-json-parser==0.2.1.1.post6
pikepdf==9.10.2
pillow==11.3.0
platformdirs==4.3.8
playwright==1.54.0
prometheus-client==0.22.1
prometheus-fastapi-instrumentator==7.1.0
propcache==0.3.2
proto-plus==1.26.1
protobuf==5.29.5
psutil==7.0.0
py-cpuinfo==9.0.0
pyasn1==0.6.1
pyasn1-modules==0.4.2
pybase64==1.4.2
pycountry==24.6.1
pycparser==2.22
pydantic==2.11.7
pydantic-core==2.33.2
pydantic-extra-types==2.10.5
pyee==13.0.0
pygments==2.19.2
pypdf==6.0.0
pypdfium2==4.30.0
python-dateutil==2.9.0.post0
python-dotenv==1.1.1
python-json-logger==3.3.0
python-magic==0.4.27
python-multipart==0.0.20
pyyaml==6.0.2
pyzmq==27.0.1
rapidfuzz==3.13.0
ray==2.48.0
referencing==0.36.2
regex==2025.7.34
requests==2.32.4
rich==13.9.4
rich-toolkit==0.15.0
rignore==0.6.4
rpds-py==0.27.0
rsa==4.9.1
s3transfer==0.13.1
safetensors==0.6.2
scipy==1.16.1
sentencepiece==0.2.1
sentry-sdk==2.34.1
sequence-align==0.3.0
setuptools==79.0.1
shellingham==1.5.4
six==1.17.0
smart-open==7.3.0.post1
sniffio==1.3.1
soupsieve==2.7
starlette==0.47.2
sympy==1.14.0
syntok==1.4.4
tenacity==9.1.2
tiktoken==0.11.0
tinycss2==1.4.0
tinyhost==0.4.18
tokenizers==0.21.4
torch==2.7.0
torchaudio==2.7.0
torchvision==0.22.0
tornado==6.5.2
tqdm==4.67.1
traitlets==5.14.3
transformers==4.52.4
triton==3.3.0
typer==0.16.0
typing-extensions==4.14.1
typing-inspection==0.4.1
urllib3==2.5.0
uvicorn==0.35.0
uvloop==0.21.0
vllm==0.9.2
watchfiles==1.1.0
wcwidth==0.2.13
webencodings==0.5.1
websockets==15.0.1
werkzeug==3.1.3
wrapt==1.17.3
xformers==0.0.30
xgrammar==0.1.19
yarl==1.20.1
zstandard==0.23.0

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。