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-03-07 10:44:43 +00:00
2024-06-07 17:50:18 +01:00
2024-05-09 22:57:52 +02:00
2024-06-10 12:35:10 +01:00
2024-04-23 16:06:20 +01:00
2023-06-20 18:07:47 -04:00
2024-04-24 09:38:18 +02:00
2024-02-08 14:13:35 -08:00
2024-02-16 08:16:58 +01:00
2024-02-16 08:16:58 +01:00
2023-10-11 10:26:37 -07:00
2024-02-16 08:16:58 +01:00
2024-06-07 17:50:18 +01:00
2024-02-16 08:16:58 +01:00
2024-02-16 08:16:58 +01:00
2023-10-11 10:26:37 -07:00
2024-05-07 12:59:49 +02:00
2023-10-11 10:26:37 -07:00
2024-05-02 14:42:25 +01:00
2024-02-16 08:16:58 +01:00
2023-11-13 14:20:54 +01:00
2024-02-06 12:01:01 -08:00
2024-05-29 11:55:43 +01:00
2023-10-11 10:26:37 -07:00
2024-04-18 12:49:43 -04:00
2024-02-16 08:16:58 +01:00
2023-10-11 10:26:37 -07:00
2024-02-16 08:16:58 +01:00
2024-02-06 11:15:44 -08:00
2024-05-30 16:47:35 +02:00
2024-02-16 08:16:58 +01:00
2023-10-11 10:26:37 -07:00
2023-10-11 10:26:37 -07:00
2024-05-30 16:47:35 +02:00
2023-10-11 10:26:37 -07:00
2024-06-10 09:53:25 +01:00
2024-02-16 08:16:58 +01:00
2024-02-16 08:16:58 +01:00
2024-02-16 08:16:58 +01:00
2024-02-16 08:16:58 +01:00
2023-10-11 10:26:37 -07:00
2023-10-11 10:26:37 -07:00
2023-10-11 10:26:37 -07:00
2023-10-11 10:26:37 -07:00
2024-02-16 08:16:58 +01:00
2023-11-06 19:45:03 +00:00
2024-04-16 11:58:55 +02:00
2024-02-16 08:16:58 +01:00
2023-10-11 10:26:37 -07:00
2024-02-16 08:16:58 +01:00
2024-04-08 14:21:16 +01:00
2024-02-16 08:16:58 +01:00
2024-02-16 08:16:58 +01:00
2024-04-16 11:58:55 +02:00
2023-10-11 10:26:37 -07:00
2024-03-11 14:07:16 +00:00
2024-02-16 08:16:58 +01:00
2024-02-16 08:16:58 +01:00
2024-02-16 08:16:58 +01:00
2024-02-16 08:16:58 +01:00
2024-04-18 12:49:43 -04:00
2023-10-11 10:26:37 -07:00
2024-02-16 08:16:58 +01:00