File tree Expand file tree Collapse file tree 1 file changed +0
-4
lines changed
src/sagemaker/remote_function Expand file tree Collapse file tree 1 file changed +0
-4
lines changed Original file line number Diff line number Diff line change 159
159
160
160
printf "INFO: Invoking remote function inside conda environment: $conda_env.\\ n"
161
161
printf "INFO: $conda_exe run -n $conda_env python -m sagemaker.remote_function.invoke_function \\ n"
162
-
163
162
$conda_exe run -n $conda_env python -m sagemaker.remote_function.invoke_function "$@"
164
163
else
165
164
printf "INFO: No conda env provided. Invoking remote function\\ n"
166
165
printf "INFO: python -m sagemaker.remote_function.invoke_function \\ n"
167
-
168
166
python -m sagemaker.remote_function.invoke_function "$@"
169
167
fi
170
168
"""
213
211
printf "INFO: $conda_exe run -n $conda_env torchrun --nnodes $SM_HOST_COUNT --nproc_per_node $SM_NPROC_PER_NODE \
214
212
--master_addr $SM_MASTER_ADDR --master_port $SM_MASTER_PORT --node_rank $SM_CURRENT_HOST_RANK \
215
213
-m sagemaker.remote_function.invoke_function \\ n"
216
-
217
214
$conda_exe run -n $conda_env torchrun --nnodes $SM_HOST_COUNT --nproc_per_node $SM_NPROC_PER_NODE \
218
215
--master_addr $SM_MASTER_ADDR --master_port $SM_MASTER_PORT --node_rank $SM_CURRENT_HOST_RANK \
219
216
-m sagemaker.remote_function.invoke_function "$@"
220
217
else
221
218
printf "INFO: No conda env provided. Invoking remote function with torchrun\\ n"
222
219
printf "INFO: torchrun --nnodes $SM_HOST_COUNT --nproc_per_node $SM_NPROC_PER_NODE --master_addr $SM_MASTER_ADDR \
223
220
--master_port $SM_MASTER_PORT --node_rank $SM_CURRENT_HOST_RANK -m sagemaker.remote_function.invoke_function \\ n"
224
-
225
221
torchrun --nnodes $SM_HOST_COUNT --nproc_per_node $SM_NPROC_PER_NODE --master_addr $SM_MASTER_ADDR \
226
222
--master_port $SM_MASTER_PORT --node_rank $SM_CURRENT_HOST_RANK -m sagemaker.remote_function.invoke_function "$@"
227
223
fi
You can’t perform that action at this time.
0 commit comments