ayzk commited on
Commit
e756a5b
·
verified ·
1 Parent(s): 758c3c7

Update dataset card

Browse files
Files changed (1) hide show
  1. README.md +116 -0
README.md ADDED
@@ -0,0 +1,116 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: other
3
+ license_name: sdrbench
4
+ license_link: https://sdrbench.github.io/
5
+ pretty_name: "SDRBench: NYX"
6
+ tags:
7
+ - scientific-data
8
+ - lossy-compression
9
+ - sdrbench
10
+ - hpc
11
+ - sz3
12
+ ---
13
+
14
+ # SDRBench — NYX
15
+
16
+ Cosmology: adaptive mesh hydrodynamics + N-body cosmological simulation. 6 fields of 512x512x512, single precision, little-endian; the _log variant holds log-transformed fields.
17
+
18
+ This repository is an **unmodified mirror** of the NYX dataset from
19
+ [SDRBench](https://sdrbench.github.io/datasets.html), the Scientific Data Reduction Benchmark. The originals are hosted by
20
+ Argonne National Laboratory on Globus; every archive was unpacked and its files uploaded
21
+ byte-for-byte (sha256 verified). `metadata/` holds the original SDRBench property and template
22
+ files. The mirror is kept in sync automatically by
23
+ [szcompressor/sdrbench](https://github.com/szcompressor/sdrbench).
24
+
25
+ - **Data source:** Zarija Lukic (LBNL)
26
+ - **Total size:** 6.4 GB
27
+ - **Format:** raw little-endian binary, C order (slowest dimension first)
28
+
29
+ ## Usage
30
+
31
+ ```bash
32
+ pip install "sdrbench[sz3]" # sdrbench + pysz (SZ3)
33
+ ```
34
+
35
+ ```python
36
+ import numpy as np
37
+ import sdrbench
38
+ from pysz import sz, szConfig, szErrorBoundMode
39
+
40
+ ds = sdrbench.dataset("nyx") # default variant: 512x512x512
41
+ print(ds.fields)
42
+ x = ds["baryon_density"] # numpy array, dtype <f4, shape (512, 512, 512)
43
+
44
+ # compress with SZ3 (pysz) at a 1e-3 value-range-relative error bound
45
+ conf = szConfig()
46
+ conf.errorBoundMode = szErrorBoundMode.REL
47
+ conf.relErrorBound = 1e-3
48
+ compressed, ratio = sz.compress(np.ascontiguousarray(x), conf)
49
+ y, _ = sz.decompress(compressed, x.dtype.type, x.shape)
50
+ max_err, psnr, nrmse = sz.verify(np.asarray(x), y)
51
+ print(f"ratio {ratio:.1f}x, PSNR {psnr:.1f} dB, max error {max_err:.3g}")
52
+ ```
53
+
54
+ Other variants: `sdrbench.dataset("nyx", "512x512x512_log")`.
55
+
56
+ Files are downloaded on first use and cached; if Hugging Face is unreachable the package falls
57
+ back to the original archive on Globus.
58
+
59
+ Without the package, any file can be read with `huggingface_hub` and numpy:
60
+
61
+ ```python
62
+ from huggingface_hub import hf_hub_download
63
+ import numpy as np
64
+ p = hf_hub_download("sdrbench/nyx", "512x512x512/baryon_density.f32", repo_type="dataset")
65
+ x = np.fromfile(p, dtype="<f4").reshape((512, 512, 512))
66
+ ```
67
+
68
+ ## Contents
69
+
70
+
71
+ ### `512x512x512` (default)
72
+
73
+ 7 files, 3.2 GB, from [SDRBENCH-EXASKY-NYX-512x512x512.tar.gz](https://g-d0cd3f.fd635.8443.data.globus.org/raw-data/EXASKY/NYX/SDRBENCH-EXASKY-NYX-512x512x512.tar.gz).
74
+
75
+ | Field | dtype | Shape (C order) | File |
76
+ |---|---|---|---|
77
+ | `baryon_density` | `<f4` | 512 x 512 x 512 | `512x512x512/baryon_density.f32` |
78
+ | `dark_matter_density` | `<f4` | 512 x 512 x 512 | `512x512x512/dark_matter_density.f32` |
79
+ | `temperature` | `<f4` | 512 x 512 x 512 | `512x512x512/temperature.f32` |
80
+ | `velocity_x` | `<f4` | 512 x 512 x 512 | `512x512x512/velocity_x.f32` |
81
+ | `velocity_y` | `<f4` | 512 x 512 x 512 | `512x512x512/velocity_y.f32` |
82
+ | `velocity_z` | `<f4` | 512 x 512 x 512 | `512x512x512/velocity_z.f32` |
83
+
84
+ Other files: `512x512x512/template_data.txt`
85
+
86
+ ### `512x512x512_log`
87
+
88
+ 6 files, 3.2 GB, from [SDRBENCH-EXASKY-NYX-512x512x512_log.tar.gz](https://g-d0cd3f.fd635.8443.data.globus.org/raw-data/EXASKY/NYX/SDRBENCH-EXASKY-NYX-512x512x512_log.tar.gz).
89
+
90
+ | Field | dtype | Shape (C order) | File |
91
+ |---|---|---|---|
92
+ | `baryon_density_log10` | `<f4` | 512 x 512 x 512 | `512x512x512_log/baryon_density_log10.f32` |
93
+ | `dark_matter_density_log10` | `<f4` | 512 x 512 x 512 | `512x512x512_log/dark_matter_density_log10.f32` |
94
+ | `temperature` | `<f4` | 512 x 512 x 512 | `512x512x512_log/temperature.f32` |
95
+ | `velocity_x` | `<f4` | 512 x 512 x 512 | `512x512x512_log/velocity_x.f32` |
96
+ | `velocity_y` | `<f4` | 512 x 512 x 512 | `512x512x512_log/velocity_y.f32` |
97
+ | `velocity_z` | `<f4` | 512 x 512 x 512 | `512x512x512_log/velocity_z.f32` |
98
+
99
+ ## Citation
100
+
101
+ If you use this dataset, please cite SDRBench:
102
+
103
+ ```bibtex
104
+ @inproceedings{zhao2020sdrbench,
105
+ title = {{SDRBench}: Scientific Data Reduction Benchmark for Lossy Compressors},
106
+ author = {Zhao, Kai and Di, Sheng and Liang, Xin and Li, Sihuan and Tao, Dingwen and Chen, Zizhong and Cappello, Franck},
107
+ booktitle = {2020 IEEE International Conference on Big Data (Big Data)},
108
+ pages = {2716--2724},
109
+ year = {2020}
110
+ }
111
+ ```
112
+
113
+ ## License and terms
114
+
115
+ The data are distributed under the same terms as on the [SDRBench website](https://sdrbench.github.io/datasets.html).
116
+ Rights remain with the original data providers listed above.