--- pretty_name: DRIVE-UGC language: - zh size_categories: - 10K/.` and match the member names inside their TAR archive. The Hub configuration selects only `records/{split}.jsonl` for the viewer; label mappings, statistics, feature arrays, and TAR files remain separate assets. Image references are paths and hashes rather than decoded image columns. This follows the Hub's [explicit data-file configuration](https://huggingface.co/docs/hub/datasets-data-files-configuration). ## Load a downloaded partition Download `features/A_test/`, `splits/A_test/`, `labels.json`, and `code/load_features.py` into the repository layout above. Run from a directory containing the downloaded repository: ```python from pathlib import Path import sys root = Path("DRIVE-UGC").resolve() sys.path.insert(0, str(root / "code")) from load_features import load_split ds = load_split(root, "A_test") event = ds.event(int(ds.paired_indices[0])) print(event["event_id"], event["label"]) print(event["posts"].shape) # (number of posts, 1024) print(event["regions"].shape) # (81 * number of images, 1152) boundaries = event["image_region_offsets"] first_image_regions = event["regions"][boundaries[0]:boundaries[1]] ``` The loader returns `public_event_index`, `event_id`, `content_group_id`, `label`, `paired`, `posts`, `regions`, and event-relative `image_region_offsets`. Use the public event index when joining feature slices to metadata; paired-subset positions are a different indexing space. To inspect local text records: ```python import json with (root / "records" / "A_test.jsonl").open(encoding="utf-8") as f: record = json.loads(next(f)) print(record.keys()) ``` For original images, resolve the record's image hash through the image index, then read the named member from its TAR shard: ```python import tarfile with (root / "images" / "image_index.jsonl").open(encoding="utf-8") as f: image_index = {item["sha256"]: item for item in map(json.loads, f)} image_ref = record["images"][0] # A_test events all contain images entry = image_index[image_ref["sha256"]] with tarfile.open(root / entry["archive"], "r") as archive: with archive.extractfile(entry["path"]) as image_file: image_bytes = image_file.read() ``` This retrieves selected source-image bytes. The released regional arrays provide the corresponding OCR-MASK model inputs. ## Attribution and rights Source contributions originate from [Autohome](https://www.autohome.com.cn/). Text features use [BGE-large-zh-v1.5](https://huggingface.co/BAAI/bge-large-zh-v1.5), and regional features use [SigLIP 2 SO400M patch14-384](https://huggingface.co/google/siglip2-so400m-patch14-384). Refer to the upstream model cards for encoder documentation and terms. Third-party posts and images remain subject to the rights of their original rights holders. This repository grants no additional open-content license for those source materials. [SOURCE_NOTICE.md](SOURCE_NOTICE.md) describes the released transformations and source rights.