Skip to content

Commit

Permalink
Update processor mapping for hub snippets (#27477)
Browse files Browse the repository at this point in the history
  • Loading branch information
amyeroberts authored Nov 14, 2023
1 parent 067c4a3 commit 303c1d6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions utils/update_metadata.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,9 +197,9 @@ def get_frameworks_table() -> pd.DataFrame:
processors[t] = "AutoProcessor"
elif t in transformers_module.models.auto.tokenization_auto.TOKENIZER_MAPPING_NAMES:
processors[t] = "AutoTokenizer"
elif t in transformers_module.models.auto.feature_extraction_auto.FEATURE_EXTRACTOR_MAPPING_NAMES:
processors[t] = "AutoFeatureExtractor"
elif t in transformers_module.models.auto.image_processing_auto.IMAGE_PROCESSOR_MAPPING_NAMES:
processors[t] = "AutoImageProcessor"
elif t in transformers_module.models.auto.feature_extraction_auto.FEATURE_EXTRACTOR_MAPPING_NAMES:
processors[t] = "AutoFeatureExtractor"
else:
# Default to AutoTokenizer if a model has nothing, for backward compatibility.
Expand Down

0 comments on commit 303c1d6

Please sign in to comment.