Pavel Iakubovskii
517df566f5
Decorators for deprecation and named arguments validation (#30799)
* Fix do_reduce_labels for maskformer image processor
* Deprecate reduce_labels in favor to do_reduce_labels
* Deprecate reduce_labels in favor to do_reduce_labels (segformer)
* Deprecate reduce_labels in favor to do_reduce_labels (oneformer)
* Deprecate reduce_labels in favor to do_reduce_labels (maskformer)
* Deprecate reduce_labels in favor to do_reduce_labels (mask2former)
* Fix typo
* Update mask2former test
* fixup
* Update segmentation examples
* Update docs
* Fixup
* Imports fixup
* Add deprecation decorator draft
* Add deprecation decorator
* Fixup
* Add deprecate_kwarg decorator
* Validate kwargs decorator
* Kwargs validation (beit)
* fixup
* Kwargs validation (mask2former)
* Kwargs validation (maskformer)
* Kwargs validation (oneformer)
* Kwargs validation (segformer)
* Better message
* Fix oneformer processor save-load test
* Update src/transformers/utils/deprecation.py
Co-authored-by: amyeroberts <22614925+amyeroberts@users.noreply.github.com>
* Update src/transformers/utils/deprecation.py
Co-authored-by: amyeroberts <22614925+amyeroberts@users.noreply.github.com>
* Update src/transformers/utils/deprecation.py
Co-authored-by: Pablo Montalvo <39954772+molbap@users.noreply.github.com>
* Update src/transformers/utils/deprecation.py
Co-authored-by: Pablo Montalvo <39954772+molbap@users.noreply.github.com>
* Better handle classmethod warning
* Fix typo, remove warn
* Add header
* Docs and `additional_message`
* Move to filter decorator ot generic
* Proper deprecation for semantic segm scripts
* Add to __init__ and update import
* Basic tests for filter decorator
* Fix doc
* Override `to_dict()` to pop depracated `_max_size`
* Pop unused parameters
* Fix trailing whitespace
* Add test for deprecation
* Add deprecation warning control parameter
* Update generic test
* Fixup deprecation tests
* Introduce init service kwargs
* Revert popping unused params
* Revert oneformer test
* Allow "metadata" to pass
* Better docs
* Fix test
* Add notion in docstring
* Fix notification for both names
* Add func name to warning message
* Fixup
---------
Co-authored-by: amyeroberts <22614925+amyeroberts@users.noreply.github.com>
Co-authored-by: Pablo Montalvo <39954772+molbap@users.noreply.github.com>
2024-06-10 12:35:10 +01:00
..
2024-05-31 14:16:23 +02:00
2022-02-23 15:46:28 -05:00
2023-10-09 11:04:57 +02:00
2024-05-15 10:02:31 -04:00
2024-05-13 18:14:36 +02:00
2024-03-19 14:43:02 +00:00
2024-04-22 13:15:28 +01:00
2024-06-06 15:21:32 +05:00
2024-06-10 12:35:10 +01:00
2024-05-30 15:25:43 +01:00
2024-02-29 03:56:16 +01:00
2024-06-07 17:50:18 +01:00
2024-06-03 14:55:10 +01:00
2023-12-07 10:00:08 +01:00
2024-05-22 06:40:15 +02:00
2024-05-22 06:40:15 +02:00
2024-06-07 15:43:34 +01:00
2024-06-10 12:35:10 +01:00
2023-12-20 18:33:17 +00:00
2024-03-06 10:57:04 +00:00
2023-11-15 14:10:39 +01:00
2024-05-29 11:55:43 +01:00
2023-06-15 07:30:24 -04:00
2024-03-15 14:18:41 +00:00
2024-02-20 16:20:20 +01:00
2024-03-15 14:18:41 +00:00
2024-05-21 13:56:52 +01:00
2024-06-07 19:40:26 +01:00
2024-05-16 10:56:11 +01:00
2024-01-23 10:28:23 +01:00
2024-05-13 15:59:46 +01:00
2024-03-21 14:04:11 +00:00
2024-06-07 07:50:35 -04:00
2024-06-07 17:50:18 +01:00
2024-01-19 09:59:14 +00:00
2023-09-05 10:12:25 +02:00
2024-05-24 08:38:58 -07:00
2024-06-03 10:53:15 +02:00