-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
53 lines (39 loc) · 1.25 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
.PHONY: download-model local-run-server \
local-run-client local-all local-services-up \
services-up open-webpage all-cuda
# For local use
download-model:
bash scripts/model_download/run.sh
mv yolov8m.onnx yolo_prediction/models
rm yolov8m.pt
local-run-server:
@cd yolo_prediction && cargo run
local-run-client:
@cd webcam_capture && cargo run
local-services-build:
@docker compose -f compose.local.yaml build
local-services-up:
@docker compose -f compose.local.yaml up -d
local-services-cuda-build:
@docker compose -f compose.cuda.local.yaml build
local-services-cuda-up:
@docker compose -f compose.cuda.local.yaml up -d
# For external use
services-up:
@docker compose -f compose.yaml up -d
services-up-cuda:
@docker compose -f compose.cuda.yaml up -d
open-webpage:
@if command -v xdg-open > /dev/null; then xdg-open index.html; \
elif command -v open > /dev/null; then open index.html; \
elif command -v start > /dev/null; then start index.html; \
else echo "No suitable command found to open the file."; fi
predict_image:
@cd scripts/predict_image && bash predict_image.sh
grpc_ui:
@cd scripts/grpc_ui && bash run_grpc_ui.sh
# Tear up
services-down:
@docker compose down
all: services-up open-webpage
all-cuda: services-up-cuda open-webpage