Datasets:
Update dataset card
Browse files
README.md
ADDED
|
@@ -0,0 +1,87 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
---
|
| 2 |
+
dataset_info:
|
| 3 |
+
features:
|
| 4 |
+
- name: sample_id
|
| 5 |
+
dtype: string
|
| 6 |
+
- name: energy
|
| 7 |
+
sequence: float32
|
| 8 |
+
length: 3384
|
| 9 |
+
- name: n_freqs
|
| 10 |
+
dtype: int32
|
| 11 |
+
- name: n_dirs
|
| 12 |
+
dtype: int32
|
| 13 |
+
- name: source
|
| 14 |
+
dtype: string
|
| 15 |
+
- name: station
|
| 16 |
+
dtype: string
|
| 17 |
+
- name: n_anchors
|
| 18 |
+
dtype: int32
|
| 19 |
+
- name: anchors_json
|
| 20 |
+
dtype: string
|
| 21 |
+
- name: Hs
|
| 22 |
+
dtype: float32
|
| 23 |
+
- name: Tp
|
| 24 |
+
dtype: float32
|
| 25 |
+
- name: Dp
|
| 26 |
+
dtype: float32
|
| 27 |
+
- name: total_energy
|
| 28 |
+
dtype: float32
|
| 29 |
+
splits:
|
| 30 |
+
- name: train
|
| 31 |
+
num_examples: 100964
|
| 32 |
+
- name: validation
|
| 33 |
+
num_examples: 5532
|
| 34 |
+
- name: test
|
| 35 |
+
num_examples: 5529
|
| 36 |
+
license: cc-by-4.0
|
| 37 |
+
task_categories:
|
| 38 |
+
- image-to-image
|
| 39 |
+
tags:
|
| 40 |
+
- oceanography
|
| 41 |
+
- wave-spectrum
|
| 42 |
+
- compression
|
| 43 |
+
- diffusion-model
|
| 44 |
+
---
|
| 45 |
+
|
| 46 |
+
# ATLAS-WDS: Wave Directional Spectrum Dataset
|
| 47 |
+
|
| 48 |
+
海浪方向谱压缩回传训练数据集。
|
| 49 |
+
|
| 50 |
+
## 数据格式
|
| 51 |
+
|
| 52 |
+
每条记录包含一个 **47×72 能量矩阵**(展平为 3384 维 float32 数组)
|
| 53 |
+
及对应的 **斜高斯锚点参数**。
|
| 54 |
+
|
| 55 |
+
## 快速加载
|
| 56 |
+
|
| 57 |
+
```python
|
| 58 |
+
from datasets import load_dataset
|
| 59 |
+
import numpy as np, json
|
| 60 |
+
|
| 61 |
+
ds = load_dataset("wuff-mann/ATLAS-WDS", split="train", streaming=True)
|
| 62 |
+
|
| 63 |
+
for sample in ds:
|
| 64 |
+
# 还原能量矩阵
|
| 65 |
+
energy = np.array(sample["energy"], dtype=np.float32).reshape(
|
| 66 |
+
sample["n_freqs"], sample["n_dirs"]) # (47, 72)
|
| 67 |
+
# 锚点参数
|
| 68 |
+
anchors = json.loads(sample["anchors_json"])
|
| 69 |
+
# 物理参数
|
| 70 |
+
Hs, Tp, Dp = sample["Hs"], sample["Tp"], sample["Dp"]
|
| 71 |
+
```
|
| 72 |
+
|
| 73 |
+
## 三阶段训练使用
|
| 74 |
+
|
| 75 |
+
```python
|
| 76 |
+
# Stage 1: cLDM 预训练 — 只用能量矩阵
|
| 77 |
+
for sample in ds:
|
| 78 |
+
matrix = np.array(sample["energy"]).reshape(47, 72)
|
| 79 |
+
|
| 80 |
+
# Stage 2: Swin 编码器 — 矩阵 + 锚点
|
| 81 |
+
for sample in ds:
|
| 82 |
+
matrix = np.array(sample["energy"]).reshape(47, 72)
|
| 83 |
+
anchors = json.loads(sample["anchors_json"])
|
| 84 |
+
|
| 85 |
+
# Stage 3: 端到端对齐 — 仅真实数据
|
| 86 |
+
ds_real = ds.filter(lambda x: x["source"] != "synthetic")
|
| 87 |
+
```
|