class_docstr: SmilesToSeq Featurizer takes a SMILES string, and turns it into a sequence.
  Details taken from [1]_.
  
  SMILES strings smaller than a specified max length (max_len) are padded using
  the PAD token while those larger than the max length are not considered. Based
  on the paper, there is also the option to add extra padding (pad_len) on both
  sides of the string after length normalization. Using a character to index (char_to_idx)
  mapping, the SMILES characters are turned into indices and the
  resulting sequence of indices serves as the input for an embedding layer.
  
  References
  ----------
  .. [1] Goh, Garrett B., et al. "Using rule-based labels for weak supervised
      learning: a ChemNet for transferable chemical property prediction."
      Proceedings of the 24th ACM SIGKDD International Conference on Knowledge
      Discovery & Data Mining. 2018.
  
  Note
  ----
  This class requires RDKit to be installed.
class_docstr_tok: ["SmilesToSeq","Featurizer","takes","a","SMILES","string",",","and","turns","it","into","a","sequence",".","Details","taken","from","[","1","]","_",".","SMILES","strings","smaller","than","a","specified","max","length","(","max_len",")","are","padded","using","the","PAD","token","while","those","larger","than","the","max","length","are","not","considered",".","Based","on","the","paper",",","there","is","also","the","option","to","add","extra","padding","(","pad_len",")","on","both","sides","of","the","string","after","length","normalization",".","Using","a","character","to","index","(","char_to_idx",")","mapping",",","the","SMILES","characters","are","turned","into","indices","and","the","resulting","sequence","of","indices","serves","as","the","input","for","an","embedding","layer",".","References","--","--","--","--","--","..","[","1","]","Goh",",","Garrett","B.",",","et","al",".","``","Using","rule-based","labels","for","weak","supervised","learning",":","a","ChemNet","for","transferable","chemical","property","prediction",".","''","Proceedings","of","the","24th","ACM","SIGKDD","International","Conference","on","Knowledge","Discovery","&","Data","Mining",".","2018",".","Note","--","--","This","class","requires","RDKit","to","be","installed","."]
docstr: Featurizes a SMILES sequence.
  
  Parameters
  ----------
  datapoints: rdkit.Chem.rdchem.Mol
      RDKit Mol object
  
  Returns
  -------
  np.ndarray
      A 1D array of a SMILES sequence.
      If the length of SMILES is longer than `max_len`, this value is an empty array.
docstr_tok: ["Featurizes","a","SMILES","sequence",".","Parameters","--","--","--","--","--","datapoints",":","rdkit.Chem.rdchem.Mol","RDKit","Mol","object","Returns","--","--","--","-","np.ndarray","A","1D","array","of","a","SMILES","sequence",".","If","the","length","of","SMILES","is","longer","than","`","max_len","`",",","this","value","is","an","empty","array","."]
code: def _featurize(self, datapoint: RDKitMol, **kwargs) -> np.ndarray:
      """Featurizes a SMILES sequence.
  
      Parameters
      ----------
      datapoints: rdkit.Chem.rdchem.Mol
          RDKit Mol object
  
      Returns
      -------
      np.ndarray
          A 1D array of a SMILES sequence.
          If the length of SMILES is longer than `max_len`, this value is an empty array.
  
      """
      try:
          from rdkit import Chem
      except ModuleNotFoundError:
          raise ImportError(
              "This class requires RDKit to be installed."
          )
  
      if "mol" in kwargs:
          datapoint = kwargs.get("mol")
          raise DeprecationWarning(
              'Mol is being phased out as a parameter, please pass "datapoint" instead.'
          )
      smile = Chem.MolToSmiles(datapoint)
      if len(smile) > self.max_len:
          return np.array([])
  
      smile_list = list(smile)
      # Extend shorter strings with padding
      if len(smile) < self.max_len:
          smile_list.extend([PAD_TOKEN] * (self.max_len - len(smile)))
  
      # Padding before and after
      smile_list += [PAD_TOKEN] * self.pad_len
      smile_list = [PAD_TOKEN] * self.pad_len + smile_list
  
      smile_seq = self.to_seq(smile_list)
      return smile_seq
  
file_path: deepchem/deepchem/feat/molecule_featurizers/smiles_to_seq.py
imports: from typing import Dict, List
  import numpy
  import pandas
  from deepchem.utils.typing import RDKitMol
  from deepchem.feat.base_classes import MolecularFeaturizer
label_desc: Use image node_id 5 for calling the SmilesToSeq obj's underlying member method code with example usage: obj._featurize(datapoint) and returns: smile_seq, np