class_docstr: Unit tests for the counts.process_samples method
docstr: Test that the counts output is correct when all_outcomes is passed
  for composite mid-circuit measurement values.
docstr_tok: ["Test","that","the","counts","output","is","correct","when","all_outcomes","is","passed","for","composite","mid-circuit","measurement","values","."]
code: def test_counts_all_outcomes_composite_measurement_value(self):
      """Test that the counts output is correct when all_outcomes is passed
      for composite mid-circuit measurement values."""
      shots = 1000
      samples = np.zeros((shots, 2)).astype(np.int64)
      m0 = qml.measure(0)
      m1 = qml.measure(1)
      mv = (m0 - 1) * 2 * (m1 + 1) - 2  # 00 equates to -4
  
      result1 = qml.counts(mv, all_outcomes=False).process_samples(
          samples, wire_order=[0, 1]
      )
  
      assert len(result1) == 1
      assert set(result1.keys()) == {-4}
      assert result1[-4] == shots
  
      result2 = qml.counts(mv, all_outcomes=True).process_samples(
          samples, wire_order=[0, 1]
      )
  
      # Possible outcomes are -4, -6, -2
      assert len(result2) == 3
      assert set(result2.keys()) == {-6, -4, -2}
      assert result2[-4] == shots
      assert result2[-6] == result2[-2] == 0
  
imports: import copy
  import numpy
  import pytest
  import pennylane
  from pennylane.measurements import AllCounts, Counts, CountsMP
  from pennylane.wires import Wires
label_desc: Use image node_id 13 for calling the TestProcessSamples obj's underlying member method code with example usage: obj.test_counts_all_outcomes_composite_measurement_value() without return types