tamoghna commited on
Commit
35ea5b0
·
verified ·
1 Parent(s): e5b34a1

Update modeling.py

Browse files
Files changed (1) hide show
  1. modeling.py +1 -7
modeling.py CHANGED
@@ -119,10 +119,4 @@ class SmallTransformer(PreTrainedModel):
119
  return decoder_input_ids
120
 
121
 
122
- # Register the custom model type so AutoModel can find it.
123
- # This ensures that when AutoModelForSeq2SeqLM sees 'model_type': 'small_transformer'
124
- # in your config.json, it knows to use the SmallTransformer class from this file.
125
- if SmallTransformer.config_class.model_type in PreTrainedModel._model_mapping.keys():
126
- pass
127
- else:
128
- PreTrainedModel._model_mapping.register(SmallTransformer.config_class, SmallTransformer)
 
119
  return decoder_input_ids
120
 
121
 
122
+ # No registration needed - auto_map in config.json handles this