class_docstr: Turn positive integers (indexes) into dense vectors of fixed size.
  The input of this layer should be 2D.
  
  This layer can only be used as the first layer in a model, you need to provide the argument
  input_length (an integer) or input_shape (a shape tuple, does not include the batch dimension).
  
  # Arguments
  input_dim: Size of the vocabulary. Int > 0.
  output_dim: Dimension of the dense embedding. Int > 0.
  init: String representation of the initialization method for the weights of the layer.
        Default is 'uniform'.
  W_regularizer: An instance of [[Regularizer]], (eg. L1 or L2 regularization),
                 applied to the embedding matrix. Default is None.
  weights: Initial weights set to this layer, which should be a numpy array of
           size (inputDim, outputDim). Default is None and in this case weights are
           initialized by the initialization method specified by 'init'.
           Otherwise, 'weights' will override 'init' to take effect.
  trainable: Whether this layer is trainable or not. Default is True.
  input_length: Positive int. The sequence length of each input.
  mask_zero: if maskZero is set to true, the input whose value equals `paddingValue`
  the output will be masked to zero vector.
  padding_value: padding value, default 0
  zero_based_id: default True and input should be 0 based. Otherwise need to be 1 base
  name: String to set the name of the layer.
        If not specified, its name will by default to be a generated string.
  
  >>> embedding = Embedding(1000, 32, input_length=10, name="embedding1")
  creating: createZooKerasEmbedding
  
  >>> import numpy as np
  >>> embedding = Embedding(10, 200, weights=np.random.random([10, 200]), input_length=10)
  creating: createZooKerasEmbedding
class_docstr_tok: ["Turn","positive","integers","(","indexes",")","into","dense","vectors","of","fixed","size",".","The","input","of","this","layer","should","be","2D",".","This","layer","can","only","be","used","as","the","first","layer","in","a","model",",","you","need","to","provide","the","argument","input_length","(","an","integer",")","or","input_shape","(","a","shape","tuple",",","does","not","include","the","batch","dimension",")",".","#","Arguments","input_dim",":","Size","of","the","vocabulary",".","Int",">","0.","output_dim",":","Dimension","of","the","dense","embedding",".","Int",">","0.","init",":","String","representation","of","the","initialization","method","for","the","weights","of","the","layer",".","Default","is","'uniform","'",".","W_regularizer",":","An","instance","of","[","[","Regularizer","]","]",",","(","eg",".","L1","or","L2","regularization",")",",","applied","to","the","embedding","matrix",".","Default","is","None",".","weights",":","Initial","weights","set","to","this","layer",",","which","should","be","a","numpy","array","of","size","(","inputDim",",","outputDim",")",".","Default","is","None","and","in","this","case","weights","are","initialized","by","the","initialization","method","specified","by","'init","'",".","Otherwise",",","'weights","'","will","override","'init","'","to","take","effect",".","trainable",":","Whether","this","layer","is","trainable","or","not",".","Default","is","True",".","input_length",":","Positive","int",".","The","sequence","length","of","each","input",".","mask_zero",":","if","maskZero","is","set","to","true",",","the","input","whose","value","equals","`","paddingValue","`","the","output","will","be","masked","to","zero","vector",".","padding_value",":","padding","value",",","default","0","zero_based_id",":","default","True","and","input","should","be","0","based",".","Otherwise","need","to","be","1","base","name",":","String","to","set","the","name","of","the","layer",".","If","not","specified",",","its","name","will","by","default","to","be","a","generated","string",".",">",">",">","embedding","=","Embedding","(","1000",",","32",",","input_length=10",",","name=","''","embedding1","''",")","creating",":","createZooKerasEmbedding",">",">",">","import","numpy","as","np",">",">",">","embedding","=","Embedding","(","10",",","200",",","weights=np.random.random","(","[","10",",","200","]",")",",","input_length=10",")","creating",":","createZooKerasEmbedding"]
code: def __init__(
      self,
      input_dim,
      output_dim,
      init="uniform",
      weights=None,
      trainable=True,
      input_length=None,
      W_regularizer=None,
      input_shape=None,
      mask_zero=False,
      padding_value=0,
      zero_based_id=True,
      **kwargs,
  ):
      if input_length:
          input_shape = (input_length,)
      super(Embedding, self).__init__(
          None,
          input_dim,
          output_dim,
          init,
          JTensor.from_ndarray(weights),
          trainable,
          W_regularizer,
          list(input_shape) if input_shape else None,
          mask_zero,
          padding_value,
          zero_based_id,
          **kwargs,
      )
  
file_path: BigDL/python/dllib/src/bigdl/dllib/keras/layers/embeddings.py
imports: import sys
  from bigdl.dllib.utils.common import JTensor
  from bigdl.dllib.utils.file_utils import callZooFunc
  from ..engine.topology import ZooKerasLayer
label_desc: Use image node_id 1 to create a new Embedding object from inherited base classes: ZooKerasLayer with example: obj = Embedding(input_dim, output_dim, init, weights, trainable, input_length, W_regularizer, input_shape, mask_zero, padding_value, zero_based_id)