Docker compose project for captioning images with VLMs
# Build the container
docker compose build internvl2-8b
# Run
docker compose run --rm --remove-orphans internvl2-8b
docker compose run --rm --remove-orphans vlm-caption --model=yannqi-r --thinking --content_hint="selfie photo" --system_prompt=system_prompt_example.txt --user_prompt=user_prompt_example.txt --replace_newlines
docker compose run --rm --remove-orphans vlm-caption --model=joycaption --quantize --system_prompt=system_prompt_basic.txt --user_prompt=user_prompt_image_quality.txt --replace_newlines
If the model is gated and a token is required to download or access the git repository, this can be specified
--build-arg HF_TOKEN=<insert token here>export HF_TOKEN=<insert token here> && docker compose run --rm --remove-orphans internvl2-8bI originally had a lowly 16GB GPU, so models were selected and adjusted to fit into this, e.g. by loading with 8 bit quantization. I now have a 5090 so larger models are being added.
If you can help with any of those, please submit a PR, or https://buymeacoffee.com/psychologic
62 commits
Python
92.3%
Dockerfile
7.7%
Docker compose project for captioning images with VLMs
# Build the container
docker compose build internvl2-8b
# Run
docker compose run --rm --remove-orphans internvl2-8b
docker compose run --rm --remove-orphans vlm-caption --model=yannqi-r --thinking --content_hint="selfie photo" --system_prompt=system_prompt_example.txt --user_prompt=user_prompt_example.txt --replace_newlines
docker compose run --rm --remove-orphans vlm-caption --model=joycaption --quantize --system_prompt=system_prompt_basic.txt --user_prompt=user_prompt_image_quality.txt --replace_newlines
If the model is gated and a token is required to download or access the git repository, this can be specified
--build-arg HF_TOKEN=<insert token here>export HF_TOKEN=<insert token here> && docker compose run --rm --remove-orphans internvl2-8bI originally had a lowly 16GB GPU, so models were selected and adjusted to fit into this, e.g. by loading with 8 bit quantization. I now have a 5090 so larger models are being added.
If you can help with any of those, please submit a PR, or https://buymeacoffee.com/psychologic
62 commits
Python
92.3%
Dockerfile
7.7%