Skip to content

Instantly share code, notes, and snippets.

@gcr
Created November 17, 2013 17:41
Show Gist options
  • Select an option

  • Save gcr/7515937 to your computer and use it in GitHub Desktop.

Select an option

Save gcr/7515937 to your computer and use it in GitHub Desktop.
np.select(np.array([[1, 1, 0, 0],
[0, 0, 1, 1]]),
np.array([[1, 2, 3, 4],
[5, 6, 7, 8]]))
Truncated Traceback (Use C-c C-x to view full TB):
/usr/lib/python2.7/site-packages/numpy/core/fromnumeric.pyc in choose(a, choices, out, mode)
296 except AttributeError:
297 return _wrapit(a, 'choose', choices, out=out, mode=mode)
--> 298 return choose(choices, out=out, mode=mode)
299
300
ValueError: invalid entry in choice array
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment