class_docstr: Choose a slice of input on the last axis given order,
  Suppose input x has two dimensions,
  output f(x) = x[:, slice_num:slice_num+1]
class_docstr_tok: ["Choose","a","slice","of","input","on","the","last","axis","given","order",",","Suppose","input","x","has","two","dimensions",",","output","f","(","x",")","=","x","[",":",",","slice_num",":","slice_num+1","]"]
docstr: Parameters
  ----------
  slice_num: int
      index of slice number
  axis: int
      axis id
docstr_tok: ["Parameters","--","--","--","--","--","slice_num",":","int","index","of","slice","number","axis",":","int","axis","id"]
code: def __init__(self, slice_num, axis=1, **kwargs):
      """
      Parameters
      ----------
      slice_num: int
          index of slice number
      axis: int
          axis id
      """
      self.slice_num = slice_num
      self.axis = axis
      super(Slice, self).__init__(**kwargs)
  
imports: import numpy
  import tensorflow
  from deepchem.models import KerasModel, layers
  from deepchem.models.losses import SigmoidCrossEntropy
  from tensorflow.keras.layers import Input, Layer, Activation, Concatenate, Lambda
  import warnings
label_desc: Use image node_id 1 to create a new Slice object from inherited base classes: Layer with example: obj = Slice(slice_num, axis)