skypilot

Форк
0
/
huggingface_glue_imdb_app.yaml 
31 строка · 1012.0 Байт
1
name: huggingface
2

3
resources:
4
  accelerators: V100
5
  # The above is a shorthand for <name>: <count=1>.  Same as:
6
  # accelerators: V100:1
7

8
# The setup command.  Will be run under the working directory.
9
setup: |
10
  git clone https://github.com/huggingface/transformers/
11
  # checkout to the correct version
12
  cd transformers
13
  git checkout v4.25.1
14
  pip3 install .
15
  cd examples/pytorch/text-classification
16
  # SkyPilot's default image on AWS/GCP has CUDA 11.6 (Azure 11.5).
17
  pip3 install -r requirements.txt tensorboard torch==1.12.1+cu113 --extra-index-url https://download.pytorch.org/whl/cu113
18

19
# The command to run.  Will be run under the working directory.
20
run: |
21
  cd transformers/examples/pytorch/text-classification
22
  python3 run_glue.py \
23
    --model_name_or_path bert-base-cased \
24
    --dataset_name imdb  \
25
    --do_train \
26
    --max_seq_length 128 \
27
    --per_device_train_batch_size 32 \
28
    --learning_rate 2e-5 \
29
    --max_steps 50 \
30
    --output_dir /tmp/imdb/ --overwrite_output_dir \
31
    --fp16
32

Использование cookies

Мы используем файлы cookie в соответствии с Политикой конфиденциальности и Политикой использования cookies.

Нажимая кнопку «Принимаю», Вы даете АО «СберТех» согласие на обработку Ваших персональных данных в целях совершенствования нашего веб-сайта и Сервиса GitVerse, а также повышения удобства их использования.

Запретить использование cookies Вы можете самостоятельно в настройках Вашего браузера.