def choose(a, choices, out=None, mode='raise'):
 assert (out is None)
 return Choose(mode)(a, choices)

def choose ( a , choices , out = None , mode = 'raise' ) : assert ( out is None ) return Choose ( mode ) ( a , choices )
construct an array from an index array and a set of arrays to choose from .