These scikit-learn methods expect 2-dimensional numpy arrays as the input, so you could either pass a batch returned by the DataLoader to it (after calling numpy() on it and making sure the shape is right) or you could stack (some) batches and pass this larger array to it.