Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
guocuimi committed Oct 15, 2024
1 parent 8fb7fa8 commit 045d460
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 8 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/package_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ jobs:
- name: Install the package and run pytest
timeout-minutes: 10
run: |
docker pull pytorch/manylinux-builder:cuda${CUDA_VERSION}
docker run --rm -t --gpus=all \
-v "$CI_CACHE_DIR":/ci_cache \
-v "$GITHUB_WORKSPACE":/ScaleLLM \
Expand All @@ -96,5 +95,5 @@ jobs:
-e TORCH_VERSION=${TORCH_VERSION} \
-e PIP_CACHE_DIR=/ci_cache/.pip \
-u $(id -u):$(id -g) \
pytorch/manylinux-builder:cuda${CUDA_VERSION} \
vectorchai/scalellm_manylinux:cuda${CUDA_VERSION} \
bash /ScaleLLM/scripts/run_pytest.sh
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
# deps
/.deps

# pip cache
/.pip

# libtorch
/libtorch

Expand Down
9 changes: 3 additions & 6 deletions scripts/run_pytest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ ensure_env TORCH_VERSION
ensure_env CUDA_VERSION

PROJECT_ROOT="$(cd "$(dirname "$0")/.." && pwd)"
cd "$PROJECT_ROOT"

export HOME=/tmp/home
mkdir -p $HOME
Expand All @@ -26,16 +27,12 @@ export PATH="/opt/python/cp${PYVER}-cp${PYVER}/bin:$PATH"
# install PyTorch
pip install torch==$TORCH_VERSION -i "https://download.pytorch.org/whl/cu${CUDA_VERSION//./}"

cd "$PROJECT_ROOT"

# install dependencies
pip install numpy
pip install -r requirements-test.txt

# install scalellm wheel
pip install dist/*.whl

# run pytest
printf "\n\nRunning pytest\n\n"
# cd tests
python3 -m pytest
cd tests
pytest

0 comments on commit 045d460

Please sign in to comment.