class_docstr: Detect the language of the input corpus.
  
  We currently support three pretrained models:
  
      - model='langid'
          Use the langid implementation from
           https://github.com/saffsd/langid.py
      - model='fasttext'
          Use the fasttext model "lid.176.bin" from
           https://fasttext.cc/docs/en/language-identification.html
      - model='fasttext_compressed'
          Use the compressed fasttext model "lid.176.ftz"
          from  https://fasttext.cc/docs/en/language-identification.html
  
  .. code-block:: none
  
      References:
  
      @article{joulin2016bag,
        title={Bag of Tricks for Efficient Text Classification},
        author={Joulin, Armand and Grave, Edouard and Bojanowski, Piotr and Mikolov, Tomas},
        journal={arXiv preprint arXiv:1607.01759},
        year={2016}
      }
  
      @article{joulin2016fasttext,
        title={FastText.zip: Compressing text classification models},
        author={Joulin, Armand and Grave, Edouard and Bojanowski, Piotr and Douze, Matthijs and J{\'e}gou, H{\'e}rve and Mikolov, Tomas},
        journal={arXiv preprint arXiv:1612.03651},
        year={2016}
      }
  
      @inproceedings{lui2012langid,
        title={langid. py: An off-the-shelf language identification tool},
        author={Lui, Marco and Baldwin, Timothy},
        booktitle={Proceedings of the ACL 2012 system demonstrations},
        pages={25--30},
        year={2012},
        organization={Association for Computational Linguistics}
      }
code: def __getstate__(self):
      d = {k: v for k, v in self.__dict__.items() if k != "_model"}
      return d
  
imports: import re
  import regex
  import requests
  import unicodedata
  import os
  import warnings
  from typing import List, Pattern, Union, Tuple, Optional
  from sacremoses.normalize import MosesPunctNormalizer
  from ..utils.lazy_imports import try_import_fasttext, try_import_langid
  from ..utils.misc import download
  from ..base import get_model_zoo_home_dir, get_repo_url
label_desc: Use image node_id 4 for calling the LanguageIdentifier obj's underlying member method code with example usage: obj.__getstate__() and returns: d