
25 May
2010
25 May
'10
4:54 p.m.
I don't understand this:
a1 = np.array(['a', 'b'], dtype=object) a2 = np.array(['a', 'b'])
a1 == a2
array([ True, True], dtype=bool) # Looks good
a2 == a1
False # Should I have expected this?
This works like I expected:
a1 = np.array([1, 2], dtype=object) a2 = np.array([1, 2])
a1 == a2
array([ True, True], dtype=bool)
a2 == a1
array([ True, True], dtype=bool)