[Fix] Remove hard requirements of pandas
Browse files
processing_interns1_pro.py
CHANGED
|
@@ -173,7 +173,7 @@ class InternS1ProProcessor(ProcessorMixin):
|
|
| 173 |
raise ImportError("Please install soundfile to process audio files.")
|
| 174 |
ts_input, sr = sf.read(ts_path) # ts_input: np.ndarray, shape [T] or [T, C]
|
| 175 |
elif ext == ".csv":
|
| 176 |
-
|
| 177 |
df = pd.read_csv(ts_path, header=None)
|
| 178 |
ts_input = df.values # [T, C]
|
| 179 |
elif ext == ".npy":
|
|
|
|
| 173 |
raise ImportError("Please install soundfile to process audio files.")
|
| 174 |
ts_input, sr = sf.read(ts_path) # ts_input: np.ndarray, shape [T] or [T, C]
|
| 175 |
elif ext == ".csv":
|
| 176 |
+
pd = __import__("pandas")
|
| 177 |
df = pd.read_csv(ts_path, header=None)
|
| 178 |
ts_input = df.values # [T, C]
|
| 179 |
elif ext == ".npy":
|