ayushexel commited on
Commit
20509fe
·
verified ·
1 Parent(s): a2cc533

Add files using upload-large-folder tool

Browse files
.gitattributes CHANGED
@@ -58,3 +58,6 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
58
  # Video files - compressed
59
  *.mp4 filter=lfs diff=lfs merge=lfs -text
60
  *.webm filter=lfs diff=lfs merge=lfs -text
 
 
 
 
58
  # Video files - compressed
59
  *.mp4 filter=lfs diff=lfs merge=lfs -text
60
  *.webm filter=lfs diff=lfs merge=lfs -text
61
+ data/train.lance/_indices/b81c561e-5245-49a3-abad-fd799032d2e1/part_0_invert.lance filter=lfs diff=lfs merge=lfs -text
62
+ data/train.lance/_indices/4deb611f-d30b-4d8c-a4a2-304509a0751a/auxiliary.idx filter=lfs diff=lfs merge=lfs -text
63
+ data/train.lance/data/110110001110111001110111dced8948baa07b24e470f8ee3b.lance filter=lfs diff=lfs merge=lfs -text
README.md ADDED
@@ -0,0 +1,80 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: other
3
+ task_categories:
4
+ - image-classification
5
+ - image-feature-extraction
6
+ language:
7
+ - en
8
+ tags:
9
+ - stanford-cars
10
+ - fine-grained
11
+ - cars
12
+ - lance
13
+ - clip-embeddings
14
+ pretty_name: stanford-cars-lance
15
+ size_categories:
16
+ - 1K<n<10K
17
+ ---
18
+ # Stanford Cars (Lance Format)
19
+
20
+ Lance-formatted version of the [Stanford Cars dataset](https://web.archive.org/web/20210212183835/http://ai.stanford.edu/~jkrause/cars/car_dataset.html) — 8,144 training images across 196 fine-grained car make/model/year classes — sourced from [`Multimodal-Fatima/StanfordCars_train`](https://huggingface.co/datasets/Multimodal-Fatima/StanfordCars_train).
21
+
22
+ ## Schema
23
+
24
+ | Column | Type | Notes |
25
+ |---|---|---|
26
+ | `id` | `int64` | Row index |
27
+ | `image` | `large_binary` | Inline JPEG bytes |
28
+ | `label` | `int32` | Class id (0-195) |
29
+ | `blip_caption` | `string?` | BLIP-generated caption (beam=5) carried through from the source mirror |
30
+ | `image_emb` | `fixed_size_list<float32, 512>` | OpenCLIP `ViT-B-32` embedding (cosine-normalized) |
31
+
32
+ ## Pre-built indices
33
+
34
+ - `IVF_PQ` on `image_emb` — `metric=cosine`
35
+ - `INVERTED` (FTS) on `blip_caption`
36
+ - `BTREE` on `label`
37
+
38
+ ## Quick start
39
+
40
+ ```python
41
+ import lance
42
+ ds = lance.dataset("hf://datasets/lance-format/stanford-cars-lance/data/train.lance")
43
+ print(ds.count_rows(), ds.schema.names, ds.list_indices())
44
+ ```
45
+
46
+ ## Caption-based filtering
47
+
48
+ ```python
49
+ import lance
50
+ ds = lance.dataset("hf://datasets/lance-format/stanford-cars-lance/data/train.lance")
51
+ hits = ds.scanner(full_text_query="red sports car", columns=["id", "blip_caption"], limit=10).to_table()
52
+ ```
53
+
54
+ ## Visual similarity search
55
+
56
+ ```python
57
+ import lance, pyarrow as pa
58
+ ds = lance.dataset("hf://datasets/lance-format/stanford-cars-lance/data/train.lance")
59
+ emb_field = ds.schema.field("image_emb")
60
+ ref = ds.take([0], columns=["image_emb", "blip_caption"]).to_pylist()[0]
61
+ neighbors = ds.scanner(
62
+ nearest={"column": "image_emb", "q": pa.array([ref["image_emb"]], type=emb_field.type)[0], "k": 5},
63
+ columns=["id", "blip_caption"],
64
+ ).to_table().to_pylist()
65
+ ```
66
+
67
+ ## Source & license
68
+
69
+ Converted from [`Multimodal-Fatima/StanfordCars_train`](https://huggingface.co/datasets/Multimodal-Fatima/StanfordCars_train), itself a parquet redistribution of the Stanford Cars test split. The original dataset license is for non-commercial research use; review the [Stanford Cars terms](https://github.com/jhoffman/stanford-cars) before redistribution.
70
+
71
+ ## Citation
72
+
73
+ ```
74
+ @inproceedings{krause2013collecting,
75
+ title={Collecting a large-scale dataset of fine-grained cars},
76
+ author={Krause, Jonathan and Stark, Michael and Deng, Jia and Fei-Fei, Li},
77
+ booktitle={Workshop on Fine-Grained Visual Categorization (CVPR)},
78
+ year={2013}
79
+ }
80
+ ```
data/train.lance/_indices/4deb611f-d30b-4d8c-a4a2-304509a0751a/auxiliary.idx ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:0af7de1377a261794918a94fca60d3cb3efea1161509b3ec8daecb523945010d
3
+ size 1061124
data/train.lance/_indices/4deb611f-d30b-4d8c-a4a2-304509a0751a/index.idx ADDED
Binary file (33.1 kB). View file
 
data/train.lance/_indices/b81c561e-5245-49a3-abad-fd799032d2e1/metadata.lance ADDED
Binary file (733 Bytes). View file
 
data/train.lance/_indices/b81c561e-5245-49a3-abad-fd799032d2e1/part_0_docs.lance ADDED
Binary file (20.4 kB). View file
 
data/train.lance/_indices/b81c561e-5245-49a3-abad-fd799032d2e1/part_0_invert.lance ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e2ef9746b7f5dda39f8f8707dc2c6f8923839e0079d0d39ab0d003c8958989a7
3
+ size 109205
data/train.lance/_indices/b81c561e-5245-49a3-abad-fd799032d2e1/part_0_tokens.lance ADDED
Binary file (5.19 kB). View file
 
data/train.lance/_indices/de4cafa4-06d4-482b-880d-1b24f2b03b1e/page_data.lance ADDED
Binary file (15 kB). View file
 
data/train.lance/_indices/de4cafa4-06d4-482b-880d-1b24f2b03b1e/page_lookup.lance ADDED
Binary file (1.26 kB). View file
 
data/train.lance/_transactions/0-858c4eb4-f696-4db8-9ba2-88d21016ed34.txn ADDED
Binary file (322 Bytes). View file
 
data/train.lance/_transactions/1-fc82b61f-a9e1-438c-a46f-8223475eb601.txn ADDED
Binary file (189 Bytes). View file
 
data/train.lance/_transactions/2-610ddb56-253b-44ef-bbcd-288491315f5c.txn ADDED
Binary file (288 Bytes). View file
 
data/train.lance/_transactions/3-8357436c-656f-40ae-9e51-8b8d7406e1f7.txn ADDED
Binary file (192 Bytes). View file
 
data/train.lance/_versions/18446744073709551611.manifest ADDED
Binary file (1.14 kB). View file
 
data/train.lance/_versions/18446744073709551612.manifest ADDED
Binary file (1.09 kB). View file
 
data/train.lance/_versions/18446744073709551613.manifest ADDED
Binary file (748 Bytes). View file
 
data/train.lance/_versions/18446744073709551614.manifest ADDED
Binary file (729 Bytes). View file
 
data/train.lance/data/110110001110111001110111dced8948baa07b24e470f8ee3b.lance ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:819d178bfe952209bfe204b1f32d48922756e742aae711c463011f3a989c70d6
3
+ size 876028317