예제 #1
0
  def __init__(self, op, op_type, tflite_interpreter):
      Layer.__init__(self, op, op_type, tflite_interpreter)

      if op.BuiltinOptions() is None:
          self.tflite_reshape_parser = None
      else:
          self.tflite_reshape_parser = ReshapeOptions()
          self.tflite_reshape_parser.Init(op.BuiltinOptions().Bytes, op.BuiltinOptions().Pos)
예제 #2
0
 def __init__(self, op, op_type, tflite_interpreter):
     Layer.__init__(self, op, op_type, tflite_interpreter)
     self.node_name = '{}_Fused'.format(self.node_name)
예제 #3
0
 def __init__(self, op, op_type, tflite_interpreter):
     Layer.__init__(self, op, op_type, tflite_interpreter)
예제 #4
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_avgpool_parser = Pool2DOptions()
        self.tflite_avgpool_parser.Init(self.op.BuiltinOptions().Bytes,
                                        self.op.BuiltinOptions().Pos)
예제 #5
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_mean_parser = ReducerOptions()
        self.tflite_mean_parser.Init(self.op.BuiltinOptions().Bytes,
                                     self.op.BuiltinOptions().Pos)
예제 #6
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_l2norm_parser = L2NormOptions()
        self.tflite_l2norm_parser.Init(op.BuiltinOptions().Bytes,
                                       op.BuiltinOptions().Pos)
예제 #7
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_squeeze_parser = SqueezeOptions()
        self.tflite_squeeze_parser.Init(op.BuiltinOptions().Bytes,
                                        op.BuiltinOptions().Pos)
예제 #8
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_fc_parser = FullyConnectedOptions()
        self.tflite_fc_parser.Init(self.op.BuiltinOptions().Bytes,
                                   self.op.BuiltinOptions().Pos)
예제 #9
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_concat_parser = ConcatenationOptions()
        self.tflite_concat_parser.Init(self.op.BuiltinOptions().Bytes,
                                       self.op.BuiltinOptions().Pos)
예제 #10
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_depth2space_parser = DepthToSpaceOptions()
        self.tflite_depth2space_parser.Init(op.BuiltinOptions().Bytes,
                                            op.BuiltinOptions().Pos)
예제 #11
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_space2depth_parser = SpaceToDepthOptions()
        self.tflite_space2depth_parser.Init(op.BuiltinOptions().Bytes,
                                            op.BuiltinOptions().Pos)
예제 #12
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_tconv_parser = TransposeConvOptions()
        self.tflite_tconv_parser.Init(op.BuiltinOptions().Bytes,
                                      op.BuiltinOptions().Pos)
예제 #13
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_resize_bilinear_parser = ResizeBilinearOptions()
        self.tflite_resize_bilinear_parser.Init(self.op.BuiltinOptions().Bytes,
                                                self.op.BuiltinOptions().Pos)
예제 #14
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_resize_nn_parser = ResizeNearestNeighborOptions()
        self.tflite_resize_nn_parser.Init(self.op.BuiltinOptions().Bytes,
                                          self.op.BuiltinOptions().Pos)
예제 #15
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_conv_parser = DepthwiseConv2DOptions()
        self.tflite_conv_parser.Init(self.op.BuiltinOptions().Bytes,
                                     self.op.BuiltinOptions().Pos)
예제 #16
0
    def __init__(self, op, op_type, tflite_interpreter):
        Layer.__init__(self, op, op_type, tflite_interpreter)

        self.tflite_leaky_relu_parser = LeakyReluOptions()
        self.tflite_leaky_relu_parser.Init(op.BuiltinOptions().Bytes,
                                           op.BuiltinOptions().Pos)