Numpy
Numpy (12)
알 수 없는 사용자
2022. 8. 2. 23:15
728x90
How to remove from one array those items that exist in another?
a = np.array([1,2,3,4,5])
b = np.array([5,6,7,8,9])
np.setdiff1d(a,b)
# output
array([1, 2, 3, 4])