class_docstr: Transform indexedTokens and label (if any) of a TextFeature to a BigDL Sample.
  Need to word2idx first.
  
  >>> to_sample = TextFeatureToSample()
  creating: createTextFeatureToSample
class_docstr_tok: ["Transform","indexedTokens","and","label","(","if","any",")","of","a","TextFeature","to","a","BigDL","Sample",".","Need","to","word2idx","first",".",">",">",">","to_sample","=","TextFeatureToSample","(",")","creating",":","createTextFeatureToSample"]
code: def __init__(self, bigdl_type="float"):
      super(TextFeatureToSample, self).__init__(bigdl_type)
  
imports: import sys
  import six
  from zoo.feature.common import Preprocessing
  from zoo.feature.text import TextFeature
  from zoo.common.utils import callZooFunc
label_desc: Use image node_id 1 to create a new TextFeatureToSample object from inherited base classes: TextTransformer with example: obj = TextFeatureToSample(bigdl_type)