def testFloat(self): with session.Session().as_default() as sess: in_tensor = array_ops.placeholder( shape=[1, 16, 16, 3], dtype=dtypes.float32) _ = in_tensor + in_tensor filename = self._saveFrozenGraph(sess) model_coverage.test_frozen_graph(filename, ['Placeholder'], ['add'])
def testMultipleOutputs(self): with session.Session().as_default() as sess: in_tensor_1 = array_ops.placeholder( shape=[1, 16], dtype=dtypes.float32, name='inputA') in_tensor_2 = array_ops.placeholder( shape=[1, 16], dtype=dtypes.float32, name='inputB') weight = constant_op.constant(-1.0, shape=[16, 16]) bias = constant_op.constant(-1.0, shape=[16]) layer = math_ops.matmul(in_tensor_1, weight) + bias _ = math_ops.reduce_mean(math_ops.square(layer - in_tensor_2)) filename = self._saveFrozenGraph(sess) model_coverage.test_frozen_graph(filename, ['inputA', 'inputB'], ['add', 'Mean'])