class_docstr: Spacy based NP annotator - uses models.SequenceChunker model for annotation
  
  Args:
      model (SequenceChunker): a chunker model
      word_vocab (Vocabulary): word-id vocabulary of the model
      char_vocab (Vocabulary): char id vocabulary of words of the model
      chunk_vocab (Vocabulary): chunk tag vocabulary of the model
      batch_size (int, optional): inference batch size
docstr: Load a NPAnnotator annotator
  
  Args:
      model_path (str): path to trained model
      parameter_path (str): path to model parameters
      batch_size (int, optional): inference batch_size
      use_cudnn (bool, optional): use gpu for inference (cudnn cells)
  
  Returns:
      NPAnnotator class with loaded model
code: def load(
      cls,
      model_path: str,
      parameter_path: str,
      batch_size: int = 32,
      use_cudnn: bool = False,
  ):
      """
      Load a NPAnnotator annotator
  
      Args:
          model_path (str): path to trained model
          parameter_path (str): path to model parameters
          batch_size (int, optional): inference batch_size
          use_cudnn (bool, optional): use gpu for inference (cudnn cells)
  
      Returns:
          NPAnnotator class with loaded model
      """
  
      _model_path = path.join(
          path.dirname(path.realpath(__file__)), model_path
      )
      validate_existing_filepath(_model_path)
      _parameter_path = path.join(
          path.dirname(path.realpath(__file__)), parameter_path
      )
      validate_existing_filepath(_parameter_path)
  
      model = SequenceChunker(use_cudnn=use_cudnn)
      model.load(_model_path)
      with open(_parameter_path, "rb") as fp:
          model_params = pickle.load(fp)
          word_vocab = model_params["word_vocab"]
          chunk_vocab = model_params["chunk_vocab"]
          char_vocab = model_params.get("char_vocab", None)
      return cls(model, word_vocab, char_vocab, chunk_vocab, batch_size)
  
imports: import pickle
  from os import path
  import numpy
  import spacy
  from spacy.tokens import Doc
  from spacy.tokens import Span
  from nlp_architect.models.chunker import SequenceChunker
  from nlp_architect.utils.generic import pad_sentences
  from nlp_architect.utils.io import validate_existing_filepath
  from nlp_architect.utils.text import extract_nps, Stopwords
label_desc: Use image node_id 2 for calling the NPAnnotator obj's underlying member method code with example usage: obj.load(cls, model_path, parameter_path, batch_size, use_cudnn) and returns: cls