Simplify soft dependencies and update the dummy-creation process (#36827)
* Reverse dependency map shouldn't be created when test_all is set * [test_all] Remove dummies * Modular fixes * Update utils/check_repo.py Co-authored-by: Pablo Montalvo <39954772+molbap@users.noreply.github.com> * [test_all] Better docs * [test_all] Update src/transformers/commands/chat.py Co-authored-by: Joao Gante <joaofranciscocardosogante@gmail.com> * [test_all] Remove deprecated AdaptiveEmbeddings from the tests * [test_all] Doc builder * [test_all] is_dummy * [test_all] Import utils * [test_all] Doc building should not require all deps --------- Co-authored-by: Pablo Montalvo <39954772+molbap@users.noreply.github.com> Co-authored-by: Joao Gante <joaofranciscocardosogante@gmail.com>
This commit is contained in:
@@ -48,9 +48,9 @@ class TextClassificationPipelineTests(unittest.TestCase):
|
||||
model_mapping = MODEL_FOR_SEQUENCE_CLASSIFICATION_MAPPING
|
||||
tf_model_mapping = TF_MODEL_FOR_SEQUENCE_CLASSIFICATION_MAPPING
|
||||
|
||||
if model_mapping is not None:
|
||||
if not hasattr(model_mapping, "is_dummy"):
|
||||
model_mapping = {config: model for config, model in model_mapping.items() if config.__name__ not in _TO_SKIP}
|
||||
if tf_model_mapping is not None:
|
||||
if not hasattr(tf_model_mapping, "is_dummy"):
|
||||
tf_model_mapping = {
|
||||
config: model for config, model in tf_model_mapping.items() if config.__name__ not in _TO_SKIP
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user