ScyKindness
commited on
Commit
•
2a77313
1
Parent(s):
3006c0c
Update README.md
Browse files
README.md
CHANGED
@@ -1,34 +1,2 @@
|
|
1 |
-
|
2 |
-
|
3 |
-
---
|
4 |
-
import sagemaker
|
5 |
-
from sagemaker.huggingface import HuggingFace
|
6 |
-
|
7 |
-
# gets role for executing training job
|
8 |
-
role = sagemaker.get_execution_role()
|
9 |
-
hyperparameters = {
|
10 |
-
'model_name_or_path':'ScyKindness/Hatsune_Miku',
|
11 |
-
'output_dir':'/opt/ml/model'
|
12 |
-
# add your remaining hyperparameters
|
13 |
-
# more info here https://github.com/huggingface/transformers/tree/v4.17.0/examples/pytorch/language-modeling
|
14 |
-
}
|
15 |
-
|
16 |
-
# git configuration to download our fine-tuning script
|
17 |
-
git_config = {'repo': 'https://github.com/huggingface/transformers.git','branch': 'v4.17.0'}
|
18 |
-
|
19 |
-
# creates Hugging Face estimator
|
20 |
-
huggingface_estimator = HuggingFace(
|
21 |
-
entry_point='run_clm.py',
|
22 |
-
source_dir='./examples/pytorch/language-modeling',
|
23 |
-
instance_type='ml.p3.2xlarge',
|
24 |
-
instance_count=1,
|
25 |
-
role=role,
|
26 |
-
git_config=git_config,
|
27 |
-
transformers_version='4.17.0',
|
28 |
-
pytorch_version='1.10.2',
|
29 |
-
py_version='py36',
|
30 |
-
hyperparameters = hyperparameters
|
31 |
-
)
|
32 |
-
|
33 |
-
# starting the train job
|
34 |
-
huggingface_estimator.fit()
|
|
|
1 |
+
git lfs install
|
2 |
+
git clone https://huggingface.co/microsoft/DialoGPT-large
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|