def flatten(x):
    x = T.reshape(x, (x.shape[0], T.prod(x.shape) // x.shape[0]))
    return x
Turn a n-D tensor into a 2D tensor where
dataset/ETHPy150Open sharadmv/deepx/deepx/backend/theano_backend.py/flatten