Skip to content

Commit 1d288e1

Browse files
committed
update some parameters in finetuning bert tutorial
1 parent 3967523 commit 1d288e1

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

Diff for: machine-learning/nlp/bert-text-classification/finetune-bert.ipynb

+2-2
Original file line numberDiff line numberDiff line change
@@ -208,8 +208,8 @@
208208
" logging_dir='./logs', # directory for storing logs\n",
209209
" load_best_model_at_end=True, # load the best model when finished training (default metric is loss)\n",
210210
" # but you can specify `metric_for_best_model` argument to change to accuracy or other metric\n",
211-
" logging_steps=200, # log & save weights each logging_steps\n",
212-
" save_steps=200,\n",
211+
" logging_steps=400, # log & save weights each logging_steps\n",
212+
" save_steps=400,\n",
213213
" evaluation_strategy=\"steps\", # evaluate each `logging_steps`\n",
214214
")"
215215
]

Diff for: machine-learning/nlp/bert-text-classification/train.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,8 @@ def compute_metrics(pred):
9292
logging_dir='./logs', # directory for storing logs
9393
load_best_model_at_end=True, # load the best model when finished training (default metric is loss)
9494
# but you can specify `metric_for_best_model` argument to change to accuracy or other metric
95-
logging_steps=200, # log & save weights each logging_steps
96-
save_steps=200,
95+
logging_steps=400, # log & save weights each logging_steps
96+
save_steps=400,
9797
evaluation_strategy="steps", # evaluate each `logging_steps`
9898
)
9999

0 commit comments

Comments
 (0)