Datasets:
|
Download README.md from JinNian0072/program-pair-data: direct link, hf CLI and curl.
- Browser
- Download file 2.54 kB
-
https://huggingface.co/datasets/JinNian0072/program-pair-data/resolve/main/README.md
- Command line
-
hf download hf://datasets/JinNian0072/program-pair-data/README.md
-
curl -L -o README.md https://huggingface.co/datasets/JinNian0072/program-pair-data/resolve/main/README.md
2.54 kB
metadata
pretty_name: Program Pair Data
configs:
- config_name: cpp
data_files:
- split: test
path: final_benchmark_uniform/cpp_seed42_sanitized.jsonl
- config_name: python
data_files:
- split: test
path: final_benchmark_uniform/python_seed42_sanitized.jsonl
- config_name: java
data_files:
- split: test
path: final_benchmark_uniform/java_seed42_sanitized_process.jsonl
task_categories:
- text-classification
language:
- en
tags:
- code
- efficiency
- benchmark
size_categories:
- 1K<n<10K
Program Pair Data
This dataset contains 2,700 main-evaluation program pairs. Each language has
one test split with 900 pairs.
| Configuration | Pairs | Problems | Maximum pairs per problem |
|---|---|---|---|
cpp |
900 | 900 | 1 |
python |
900 | 221 | 5 |
java |
900 | 320 | 5 |
Each language contains 300 pairs in each slow-to-fast execution-cost ratio range: [2, 4), [4, 8), and [8, infinity).
Fields
language,problem_id,pair_id: language, task and comparison identifiers.slow_code,fast_code: exact model-facing program text, ordered by the saved efficiency labels.slow_code_id,fast_code_id: SHA-256 hashes of the displayed source text.measured_slow_code_id,measured_fast_code_id: SHA-256 identifiers of the measured source programs, which can differ from the displayed source.slow_id,fast_id: measured implementation identifiers.speedup: the saved slow-to-fast execution-cost ratio.measurement_metric: PIE released gem5 runtime for C++, CPU instruction count for Python, or elapsed execution time for Java.stratum,sampling_key: ratio stratum and deterministic sampling key.slow_time,fast_time: released aggregate costs, present for C++.
The Python and Java ratios aggregate per-input measurement ratios; they are not reconstructed as ratios of aggregate times. Test inputs, expected outputs, per-run measurements and original measured-source text are not included. This dataset provides the program pairs and saved efficiency labels used in the main evaluation.
Loading
from datasets import load_dataset
data = load_dataset("JinNian0072/program-pair-data", "python", split="test")
assert len(data) == 900
print(data[0]["slow_code"], data[0]["fast_code"])
Use cpp or java for the other languages. The JSONL files are uncompressed.
RELEASE.json contains record counts and file checksums. Upstream code and
data retain their respective terms.