Unverified Commit 26b6ef79 authored by Nicolas Patry's avatar Nicolas Patry Committed by GitHub
Browse files

Fixing the lecture values by making sure defaults are not changed (#13976)

384 // 4 < 128 would break `doc_stride`.
parent 58bf8825
......@@ -253,7 +253,7 @@ class QuestionAnsweringPipeline(Pipeline):
if max_seq_len is None:
max_seq_len = min(self.tokenizer.model_max_length, 384)
if doc_stride is None:
doc_stride = min(max_seq_len // 4, 128)
doc_stride = min(max_seq_len // 2, 128)
if not self.tokenizer.is_fast:
features = squad_convert_examples_to_features(
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment