-
Notifications
You must be signed in to change notification settings - Fork 932
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Contributes to #17662. @MarcoGorelli provided very helpful instructions for running the narwhals test suite. We should examine and correct the failing tests. We are down to 39 failures, shown in [this Kaggle notebook](https://www.kaggle.com/code/marcogorelli/testing-cudf-in-narwhals?scriptVersionId=220053914). Authors: - Bradley Dice (https://github.com/bdice) Approvers: - Matthew Murray (https://github.com/Matt711) - Gil Forsyth (https://github.com/gforsyth) URL: #17884
- Loading branch information
Showing
3 changed files
with
69 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#!/bin/bash | ||
# Copyright (c) 2025, NVIDIA CORPORATION. | ||
|
||
# Support invoking test_python_cudf.sh outside the script directory | ||
cd "$(dirname "$(realpath "${BASH_SOURCE[0]}")")"/../ || exit 1 | ||
|
||
# Common setup steps shared by Python test jobs | ||
source ./ci/test_python_common.sh test_python_narwhals | ||
|
||
rapids-logger "Check GPU usage" | ||
nvidia-smi | ||
rapids-print-env | ||
EXITCODE=0 | ||
trap "EXITCODE=1" ERR | ||
set +e | ||
|
||
rapids-logger "pytest narwhals" | ||
git clone https://github.com/narwhals-dev/narwhals --depth=1 | ||
pushd narwhals || exit 1 | ||
rapids-pip-retry install -U -e ".[dev]" | ||
|
||
rapids-logger "Check narwhals versions" | ||
python -c "import narwhals; print(narwhals.show_versions())" | ||
|
||
rapids-logger "Run narwhals tests for cuDF" | ||
python -m pytest \ | ||
--cache-clear \ | ||
--junitxml="${RAPIDS_TESTS_DIR}/junit-cudf-narwhals.xml" \ | ||
--numprocesses=8 \ | ||
--dist=worksteal \ | ||
--constructors=cudf | ||
|
||
rapids-logger "Run narwhals tests for cuDF Polars" | ||
NARWHALS_POLARS_GPU=1 python -m pytest \ | ||
--cache-clear \ | ||
--junitxml="${RAPIDS_TESTS_DIR}/junit-cudf-polars-narwhals.xml" \ | ||
--numprocesses=8 \ | ||
--dist=worksteal \ | ||
--constructors=polars[lazy] | ||
|
||
popd || exit 1 | ||
|
||
rapids-logger "Test script exiting with value: $EXITCODE" | ||
exit ${EXITCODE} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters