class_docstr: Tests for the transmon drive Hamiltonian.
docstr: Test call works as expected for regular parametrized Hamiltonian
docstr_tok: ["Test","call","works","as","expected","for","regular","parametrized","Hamiltonian"]
code: def test_transmon_drive_with_regular_Parametrized_Hamiltonian(self):
      """Test call works as expected for regular parametrized Hamiltonian"""
  
      def f(p, t):
          return np.sin(p * t)
  
      H = transmon_drive(f, f, f, wires=[0])
      H += np.polyval * qml.PauliZ(0)
  
      t = 5.0
      params = [1.0, 2.0, 3.0, [0.5]]
      expected = amp_phase_freq(
          f(params[0], t) * (2 * np.pi),
          f(params[1], t),
          f(params[2], t) * (2 * np.pi),
          t,
          wire=0,
      )
      expected += np.polyval(params[3], t) * qml.PauliZ(0)
  
      assert qml.math.allclose(
          qml.matrix(H(params, t)), qml.matrix(expected)
      )
  
imports: import numpy
  import pytest
  import pennylane
  from pennylane.pulse import HardwareHamiltonian, transmon_interaction, transmon_drive
  from pennylane.pulse.transmon import TransmonSettings, a, ad, AmplitudeAndPhaseAndFreq, _reorder_AmpPhaseFreq, callable_freq_to_angular
  from pennylane.pulse.hardware_hamiltonian import HardwarePulse
  from pennylane.wires import Wires
label_desc: Use image node_id 12 for calling the TestTransmonDrive obj's underlying member method code with example usage: obj.test_transmon_drive_with_regular_Parametrized_Hamiltonian() and returns: np