class_docstr: Class to test the shape of Jacobian with different return types.
  
  The return types have the following major cases:
  
  1. 1 trainable param, 1 measurement
  2. 1 trainable param, >1 measurement
  3. >1 trainable param, 1 measurement
  4. >1 trainable param, >1 measurement
class_docstr_tok: ["Class","to","test","the","shape","of","Jacobian","with","different","return","types",".","The","return","types","have","the","following","major","cases",":","1",".","1","trainable","param",",","1","measurement","2",".","1","trainable","param",",",">","1","measurement","3",".",">","1","trainable","param",",","1","measurement","4",".",">","1","trainable","param",",",">","1","measurement"]
docstr: Test single param multi-measurement case
docstr_tok: ["Test","single","param","multi-measurement","case"]
code: def test_1_N(self, shot_vec, op_wire):
      """Test single param multi-measurement case"""
      dev = qml.device("default.qubit", wires=6, shots=shot_vec)
      x = 0.543
  
      with qml.queuing.AnnotatedQueue() as q:
          qml.RY(
              x, wires=[op_wire]
          )  # Op acts either on wire 0 (non-zero grad) or wire 1 (zero grad)
  
          # 4 measurements
          qml.expval(qml.PauliZ(wires=0))
  
          # Note: wire 1 is skipped as a measurement to allow for zero grad case to be tested
          qml.probs(wires=[3, 2])
          qml.var(qml.Projector([1], wires=4))
          qml.var(qml.Hermitian(A, wires=5))
  
      grad_transform_shots = Shots(shot_vec)
      tape = qml.tape.QuantumScript.from_queue(
          q, shots=grad_transform_shots
      )
      # Multiple trainable params
      tape.trainable_params = {0}
  
      tapes, fn = spsa_grad(tape)
      all_res = fn(dev.execute(tapes))
  
      assert len(all_res) == grad_transform_shots.num_copies
      assert isinstance(all_res, tuple)
  
      expected_shapes = [(), (4,), (), ()]
      for meas_res in all_res:
          for res, shape in zip(meas_res, expected_shapes):
              assert isinstance(res, np.ndarray)
              assert res.shape == shape
  
imports: import numpy
  import pytest
  from pennylane import numpy
  import pennylane
  from pennylane.gradients import spsa_grad
  from pennylane.devices import DefaultQubitLegacy
  from pennylane.measurements import Shots
  from pennylane.operation import Observable, AnyWires
label_desc: Use image node_id 2 for calling the TestReturn obj's underlying member method code with example usage: obj.test_1_N(shot_vec, op_wire) without return types