-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: aws sagemaker compatible image (#147)
The only difference is that now it pushes to registry.internal.huggingface.tech/api-inference/community/text-generation-inference/sagemaker:... instead of registry.internal.huggingface.tech/api-inference/community/text-generation-inference:sagemaker-... --------- Co-authored-by: Philipp Schmid <32632186+philschmid@users.noreply.github.com>
- Loading branch information
1 parent
c9bdaa8
commit d503e8f
Showing
4 changed files
with
86 additions
and
3 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
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,20 @@ | ||
#!/bin/bash | ||
|
||
if [[ -z "${HF_MODEL_ID}" ]]; then | ||
echo "HF_MODEL_ID must be set" | ||
exit 1 | ||
fi | ||
|
||
if [[ -n "${HF_MODEL_REVISION}" ]]; then | ||
export REVISION="${HF_MODEL_REVISION}" | ||
fi | ||
|
||
if [[ -n "${SM_NUM_GPUS}" ]]; then | ||
export NUM_SHARD="${SM_NUM_GPUS}" | ||
fi | ||
|
||
if [[ -n "${HF_MODEL_QUANTIZE}" ]]; then | ||
export QUANTIZE="${HF_MODEL_QUANTIZE}" | ||
fi | ||
|
||
text-generation-launcher --port 8080 |