Skip to content

Commit

Permalink
add warning when no transcriptions.csv found
Browse files Browse the repository at this point in the history
  • Loading branch information
qiuqiao committed Mar 3, 2024
1 parent c6bf62e commit 51a869d
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions binarize.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import pathlib
import warnings

import click
import h5py
Expand Down Expand Up @@ -320,6 +321,8 @@ def get_meta_data(self, data_folder, vocab):
for i in path.rglob("transcriptions.csv")
if i.name == "transcriptions.csv"
]
if len(trans_path_list) <= 0:
warnings.warn(f"No transcriptions.csv found in {data_folder}.")

print("Loading metadata...")
meta_data_df = pd.DataFrame()
Expand Down

0 comments on commit 51a869d

Please sign in to comment.