Datasets:
Download code/stream_issues.py from open-index/open-github-issues: direct link, hf CLI and curl.
- Browser
- Download file 413 Bytes
-
https://huggingface.co/datasets/open-index/open-github-issues/resolve/main/code/stream_issues.py
- Command line
-
hf download hf://datasets/open-index/open-github-issues/code/stream_issues.py
-
curl -L -o stream_issues.py https://huggingface.co/datasets/open-index/open-github-issues/resolve/main/code/stream_issues.py
413 Bytes
| # /// script | |
| # requires-python = ">=3.11" | |
| # dependencies = ["datasets"] | |
| # /// | |
| """Stream issues from the dataset without downloading everything.""" | |
| from datasets import load_dataset | |
| ds = load_dataset("open-index/open-github-issues", "issues", streaming=True) | |
| for i, row in enumerate(ds["train"]): | |
| print(f"#{row['number']}: [{row['state']}] {row['title']} (by {row['author']})") | |
| if i >= 19: | |
| break | |