Skip to content

Commit bd27358

Browse files
changes after review
1 parent 72f2a02 commit bd27358

3 files changed

Lines changed: 15 additions & 13 deletions

File tree

.github/workflows/matrix.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,11 +126,10 @@
126126
"dockerfile": "Dockerfile-intel"
127127
},
128128
{
129-
"name": "rocm-mi300-mi325",
129+
"name": "rocm-gfx942-gfx950",
130130
"imageNamePrefix": "rocm-",
131131
"runOn": "always",
132132
"sccache": true,
133-
"extraBuildArgs": "GPU_ARCHS=gfx942",
134133
"grpc": true,
135134
"dockerfile": "Dockerfile-amd"
136135
}

Dockerfile-amd

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
# ── Rust builder ─────────────────────────────────────────────────────────────
21
FROM lukemathwalker/cargo-chef:latest-rust-1.92-bookworm AS chef
32
WORKDIR /usr/src
43

@@ -58,7 +57,6 @@ RUN --mount=type=secret,id=actions_results_url,env=ACTIONS_RESULTS_URL \
5857
--mount=type=secret,id=actions_runtime_token,env=ACTIONS_RUNTIME_TOKEN \
5958
cargo build --release --bin text-embeddings-router -F grpc -F python --no-default-features && sccache -s
6059

61-
# ── ROCm Python runtime ───────────────────────────────────────────────────────
6260
FROM rocm/pytorch:rocm7.2.2_ubuntu22.04_py3.10_pytorch_release_2.10.0 AS rocm
6361

6462
LABEL maintainer="Hugging Face"
@@ -87,7 +85,6 @@ COPY backends/python/server/requirements-amd.txt backends/python/server/requirem
8785
RUN cd backends/python/server && \
8886
make install
8987

90-
# ── Final images ──────────────────────────────────────────────────────────────
9188
FROM rocm AS grpc
9289

9390
COPY --from=grpc-builder /usr/src/target/release/text-embeddings-router /usr/local/bin/text-embeddings-router

docs/source/en/amd_gpu.md

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ model=BAAI/bge-base-en-v1.5
3131
volume=$PWD/data # share a volume to avoid re-downloading weights
3232

3333
docker run \
34-
--device /dev/kfd --device /dev/dri \
34+
--device /dev/kfd --device /dev/dri/renderD128 \
3535
--group-add video \
3636
--ipc=host \
3737
-p 8080:80 \
@@ -44,10 +44,13 @@ docker run \
4444
Then test it:
4545

4646
```shell
47-
curl http://localhost:8080/embed \
48-
-X POST \
47+
curl http://localhost:8080/v1/embeddings \
4948
-H 'Content-Type: application/json' \
50-
-d '{"inputs": "What is Deep Learning?"}'
49+
-d '{
50+
"input": "What is Deep Learning?",
51+
"model": "text-embeddings-inference",
52+
"encoding_format": "float"
53+
}'
5154
```
5255

5356
---
@@ -59,7 +62,7 @@ If you prefer to build from source, use AMD's official ROCm PyTorch image as the
5962
## Step 1: Start the container
6063

6164
```shell
62-
docker run -it --device=/dev/kfd --device=/dev/dri \
65+
docker run -it --device=/dev/kfd --device=/dev/dri/renderD128 \
6366
--group-add video --shm-size 8g \
6467
-v $PWD:/workspace \
6568
rocm/pytorch:latest bash
@@ -132,10 +135,13 @@ model=BAAI/bge-base-en-v1.5
132135
Once the server is ready, you can test it with a simple embed request:
133136

134137
```shell
135-
curl http://localhost:8080/embed \
136-
-X POST \
138+
curl http://localhost:8080/v1/embeddings \
137139
-H 'Content-Type: application/json' \
138-
-d '{"inputs": "What is Deep Learning?"}'
140+
-d '{
141+
"input": "What is Deep Learning?",
142+
"model": "text-embeddings-inference",
143+
"encoding_format": "float"
144+
}'
139145
```
140146

141147
## Verifying GPU detection

0 commit comments

Comments
 (0)