From 8c7a59d58e2ce6b18384c9fcdba2fd49e5450b0e Mon Sep 17 00:00:00 2001 From: Gustaf Rydholm Date: Wed, 27 Oct 2021 22:12:36 +0200 Subject: Fix imports in transformer model --- text_recognizer/models/transformer.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'text_recognizer/models') diff --git a/text_recognizer/models/transformer.py b/text_recognizer/models/transformer.py index 50bf73d..d8cb665 100644 --- a/text_recognizer/models/transformer.py +++ b/text_recognizer/models/transformer.py @@ -1,12 +1,12 @@ """PyTorch Lightning model for base Transformers.""" -from typing import Tuple, Type, Set +from typing import Set, Tuple import attr import torch from torch import Tensor -from text_recognizer.models.metrics import CharacterErrorRate from text_recognizer.models.base import BaseLitModel +from text_recognizer.models.metrics import CharacterErrorRate @attr.s(auto_attribs=True, eq=False) @@ -76,7 +76,7 @@ class TransformerLitModel(BaseLitModel): def predict(self, x: Tensor) -> Tensor: """Predicts text in image. - + Args: x (Tensor): Image(s) to extract text from. -- cgit v1.2.3-70-g09d2