Skip to content

Commit 5ff278c

Browse files
feat: gemini dingo/data/datasource/local.py
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
1 parent 41b4aee commit 5ff278c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dingo/data/datasource/local.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ def _load_parquet_file(self, path: str) -> Generator[str, None, None]:
175175
batch_dict = batch.to_pydict()
176176

177177
# 获取批次中的行数
178-
num_rows = len(batch_dict[next(iter(batch_dict))])
178+
num_rows = len(next(iter(batch_dict.values()))) if batch_dict else 0
179179

180180
# 逐行处理
181181
for i in range(num_rows):

0 commit comments

Comments
 (0)