class_docstr: Test that calling the ParametrizedHamiltonian behaves as expected.
docstr: Test that the ParametrizedHamiltonian can be created and called to initialize an
  operator consisting of qutrit operations
docstr_tok: ["Test","that","the","ParametrizedHamiltonian","can","be","created","and","called","to","initialize","an","operator","consisting","of","qutrit","operations"]
code: def test_call_with_qutrit_operators(self):
      """Test that the ParametrizedHamiltonian can be created and called to initialize an
      operator consisting of qutrit operations"""
  
      def f(x, t):
          return x + 2 * t
  
      coeffs = [f, 2]
      obs = [
          qml.GellMann(wires=0, index=1),
          qml.GellMann(wires=0, index=2),
      ]
  
      H = ParametrizedHamiltonian(coeffs, obs)
  
      assert isinstance(H([2], 4), qml.ops.Sum)
      assert (
          repr(H([2], t=4))
          == "(2*(GellMann2(wires=[0]))) + (10*(GellMann1(wires=[0])))"
      )
      assert np.all(
          qml.matrix(H([2], 4))
          == np.array(
              [
                  [0.0 + 0.0j, 10.0 - 2.0j, 0.0 + 0.0j],
                  [10.0 + 2.0j, 0.0 + 0.0j, 0.0 + 0.0j],
                  [0.0 + 0.0j, 0.0 + 0.0j, 0.0 + 0.0j],
              ]
          )
      )
  
imports: import pytest
  import pennylane
  from pennylane import numpy
  from pennylane.pulse import ParametrizedHamiltonian
  from pennylane.wires import Wires
label_desc: Use image node_id 3 for calling the TestCall obj's underlying member method code with example usage: obj.test_call_with_qutrit_operators() and returns: unknown