Skip to content

feat(data): improve offline data prep with validation, tutorials, image util tests - #1875

Open
DoubleCore wants to merge 1 commit into
areal-project:mainfrom
DoubleCore:issue-1695-offline-data
Open

DoubleCore wants to merge 1 commit into
areal-project:mainfrom
DoubleCore:issue-1695-offline-data

Conversation

@DoubleCore

Copy link
Copy Markdown

Implements #1695.

…ge util tests

Contributors can now prepare and check datasets on CPU before arranging
GPU resources, and the image helpers gain CPU-only regression coverage.

Key changes:
- Add python -m areal.dataset.validate with text-rl and tokenized-sft
  profiles, --split/--require-field/--max-length/--max-errors options,
  deterministic JSON reports, and 0/1/2 exit codes
- Extend EN/ZH dataset customization guides with a runnable offline
  custom-dataset tutorial wired to the new validator, incl. DatasetDict
  split selection and unavailable-split errors
- Add tests/test_image_utils.py covering base64 encoding and
  max-size padding behavior with synthetic Pillow images
- Document existing image2base64/pad_images_batch_to_max_size behavior
  via docstrings without changing signatures
- Add offline unit tests and subprocess CLI integration tests for the
  validator (skipped when the full import chain is unavailable)

Refs: areal-project#1695
@DoubleCore

Copy link
Copy Markdown
Author

Closing this PR myself: it duplicates wesssI's #1852, which implements the same offline data validation CLI and custom-dataset walkthrough. To avoid wasting maintainer review time on duplicate work, I'm closing this one.

@DoubleCore DoubleCore closed this Nov 7, 2026
@DoubleCore DoubleCore reopened this Nov 7, 2026

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants