But Dataloader could only support PIL Image as its input.
What I want to do is that:

Use OpenCV to read, and preprocess image like transforms.
Use data.Dataloader to create train dataloader and test dataloader. But it cannot accept data that is resized by OpenCV.