Instructions to use arxtifix/Dummymodel with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use arxtifix/Dummymodel with Transformers:
# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("arxtifix/Dummymodel", device_map="auto") - Notebooks
- Google Colab
- Kaggle
paulinergt commited on
Commit ·
644971b
1
Parent(s): c69516e
init-container
Browse files- Dockerfile +28 -0
- download_model.sh +17 -0
Dockerfile
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#ARG EXOSCALE_DOCKER_REGISTRY=registry.internal.exoscale.ch
|
| 2 |
+
|
| 3 |
+
#FROM ${EXOSCALE_DOCKER_REGISTRY}/docker.io/library/ubuntu:latest
|
| 4 |
+
|
| 5 |
+
FROM ubuntu:22.04
|
| 6 |
+
|
| 7 |
+
# Install the necessary dependencies
|
| 8 |
+
RUN apt-get update && \
|
| 9 |
+
apt-get install -y \
|
| 10 |
+
bash \
|
| 11 |
+
python3 \
|
| 12 |
+
python3-pip \
|
| 13 |
+
curl \
|
| 14 |
+
unzip && \
|
| 15 |
+
rm -rf /var/lib/apt/lists/*
|
| 16 |
+
|
| 17 |
+
# Install AWS CLI
|
| 18 |
+
RUN curl "https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip" -o "awscliv2.zip"
|
| 19 |
+
RUN unzip awscliv2.zip && ./aws/install
|
| 20 |
+
|
| 21 |
+
# Copy the script which downloads the model from S3
|
| 22 |
+
COPY download_model.sh /usr/local/bin/
|
| 23 |
+
|
| 24 |
+
# Give execution permissions to the script
|
| 25 |
+
RUN chmod +x /usr/local/bin/download_model.sh
|
| 26 |
+
|
| 27 |
+
# Script to run
|
| 28 |
+
ENTRYPOINT [ "/usr/local/bin/download_model.sh" ]
|
download_model.sh
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/bin/bash
|
| 2 |
+
|
| 3 |
+
set -e
|
| 4 |
+
|
| 5 |
+
function download_object_from_bucket() {
|
| 6 |
+
local response
|
| 7 |
+
|
| 8 |
+
response=$(aws --debug s3 cp \
|
| 9 |
+
"$LLM_BUCKET" \
|
| 10 |
+
"$LOCAL_PATH" \
|
| 11 |
+
--recursive \
|
| 12 |
+
--endpoint-url $AWS_ENDPOINT_URL \
|
| 13 |
+
--region $AWS_DEFAULT_REGION)
|
| 14 |
+
|
| 15 |
+
}
|
| 16 |
+
|
| 17 |
+
download_object_from_bucket
|