(self, path)
| 57 | return crop_img |
| 58 | |
| 59 | def default_img_loader(self, path) -> np.ndarray: |
| 60 | img = cv2.imread(path) |
| 61 | return cv2.cvtColor(img, cv2.COLOR_BGR2RGB) |
| 62 | |
| 63 | def default_aud_loader(self, path: str) -> torch.Tensor: |
| 64 | speech_array, sampling_rate = librosa.load(path, sr = self.sampling_rate) |