TextNet
This model was released on 2021-11-03 and added to Hugging Face Transformers on 2025-01-08.
TextNet
Section titled “TextNet”
Overview
Section titled “Overview”The TextNet model was proposed in FAST: Faster Arbitrarily-Shaped Text Detector with Minimalist Kernel Representation by Zhe Chen, Jiahao Wang, Wenhai Wang, Guo Chen, Enze Xie, Ping Luo, Tong Lu. TextNet is a vision backbone useful for text detection tasks. It is the result of neural architecture search (NAS) on backbones with reward function as text detection task (to provide powerful features for text detection).

TextNet backbone as part of FAST. Taken from the original paper.
This model was contributed by Raghavan, jadechoghari and nielsr.
Usage tips
Section titled “Usage tips”TextNet is mainly used as a backbone network for the architecture search of text detection. Each stage of the backbone network is comprised of a stride-2 convolution and searchable blocks. Specifically, we present a layer-level candidate set, defined as {conv3×3, conv1×3, conv3×1, identity}. As the 1×3 and 3×1 convolutions have asymmetric kernels and oriented structure priors, they may help to capture the features of extreme aspect-ratio and rotated text lines.
TextNet is the backbone for Fast, but can also be used as an efficient text/image classification, we add a TextNetForImageClassification as is it would allow people to train an image classifier on top of the pre-trained textnet weights
TextNetConfig
Section titled “TextNetConfig”[[autodoc]] TextNetConfig
TextNetImageProcessor
Section titled “TextNetImageProcessor”[[autodoc]] TextNetImageProcessor - preprocess
TextNetImageProcessorFast
Section titled “TextNetImageProcessorFast”[[autodoc]] TextNetImageProcessorFast - preprocess
TextNetModel
Section titled “TextNetModel”[[autodoc]] TextNetModel - forward
TextNetForImageClassification
Section titled “TextNetForImageClassification”[[autodoc]] TextNetForImageClassification - forward