code: def test_symbol_fluent():
      has_grad = set(
          [
              "flatten",
              "expand_dims",
              "flip",
              "tile",
              "transpose",
              "sum",
              "nansum",
              "prod",
              "nanprod",
              "mean",
              "max",
              "min",
              "reshape",
              "broadcast_to",
              "split",
              "broadcast_axes",
              "broadcast_like",
              "pad",
              "swapaxes",
              "slice",
              "slice_axis",
              "slice_like",
              "take",
              "one_hot",
              "pick",
              "sort",
              "topk",
              "argsort",
              "argmax",
              "argmin",
              "clip",
              "abs",
              "sign",
              "sin",
              "cos",
              "tan",
              "arcsin",
              "arccos",
              "arctan",
              "degrees",
              "radians",
              "sinh",
              "cosh",
              "tanh",
              "arcsinh",
              "arccosh",
              "arctanh",
              "exp",
              "expm1",
              "log",
              "log10",
              "log2",
              "log1p",
              "sqrt",
              "rsqrt",
              "square",
              "reciprocal" "reshape_like",
              "cbrt",
              "rcbrt",
              "relu",
              "sigmoid",
              "softmax",
              "log_softmax",
              "softmin",
              "rint",
              "ceil",
              "floor",
              "trunc",
              "fix",
          ]
      )
  
      def check_fluent_regular(
          func, kwargs, shape=(5, 17, 1), equal_nan=False
      ):
          with mx.name.NameManager():
              data = mx.symbol.Variable("data")
              regular = getattr(mx.symbol, func)(
                  data, name=func + "0", **kwargs
              )
              fluent = getattr(data, func)(**kwargs)
              check_symbol_consistency(
                  regular,
                  fluent,
                  {"ctx": mx.context.current_context(), "data": shape},
                  skip_grad=func not in has_grad,
                  equal_nan=equal_nan,
              )
  
      for func in [
          "flatten",
          "norm",
          "round",
          "rint",
          "fix",
          "floor",
          "ceil",
          "trunc",
          "zeros_like",
          "ones_like",
          "abs",
          "sign",
          "sin",
          "cos",
          "degrees",
          "radians",
          "exp",
          "expm1",
          "square",
          "reciprocal",
          "argmax_channel",
          "shape_array",
          "size_array",
      ]:
          check_fluent_regular(func, {})
  
      for func in [
          "arccosh",
          "arcsin",
          "arccos",
          "arctan",
          "tan",
          "sinh",
          "cosh",
          "tanh",
          "arcsinh",
          "arctanh",
          "log",
          "log10",
          "log2",
          "log1p",
          "sqrt",
          "rsqrt",
          "cbrt",
          "rcbrt",
          "relu",
          "sigmoid",
          "softmax",
          "log_softmax",
          "softmin",
      ]:
          check_fluent_regular(func, {}, equal_nan=True)
  
      for func in [
          "expand_dims",
          "flip",
          "sort",
          "topk",
          "argsort",
          "argmax",
          "argmin",
      ]:
          check_fluent_regular(func, {"axis": 1})
  
      check_fluent_regular("one_hot", {"depth": 15})
      check_fluent_regular("tile", {"reps": (1, 2)})
      check_fluent_regular("repeat", {"repeats": 3})
      check_fluent_regular("transpose", {"axes": (1, 0, 2)})
      check_fluent_regular(
          "split", {"axis": 2, "num_outputs": 3}, shape=(5, 17, 6)
      )
      check_fluent_regular(
          "slice",
          {"begin": (2, 5, 1), "end": (4, 7, 6)},
          shape=(5, 17, 6),
      )
      check_fluent_regular(
          "slice_axis", {"axis": 1, "begin": 5, "end": 7}
      )
      check_fluent_regular(
          "slice_like",
          {"axes": (0, -2), "shape_like": mx.sym.zeros((3, 3))},
      )
      check_fluent_regular("clip", {"a_min": 0.25, "a_max": 0.75})
      check_fluent_regular(
          "broadcast_axes", {"axis": (2,), "size": (5,)}
      )
      check_fluent_regular(
          "broadcast_like",
          {
              "rhs": mx.sym.ones((1, 5)),
              "lhs_axes": (0,),
              "rhs_axes": (1,),
          },
          shape=(1, 9),
      )
      check_fluent_regular(
          "pad",
          {"mode": "constant", "pad_width": (0, 0, 0, 0, 3, 0, 0, 4)},
          shape=(5, 17, 2, 3),
      )
      check_fluent_regular(
          "reshape_like",
          {"rhs": mx.sym.ones((30, 17))},
          shape=(5, 17, 2, 3),
      )
  
      for func in [
          "sum",
          "nansum",
          "prod",
          "nanprod",
          "mean",
          "max",
          "min",
          "norm",
      ]:
          check_fluent_regular(func, {"axis": (1, 2)})
  
      check_fluent_regular("reshape", {"shape": (17, 1, 5)})
      check_fluent_regular("broadcast_to", {"shape": (5, 17, 47)})
      check_fluent_regular(
          "squeeze", {"axis": (1, 3)}, shape=(2, 1, 3, 1, 4)
      )
      check_fluent_regular("squeeze", {}, shape=(2, 1, 3, 1, 4))
  
imports: import copy
  import sys
  import os
  import logging
  import re
  import json
  import mxnet
  import numpy
  from common import assertRaises, models, TemporaryDirectory
  from mxnet.base import NotImplementedForSymbol
  from mxnet.test_utils import discard_stderr, rand_shape_nd, use_np, environment
  from mxnet.util import np_shape
  import pickle
label_desc: Use image node_id 12 for calling a global function with example usage: test_symbol_fluent() without return types