Files
HuggingFace_transformer/tests
Nicolas Patry aad95c7cde Removed max_length from being mandatory within generate. (#11314)
* Removed `max_length` from being mandatory within `generate`.

- Moving on to fully using `StoppingCriteria` for `greedy` and `sample`
modes.
- `max_length` still used for `beam_search` and `group_beam_search`
(Follow up PR)
- Fixes a bug with MaxLengthStoppingCriteria (we should stop as soon a
we hit the max_length, the comparison needs to be or equal, that affects
the tests).
- Added options to use `logits_processor` and `stopping_criteria`
directly within `generate` function (so some users can define their own
`logits_processor` and `stopping_criteria`).
- Modified the backward compat tests to make sure we issue a warning.

* Fix `max_length` argument in `generate`.

* Moving validate to being functional.

- Renamed `smax_length` to `stoppping_max_length`.

* Removing `logits_processor` and `stopping_criteria` from `generate`
arguments.

* Deepcopy.

* Fix global variable name.
2021-04-21 11:56:45 +02:00
..
2021-04-06 19:20:08 -04:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00
2021-02-08 13:25:09 +03:00
2021-01-27 21:25:11 +03:00
2020-12-07 18:36:34 -05:00
2021-03-09 17:35:07 +03:00
2020-12-09 10:32:43 -05:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00
2021-03-17 16:15:14 +03:00
2021-01-27 21:25:11 +03:00
2021-02-18 06:29:43 -05:00
2020-12-07 18:36:34 -05:00
2021-03-11 13:38:29 -05:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00
2021-03-30 08:51:34 +03:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00
2020-12-07 18:36:34 -05:00