Closed ftesser closed 3 years ago
I was experimenting with different values of max_seq_len, looking at the following line in the QA example:
max_seq_len
https://github.com/deepset-ai/FARM/blob/c9235f287ed92e09a46d7dc3572bf462f2ec95f7/examples/question_answering.py#L113
I noticed that the load method always sets max_seq_len=256. In fact if the load method is not explicitly set max_seq_len the value of 256 is used (https://github.com/deepset-ai/FARM/blob/c9235f287ed92e09a46d7dc3572bf462f2ec95f7/farm/infer.py#L279)
max_seq_len=256
I think that, if it is not explicit set, a better value to set should be the one loaded from the model config. This PR do that for both max_seq_len and doc_stride.
doc_stride
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 21 days if no further activity occurs.
I was experimenting with different values of
max_seq_len
, looking at the following line in the QA example:https://github.com/deepset-ai/FARM/blob/c9235f287ed92e09a46d7dc3572bf462f2ec95f7/examples/question_answering.py#L113
I noticed that the load method always sets
max_seq_len=256
. In fact if the load method is not explicitly setmax_seq_len
the value of 256 is used (https://github.com/deepset-ai/FARM/blob/c9235f287ed92e09a46d7dc3572bf462f2ec95f7/farm/infer.py#L279)I think that, if it is not explicit set, a better value to set should be the one loaded from the model config. This PR do that for both
max_seq_len
anddoc_stride
.