Skip to content

Commit 90a8634

Browse files
Image2video code refactor (opea-project#1075)
* image2video code refactor. Signed-off-by: Ye, Xinyu <xinyu.ye@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * fix spell error. Signed-off-by: Ye, Xinyu <xinyu.ye@intel.com> * Update opea_image2video_microservice.py * changed naming Signed-off-by: Ye, Xinyu <xinyu.ye@intel.com> --------- Signed-off-by: Ye, Xinyu <xinyu.ye@intel.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent a19c222 commit 90a8634

File tree

17 files changed

+276
-256
lines changed

17 files changed

+276
-256
lines changed

.github/workflows/docker/compose/image2video-compose.yaml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,9 @@
55
services:
66
image2video:
77
build:
8-
dockerfile: comps/image2video/Dockerfile
8+
dockerfile: comps/image2video/src/Dockerfile
99
image: ${REGISTRY:-opea}/image2video:${TAG:-latest}
10-
svd:
10+
image2video-gaudi:
1111
build:
12-
dockerfile: comps/image2video/dependency/Dockerfile
13-
image: ${REGISTRY:-opea}/svd:${TAG:-latest}
14-
svd-gaudi:
15-
build:
16-
dockerfile: comps/image2video/dependency/Dockerfile.intel_hpu
17-
image: ${REGISTRY:-opea}/svd-gaudi:${TAG:-latest}
12+
dockerfile: comps/image2video/src/Dockerfile.intel_hpu
13+
image: ${REGISTRY:-opea}/image2video-gaudi:${TAG:-latest}

comps/image2video/Dockerfile

Lines changed: 0 additions & 18 deletions
This file was deleted.

comps/image2video/README.md

Lines changed: 0 additions & 83 deletions
This file was deleted.

comps/image2video/dependency/requirements.txt

Lines changed: 0 additions & 7 deletions
This file was deleted.

comps/image2video/dependency/svd_server.py

Lines changed: 0 additions & 76 deletions
This file was deleted.

comps/image2video/deployment/docker_compose/README.md

Whitespace-only changes.

comps/image2video/deployment/kubernetes/README.md

Whitespace-only changes.

comps/image2video/image2video.py

Lines changed: 0 additions & 47 deletions
This file was deleted.

comps/image2video/dependency/Dockerfile renamed to comps/image2video/src/Dockerfile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ COPY comps /home/comps
1313
RUN apt-get update && apt-get install python3-opencv -y && \
1414
pip install --no-cache-dir --upgrade pip setuptools && \
1515
if [ ${ARCH} = "cpu" ]; then pip install --no-cache-dir torch torchvision --index-url https://download.pytorch.org/whl/cpu; fi && \
16-
pip install --no-cache-dir -r /home/comps/image2video/dependency/requirements.txt
16+
pip install --no-cache-dir -r /home/comps/image2video/src/requirements.txt
1717

1818
ENV PYTHONPATH=$PYTHONPATH:/home
1919

20-
WORKDIR /home/comps/image2video/dependency
20+
WORKDIR /home/comps/image2video/src
2121

22-
ENTRYPOINT ["python", "svd_server.py"]
22+
ENTRYPOINT ["python", "opea_image2video_microservice.py"]

comps/image2video/dependency/Dockerfile.intel_hpu renamed to comps/image2video/src/Dockerfile.intel_hpu

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ ENV PYTHONPATH=/home/user:/usr/lib/habanalabs/:/optimum-habana
1919

2020
# Install requirements and optimum habana
2121
RUN pip install --no-cache-dir --upgrade pip && \
22-
pip install --no-cache-dir -r /home/user/comps/image2video/dependency/requirements.txt && \
22+
pip install --no-cache-dir -r /home/user/comps/image2video/src/requirements.txt && \
2323
pip install --no-cache-dir optimum[habana]
2424

2525
ENV PYTHONPATH=$PYTHONPATH:/home/user
2626

27-
WORKDIR /home/user/comps/image2video/dependency
27+
WORKDIR /home/user/comps/image2video/src
2828

29-
ENTRYPOINT ["python", "svd_server.py", "--device", "hpu"]
29+
ENTRYPOINT ["python", "opea_image2video_microservice.py", "--device", "hpu"]

0 commit comments

Comments
 (0)