Skip to content

Commit

Permalink
Update csv2arrow.py
Browse files Browse the repository at this point in the history
  • Loading branch information
zml-ai authored Jun 14, 2024
1 parent 28ff0e2 commit 6602373
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions hydit/data_loader/csv2arrow.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ def parse_data(data):

with open(img_path, "rb") as fp:
image = fp.read()
md5 = hashlib.md5(fp.read()).hexdigest()
md5 = hashlib.md5(image).hexdigest()

with Image.open(img_path) as f:
width, height = f.size
Expand Down Expand Up @@ -85,4 +85,4 @@ def make_arrow(csv_root, dataset_root, start_id=0, end_id=-1):
csv_root = sys.argv[1]
output_arrow_data_path = sys.argv[2]
pool = Pool(500)
make_arrow(csv_root, output_arrow_data_path)
make_arrow(csv_root, output_arrow_data_path)

0 comments on commit 6602373

Please sign in to comment.