def hstack(datasets):
    if np.any([sparse.issparse(d) for d in datasets]):
        stack = lambda x: sparse.hstack(x).tocsr()
    else:
        stack = np.hstack
    return stack(datasets)
Wrapper for hstack method from numpy or scipy. If any of the input
dataset/ETHPy150Open theusual/kaggle-seeclickfix-ensemble/Miroslaw/data_transforms.py/hstack