If I have a list:
a = [np.array([1,1,1]), np.array([1,1,1]), np.array([1,1,1])]
How to do something like, a.count(np.array([1,1,1])? This throws:
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
Is there a function similar to .count()?
len(a)with return lengthcountis using==teat, which for arrays iselement-wise, resulting in the ambiguity error.