modal-omniparser

A serverless compute port of the OmniParser vision model for the Modal platform.
git clone https://unitehenry.com/git/modal-omniparser.git
Log | Files | Refs | README

commit b4dd839d69fdfb35cd80fa9314cc29b1309df293
parent f3836ef1f44387e148d896aaa1dbec1f6e71a870
Author: Henry Unite <unitehenry@gmail.com>
Date:   Sun, 15 Mar 2026 01:46:31 +0000

chore: format

Diffstat:
Mimage.py | 2+-
Mvolume.py | 2++
2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/image.py b/image.py @@ -58,7 +58,7 @@ omniparser_v2_0_1 = ( "mv weights/icon_caption weights/icon_caption_florence", ] ) - .env({ 'TOKENIZERS_PARALLELISM': 'false' }) + .env({"TOKENIZERS_PARALLELISM": "false"}) .add_local_python_source("volume") .add_local_python_source("image") .add_local_python_source("parse") diff --git a/volume.py b/volume.py @@ -18,6 +18,8 @@ def cache(func): @wraps(func) def wrapper(*args, **kwargs): for path in CACHE_PATHS: + if not os.path.isdir(f"/data/{path}"): + continue subprocess.run(["cp", "-rf", "--", f"/data/{path}", "/root"], check=False) try: