velaia commited on
Commit
7272b1e
1 Parent(s): 0b16231

Fixing deprecation warnings for feature_extractor_type

Browse files

Could not find image processor class in the image processor config or the model config. Loading based on pattern matching with the model's feature extractor configuration. Please open a PR/issue to update `preprocessor_config.json` to use `image_processor_type` instead of `feature_extractor_type`. This warning will be removed in v4.40.

/Users/user/git/trocr-base-handwritten/.venv/lib/python3.12/site-packages/transformers/models/vit/feature_extraction_vit.py:28: FutureWarning: The class ViTFeatureExtractor is deprecated and will be removed in version 5 of Transformers. Please use ViTImageProcessor instead.

Files changed (1) hide show
  1. preprocessor_config.json +1 -1
preprocessor_config.json CHANGED
@@ -1,7 +1,7 @@
1
  {
2
  "do_normalize": true,
3
  "do_resize": true,
4
- "feature_extractor_type": "ViTFeatureExtractor",
5
  "image_mean": [
6
  0.5,
7
  0.5,
 
1
  {
2
  "do_normalize": true,
3
  "do_resize": true,
4
+ "image_processor_type": "ViTImageProcessor",
5
  "image_mean": [
6
  0.5,
7
  0.5,