def test_is_pmf(): ops = LinearOperations() pmf = np.asarray([0.5, 0.5]) assert v.is_pmf(pmf, ops) pmf = np.array([0.6, 0.7]) assert not v.is_pmf(pmf, ops) pmf = np.array([1.6, -0.6]) assert not v.is_pmf(pmf, ops)
def test_is_pmf(): ops = LinearOperations() pmf = np.asarray([0.5, 0.5]) assert_true(v.is_pmf(pmf, ops)) pmf = np.array([0.6, 0.7]) assert_false(v.is_pmf(pmf, ops)) pmf = np.array([1.6, -0.6]) assert_false(v.is_pmf(pmf, ops))
def test_validate_pmf(): # Already covered by other tests ops = LinearOperations() pmf = np.asarray([0.5, 0.5]) assert v.is_pmf(pmf, ops)
def test_validate_pmf(): # Already covered by other tests ops = LinearOperations() pmf = np.asarray([0.5, 0.5]) assert_true(v.is_pmf(pmf, ops))