class_docstr: To run: "python -m unittest saliency.core.guided_ig_test" from the top-level directory.
docstr: Returns gradient of a quadratic function (2 * x1 + x2)^2.
  
  The partial derivatives of the function with respect to x1 and x2 depend on
  each other. For such functions, the Guided IG produces different result
  than Integrated Gradients. TYhe difference depends on the max_dist that
  Guided IG can deviate from the IG path.
docstr_tok: ["Returns","gradient","of","a","quadratic","function","(","2","*","x1","+","x2",")","^2",".","The","partial","derivatives","of","the","function","with","respect","to","x1","and","x2","depend","on","each","other",".","For","such","functions",",","the","Guided","IG","produces","different","result","than","Integrated","Gradients",".","TYhe","difference","depends","on","the","max_dist","that","Guided","IG","can","deviate","from","the","IG","path","."]
code: def _quadratic_dep_test_func(
      self, x_value_batch, call_model_args, expected_keys
  ):
      """Returns gradient of a quadratic function (2 * x1 + x2)^2.
  
      The partial derivatives of the function with respect to x1 and x2 depend on
      each other. For such functions, the Guided IG produces different result
      than Integrated Gradients. TYhe difference depends on the max_dist that
      Guided IG can deviate from the IG path.
      """
      self.assertListEqual(expected_keys, [INPUT_OUTPUT_GRADIENTS])
      return {
          INPUT_OUTPUT_GRADIENTS: [
              [
                  8 * x_value_batch[0, 0] + 4 * x_value_batch[0, 1],
                  4 * x_value_batch[0, 0] + 2 * x_value_batch[0, 1],
              ]
          ]
      }
  
file_path: saliency/saliency/core/guided_ig_test.py
imports: import unittest
  from .None import guided_ig
  from .base import INPUT_OUTPUT_GRADIENTS
  import numpy
label_desc: Use image node_id 3 for calling the GuidedIGTest obj's underlying member method code with example usage: obj._quadratic_dep_test_func(x_value_batch, call_model_args, expected_keys) and returns: dict