Browse Source

add

pull/337/head
wjm 4 years ago
parent
commit
150a0d8cc2
2 changed files with 8 additions and 1 deletions
  1. +1
    -1
      parser/func_to_graph/func2graph.py
  2. +7
    -0
      tests/ut/parser/testcase/onnx_parser_testcase/onnx_model/if.py

+ 1
- 1
parser/func_to_graph/func2graph.py View File

@@ -1,4 +1,4 @@
#!/usr/bin/python3
#!/usr/bin/env python3
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
#------------------------------------------------------------------- #-------------------------------------------------------------------
# Purpose: # Purpose:


+ 7
- 0
tests/ut/parser/testcase/onnx_parser_testcase/onnx_model/if.py View File

@@ -1,3 +1,10 @@
#!/usr/bin/env python3
# -*- coding: UTF-8 -*-
#-------------------------------------------------------------------
# Purpose:
# Copyright 2021 Huawei Technologies Co., Ltd. All rights reserved.
#-------------------------------------------------------------------

# Given a bool scalar input cond. # Given a bool scalar input cond.
# return constant tensor x if cond is True, otherwise return constant tensor y. # return constant tensor x if cond is True, otherwise return constant tensor y.
import numpy as np import numpy as np


Loading…
Cancel
Save