From 3824aa6b2fc253a2e3fd4a1f12ed0422280ce96a Mon Sep 17 00:00:00 2001 From: Brent Salisbury Date: Fri, 11 Oct 2024 02:41:50 -0400 Subject: [PATCH] Add poetry install shell cmd to the readme (#7) * Add poetry install shell cmd to the readme Signed-off-by: Brent Salisbury * Add GPU support instructions - Validated on an EC2 GPU instance to work. - Closes #8 Signed-off-by: Brent Salisbury * Update README.md Signed-off-by: Anil Vishnoi --------- Signed-off-by: Brent Salisbury Signed-off-by: Anil Vishnoi Co-authored-by: Anil Vishnoi --- README.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/README.md b/README.md index a8d1790..041e9a9 100644 --- a/README.md +++ b/README.md @@ -10,6 +10,9 @@ Install the dependencies ```sh +# Install poetry if not already available +curl -sSL https://install.python-poetry.org | python3 - + # Install dependencies poetry install @@ -30,3 +33,24 @@ curl -X 'POST' \ } }' ``` + +### Cuda GPU Support + +For GPU support try the following: + +```sh +# Create a virtual env +python3 -m venv venv + +# Activate the venv +source venv/bin/active + +# Install torch with the special index +pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu124 + +# Install the package +pip install -e . + +# Run the server +poetry run uvicorn docling_serve.app:app --reload +```