diff --git a/scripts/.cluster/direct/_direct_env.sh b/scripts/.cluster/direct/_direct_env.sh index 8c31245a..e45527fd 100755 --- a/scripts/.cluster/direct/_direct_env.sh +++ b/scripts/.cluster/direct/_direct_env.sh @@ -6,7 +6,7 @@ if [ -z "$PROJECT_DATA" ]; then exit 1 fi if [ -z "$PROJECT_ACCELERATOR_TYPE" ]; then - if (env -0 | cut -z -f1 -d= | tr '\0' '\n' | grep -q "TPU_"); then + if [ "$(uname)" != "Darwin" ] && (env -0 | cut -z -f1 -d= | tr '\0' '\n' | grep -q "TPU_"); then export PROJECT_ACCELERATOR_TYPE=tpu export PROJECT_VISIBLE_ACCELERATOR_DEVICES=all echo "Detected an environment with TPUs. For this reason, accelerator device dependencies will not be installed to a virtual environment." 1>&2