def build_backward_graph(net, output_shapes, inputs, execute=True): inputs = append_sens_to_inputs(output_shapes, inputs) net = gen_backward_net(net, len(inputs) - 1) net.set_train() _executor.compile(net, inputs) if execute: _executor(net, inputs)
def build_construct_graph(net, *inputs, execute=True): net.set_train() _executor.compile(net, *inputs) if execute: _executor(net, inputs)