// Generate data
for v, generator in o.generator_assign.items():
dest_context = config.global_config.default_context if not o.forward_sequence or v not in o.forward_sequence[
0].inputs else None
let_data_to_variable(v.variable_instance,
data=generator(v.shape), ctx=dest_context,
variable_name=v.name)
After Change
o.target.backward(
clear_buffer=True, communicator_callbacks=comm.all_reduce_callback(params, 2 << 10))
else:
o.target.backward(clear_buffer=True)
// Update
if iter % o.update_interval == o.update_interval - 1:
if o.weight_decay > 0: