code: def reset_the_weight_value(inputs, output_axis, threshold):
      x, w = inputs[:2]
      shape = w.shape
      from functools import reduce
  
      items = reduce(lambda x, y: x * y, shape)
      upbound = (threshold / (items / shape[output_axis])) ** 0.5
  
      # some channels less than the upbound, some greater than the upbound
      slice0, slice1 = None, None
      if output_axis == 0:
          slice0 = "[:shape[0]//2,...]"
          slice1 = "[shape[0]//2:,...]"
      if output_axis == 1:
          slice0 = "[:,:shape[1]//2,...]"
          slice1 = "[:,shape[1]//2:,...]"
      if output_axis == -1:
          slice0 = "[...,:shape[-1]//2]"
          slice1 = "[...,shape[-1]//2:]"
      exec("w.d{} = upbound * 0.9".format(slice0))
      exec("w.d{} = upbound * 2".format(slice1))
  
imports: from __future__ import absolute_import
  import nnabla
  import nnabla.functions
  import nnabla.parametric_functions
  from .helper import create_scale_bias, create_conv_weight_bias, create_affine_weight_bias, get_channel_axes
label_desc: Use image node_id 33 for calling a global function with example usage: reset_the_weight_value(inputs, output_axis, threshold) without return types