Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add gpu pool to test deployment and enable gpu in sample test #696

Merged
merged 3 commits into from Jan 25, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
6 changes: 6 additions & 0 deletions test/presubmit-tests-with-pipeline-deployment.sh
Expand Up @@ -126,6 +126,12 @@ ${KUBEFLOW_SRC}/scripts/kfctl.sh init ${KFAPP} --platform ${PLATFORM} --project

cd ${KFAPP}
${KUBEFLOW_SRC}/scripts/kfctl.sh generate platform

## Add one gpu node for covering gpu sample
sed -i -e 's|gpu-pool-initialNodeCount:\s*0|gpu-pool-initialNodeCount: 1|g' ./gcp_config/cluster-kubeflow.yaml
sed -i -e 's|gpu-pool-max-nodes:\s*0|gpu-pool-max-nodes: 1|g' ./gcp_config/cluster-kubeflow.yaml
sed -i -e 's|gpu-pool-min-nodes:\s*0|gpu-pool-min-nodes: 1|g' ./gcp_config/cluster-kubeflow.yaml

${KUBEFLOW_SRC}/scripts/kfctl.sh apply platform
${KUBEFLOW_SRC}/scripts/kfctl.sh generate k8s

Expand Down
1 change: 1 addition & 0 deletions test/sample-test/run_test.sh
Expand Up @@ -152,6 +152,7 @@ if [ "$TEST_NAME" == 'tf-training' ]; then
sed -i -e "s|gcr.io/ml-pipeline/ml-pipeline-dataflow-tf-predict:\([a-zA-Z0-9_.-]\)\+|${DATAFLOW_PREDICT_IMAGE}|g" kubeflow-training-classification.py
sed -i -e "s|gcr.io/ml-pipeline/ml-pipeline-local-confusion-matrix:\([a-zA-Z0-9_.-]\)\+|${LOCAL_CONFUSIONMATRIX_IMAGE}|g" kubeflow-training-classification.py
fi
sed -i -e "s|use_gpu\s*=\s*False|use_gpu = True|g" kubeflow-training-classification.py
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That seems a bit hacky. Could we use proper parameter passing instead of using sed on a Python file?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We did sed replace all over the places in the test script. There is currently a limitation that user cannot pass gpu setting as pipeline parameter as gpu must be set before the dsl compile time. That's why we cannot use parameter to control this test.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, thanks.


dsl-compile --py kubeflow-training-classification.py --output kubeflow-training-classification.tar.gz

Expand Down