__init__.py 363 字节
Newer Older
S
0.8.4  
sunyanfang01 已提交
1
__version__ = "0.8.4"
J
jiangjiajun 已提交
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17

from .core.program import PaddleProgram

program = PaddleProgram()

name_counter = dict()


def gen_name(op_name, var_name):
    name = "{}.{}".format(op_name, var_name)
    if name not in name_counter:
        name_counter[name] = 0
    else:
        name_counter[name] += 1
    name = name + "." + str(name_counter[name])
    return name