Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
strategy_pair = np.array([1, 0]), np.array([0, 1])
support_pair = [0], [1]
self.assertFalse(is_ne(strategy_pair, support_pair, (A, B)))
A = np.array([[1, -1], [-1, 1]])
strategy_pair = np.array([1 / 2, 1 / 2]), np.array([1 / 2, 1 / 2])
support_pair = [0, 1], [0, 1]
self.assertTrue(is_ne(strategy_pair, support_pair, (A, -A)))
A = np.array([[0, 1, -1], [-1, 0, 1], [1, -1, 0]])
strategy_pair = (
np.array([1 / 3, 1 / 3, 1 / 3]),
np.array([1 / 3, 1 / 3, 1 / 3]),
)
support_pair = [0, 1, 2], [0, 1, 2]
self.assertTrue(is_ne(strategy_pair, support_pair, (A, -A)))
strategy_pair = (np.array([1, 0, 0]), np.array([1, 0, 0]))
support_pair = [0], [0]
self.assertFalse(is_ne(strategy_pair, support_pair, (A, -A)))
A = np.array(
[[160, 205, 44], [175, 180, 45], [201, 204, 50], [120, 207, 49]]
)
B = np.array([[2, 2, 2], [1, 0, 0], [3, 4, 1], [4, 1, 2]])
self.assertTrue(
is_ne(
(
np.array((0, 0, 3 / 4, 1 / 4)),
np.array((1 / 28, 27 / 28, 0)),
),
(np.array([2, 3]), np.array([0, 1])),
A = np.array([[1, -1], [-1, 1]])
strategy_pair = np.array([1 / 2, 1 / 2]), np.array([1 / 2, 1 / 2])
support_pair = [0, 1], [0, 1]
self.assertTrue(is_ne(strategy_pair, support_pair, (A, -A)))
A = np.array([[0, 1, -1], [-1, 0, 1], [1, -1, 0]])
strategy_pair = (
np.array([1 / 3, 1 / 3, 1 / 3]),
np.array([1 / 3, 1 / 3, 1 / 3]),
)
support_pair = [0, 1, 2], [0, 1, 2]
self.assertTrue(is_ne(strategy_pair, support_pair, (A, -A)))
strategy_pair = (np.array([1, 0, 0]), np.array([1, 0, 0]))
support_pair = [0], [0]
self.assertFalse(is_ne(strategy_pair, support_pair, (A, -A)))
A = np.array(
[[160, 205, 44], [175, 180, 45], [201, 204, 50], [120, 207, 49]]
)
B = np.array([[2, 2, 2], [1, 0, 0], [3, 4, 1], [4, 1, 2]])
self.assertTrue(
is_ne(
(
np.array((0, 0, 3 / 4, 1 / 4)),
np.array((1 / 28, 27 / 28, 0)),
),
(np.array([2, 3]), np.array([0, 1])),
(A, B),
)
np.array([1 / 3, 1 / 3, 1 / 3]),
np.array([1 / 3, 1 / 3, 1 / 3]),
)
support_pair = [0, 1, 2], [0, 1, 2]
self.assertTrue(is_ne(strategy_pair, support_pair, (A, -A)))
strategy_pair = (np.array([1, 0, 0]), np.array([1, 0, 0]))
support_pair = [0], [0]
self.assertFalse(is_ne(strategy_pair, support_pair, (A, -A)))
A = np.array(
[[160, 205, 44], [175, 180, 45], [201, 204, 50], [120, 207, 49]]
)
B = np.array([[2, 2, 2], [1, 0, 0], [3, 4, 1], [4, 1, 2]])
self.assertTrue(
is_ne(
(
np.array((0, 0, 3 / 4, 1 / 4)),
np.array((1 / 28, 27 / 28, 0)),
),
(np.array([2, 3]), np.array([0, 1])),
(A, B),
)