@@ -181,8 +181,7 @@ jobs:
181181
182182 echo "::group::Install Voxtral requirements"
183183 ${CONDA_RUN} pip install -U "huggingface_hub[cli]<1.0"
184- ${CONDA_RUN} python -c "from huggingface_hub import login; login(token='$SECRET_EXECUTORCH_HF_TOKEN')"
185- ${CONDA_RUN} pip install mistral_common librosa soundfile datasets
184+ ${CONDA_RUN} huggingface-cli login --token $SECRET_EXECUTORCH_HF_TOKEN
186185 OPTIMUM_ET_VERSION=$(cat .ci/docker/ci_commit_pins/optimum-executorch.txt)
187186 ${CONDA_RUN} pip install "optimum-executorch @ git+https://github.com/huggingface/optimum-executorch.git@${OPTIMUM_ET_VERSION}"
188187 echo "::endgroup::"
@@ -239,14 +238,14 @@ jobs:
239238 echo "::endgroup::"
240239
241240 echo "::group::Install Voxtral Realtime requirements"
242- ${CONDA_RUN} pip install -U "huggingface_hub[cli]" safetensors
243- ${CONDA_RUN} python -c "from huggingface_hub import login; login( token=' $SECRET_EXECUTORCH_HF_TOKEN')"
241+ ${CONDA_RUN} pip install -U "huggingface_hub[cli]<1.0 " safetensors
242+ ${CONDA_RUN} huggingface-cli login -- token $SECRET_EXECUTORCH_HF_TOKEN
244243 echo "::endgroup::"
245244
246245 ${CONDA_RUN} pip list
247246
248247 echo "::group::Download model"
249- ${CONDA_RUN} python -c "from huggingface_hub import snapshot_download; snapshot_download(' mistralai/Voxtral-Mini-4B-Realtime-2602')"
248+ ${CONDA_RUN} huggingface-cli download mistralai/Voxtral-Mini-4B-Realtime-2602
250249 MODEL_PATH=$(${CONDA_RUN} python -c "from huggingface_hub import snapshot_download; print(snapshot_download('mistralai/Voxtral-Mini-4B-Realtime-2602'))")
251250 echo "Model path: ${MODEL_PATH}"
252251 echo "::endgroup::"
@@ -313,7 +312,7 @@ jobs:
313312
314313 echo "::group::Install Whisper requirements"
315314 ${CONDA_RUN} pip install -U "huggingface_hub[cli]<1.0"
316- ${CONDA_RUN} python -c "from huggingface_hub import login; login( token=' $SECRET_EXECUTORCH_HF_TOKEN')"
315+ ${CONDA_RUN} huggingface-cli login -- token $SECRET_EXECUTORCH_HF_TOKEN
317316 ${CONDA_RUN} pip install transformers soundfile datasets librosa
318317 echo "::endgroup::"
319318
@@ -447,7 +446,7 @@ jobs:
447446
448447 echo "::group::Install LLM requirements"
449448 ${CONDA_RUN} pip install -U "huggingface_hub[cli]<1.0"
450- ${CONDA_RUN} python -c "from huggingface_hub import login; login( token=' $SECRET_EXECUTORCH_HF_TOKEN')"
449+ ${CONDA_RUN} huggingface-cli login -- token $SECRET_EXECUTORCH_HF_TOKEN
451450 OPTIMUM_ET_VERSION=$(cat .ci/docker/ci_commit_pins/optimum-executorch.txt)
452451 ${CONDA_RUN} pip install transformers "optimum-executorch @ git+https://github.com/huggingface/optimum-executorch.git@${OPTIMUM_ET_VERSION}"
453452 echo "::endgroup::"
0 commit comments