def METHOD_NAME(backend):
    nq, ns = 2, 10000
    c = tc.Circuit(nq)
    c.H(0)
    c.cnot(0, 1)
    psi = c.state()
    bell_state = psi[:, None] @ psi[None, :]
    pauli_strings = tc.backend.convert_to_tensor(np.random.randint(1, 4, size=(ns, nq)))
    status = tc.backend.convert_to_tensor(np.random.rand(ns, 5))
    lss_states = shadow_snapshots(c.state(), pauli_strings, status)
    sdw_state = global_shadow_state(lss_states)
    sdw_state1 = global_shadow_state1(lss_states)
    np.testing.assert_allclose(sdw_state, bell_state, atol=0.1)
    np.testing.assert_allclose(sdw_state1, bell_state, atol=0.1)