From 5fe505f28b8cdeea375a8778ddb32911255229b9 Mon Sep 17 00:00:00 2001 From: Xiang Zhen Gan Date: Fri, 6 Dec 2024 08:53:49 +0800 Subject: [PATCH] add readme --- docker/evaluation/README.md | 66 +++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 docker/evaluation/README.md diff --git a/docker/evaluation/README.md b/docker/evaluation/README.md new file mode 100644 index 00000000..99ddde1f --- /dev/null +++ b/docker/evaluation/README.md @@ -0,0 +1,66 @@ +# CSGHUB Nginx Images Building + +## Login Container Registry +```bash +OPENCSG_ACR="opencsg-registry.cn-beijing.cr.aliyuncs.com" +OPENCSG_ACR_USERNAME="" +OPENCSG_ACR_PASSWORD="" +echo "$OPENCSG_ACR_PASSWORD" | docker login $OPENCSG_ACR -u $OPENCSG_ACR_USERNAME --password-stdin +``` + +## Build Multi-Platform Images +```bash +export BUILDX_NO_DEFAULT_ATTESTATIONS=1 +export IMAGE_TAG=0.3.5 +docker buildx build --platform linux/amd64,linux/arm64 \ + -t ${OPENCSG_ACR}/public/opencompass:${IMAGE_TAG} \ + -t ${OPENCSG_ACR}/public/opencompass:latest \ + -f Dockerfile.opencompass \ + --push . +export IMAGE_TAG=0.4.6 +docker buildx build --platform linux/amd64,linux/arm64 \ + -t ${OPENCSG_ACR}/public/lm-evaluation-harness:${IMAGE_TAG} \ + -t ${OPENCSG_ACR}/public/lm-evaluation-harness:latest \ + -f Dockerfile.lm-evaluation-harness \ + --push . +``` +*The above command will create `linux/amd64` and `linux/arm64` images with the tags `${IMAGE_TAG}` and `latest` at the same time.* + +## Test the opencompass Image +```bash +docker run \ + -e ACCESS_TOKEN=xxxx \ + -e MODEL_ID="OpenCSG/csg-wukong-1B" \ + -e DATASET_IDS="xzgan/hellaswag" \ + -e HF_ENDPOINT=https://hub.opencsg.com \ + -e ASCEND_VISIBLE_DEVICES=7 \ + -e S3_ACCESS_ID="xxxx" \ + -e S3_ACCESS_SECRET="xxxx" \ + -e S3_BUCKET="xxxxx" \ + -e S3_ENDPOINT="xxxxx" \ + -e S3_SSL_ENABLED="true" \ + ${OPENCSG_ACR}/public/opencompass:${IMAGE_TAG} +``` + +## Test the lm-evaluation-harness Image +```bash +export IMAGE_TAG=0.4.6 +docker run \ + --gpus device=7 \ + -e ACCESS_TOKEN=xxxx \ + -e MODEL_ID="OpenCSG/csg-wukong-1B" \ + -e DATASET_IDS="Rowan/hellaswag" \ + -e HF_ENDPOINT=https://hub.opencsg.com\ + -e S3_ACCESS_ID="xxx" \ + -e S3_ACCESS_SECRET="xxx" \ + -e S3_BUCKET="xxx" \ + -e S3_ENDPOINT="xxx" \ + -e S3_SSL_ENABLED="true" \ + ${OPENCSG_ACR}/public/lm-evaluation-harness:${IMAGE_TAG} +``` + +## inference image name, version and cuda version +| Latest Image | Version | CUDA Version | +| --- | --- | --- | +| opencompass | 0.3.5 | 12.4 | +| lm-evaluation-harness | 0.4.6 | 12.4 |