JLD commited on
Commit
3c857ef
1 Parent(s): 8871677

Fix feather reading

Browse files

feather infers compression (cool!)

Files changed (1) hide show
  1. unsplash25k-image-embeddings.py +1 -1
unsplash25k-image-embeddings.py CHANGED
@@ -82,7 +82,7 @@ class Unsplash25kImageEmbeddingsDataset(datasets.GeneratorBasedBuilder):
82
  # method parameters are unpacked from `gen_kwargs` as given in `_split_generators`
83
  def _generate_examples(self, embeddings_path, image_ids_path):
84
  tensors = {}
85
- image_ids = pd.read_feather(image_ids_path, compression="zstd")
86
  with safe_open(embeddings_path, framework="pt", device="cpu") as f:
87
  for key in f.keys():
88
  tensors[key] = f.get_tensor(key)
 
82
  # method parameters are unpacked from `gen_kwargs` as given in `_split_generators`
83
  def _generate_examples(self, embeddings_path, image_ids_path):
84
  tensors = {}
85
+ image_ids = pd.read_feather(image_ids_path)
86
  with safe_open(embeddings_path, framework="pt", device="cpu") as f:
87
  for key in f.keys():
88
  tensors[key] = f.get_tensor(key)