diff options
Diffstat (limited to 'src/text_recognizer/models/transformer_model.py')
-rw-r--r-- | src/text_recognizer/models/transformer_model.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/text_recognizer/models/transformer_model.py b/src/text_recognizer/models/transformer_model.py index a912122..12e497f 100644 --- a/src/text_recognizer/models/transformer_model.py +++ b/src/text_recognizer/models/transformer_model.py @@ -50,13 +50,15 @@ class TransformerModel(Model): self.init_token = dataset_args["args"]["init_token"] self.pad_token = dataset_args["args"]["pad_token"] self.eos_token = dataset_args["args"]["eos_token"] - self.max_len = 120 + self.lower = dataset_args["args"]["lower"] + self.max_len = 100 if self._mapper is None: self._mapper = EmnistMapper( init_token=self.init_token, pad_token=self.pad_token, eos_token=self.eos_token, + lower=self.lower, ) self.tensor_transform = ToTensor() |