File size: 11,800 Bytes
05cb22e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
onescience_manifest_version: "0.1"
resource_type: dataset

resource:
  id: OneScience/beno
  name: beno
  domain: cfd
  domain_tags:
    - cfd
    - elliptic_pde
    - boundary_condition
  task: elliptic_pde_surrogate_dataset
  task_tags:
    - train_data
    - eval_data
    - inference_input
    - dataset_validation
  modalities:
    - gridded_field
    - boundary_condition
  input_formats:
    - npy
  output_formats:
    - npy
  summary: BENO 椭圆 PDE 数据集,包含 Dirichlet  Neumann 边界下的 32x32 网格 RHS、SOL、BC NPY 文件。

platform_resource:
  primary:
    platform: modelscope
    repo_id: OneScience/beno
    repo_type: dataset
    url: https://modelscope.cn/datasets/OneScience/beno
    revision: main
    readme_path: README.md
    manifest_path: onescience_run_manifest.yaml
  mirrors: []
  access:
    visibility: public
    license: unknown

website_integration:
  enabled: true
  click_target:
    platform: modelscope
    resource_url: https://modelscope.cn/datasets/OneScience/beno
  llm_handoff:
    readme_required: true
    manifest_required: true
    download_readme_first: true
    resolve_related_models: true
    default_run_goal: dataset_validation
    cwd_note: 如果使用 modelscope download --cache_dir 下载数据集,请先 cd 到实际下载后的数据集仓库根目录;模型侧将 ONESCIENCE_BENO_DATA_DIR 指向本仓库 data 目录。

runtime:
  enabled: true
  onescience_domain: cfd
  min_onescience_version: null
  supported_execution:
    - local_dataset_validation
    - model_training_input
    - model_inference_input
  environment:
    exported_env:
      ONESCIENCE_BENO_DATA_DIR: <dataset_repo_root>/data
  dependencies:
    python: ">=3.10"
    python_packages:
      - numpy
      - pyyaml

onescience:
  repo: https://gitee.com/onescience-ai/onescience
  official_links:
    gitee:
      doc: https://gitee.com/onescience-ai/onescience-doc
      onescience: https://gitee.com/onescience-ai/onescience
      skills: https://gitee.com/onescience-ai/oneskills
    github:
      doc: https://github.com/onescience-ai/OneScience-doc
      onescience: https://github.com/onescience-ai/OneScience
      skills: https://github.com/onescience-ai/oneskills
  install:
    required_by_default: false
    command: bash install.sh cfd
  source_paths:
    - onescience/src/onescience/datapipes/cfd/beno.py
  compatibility:
    examples_path: onescience/examples/cfd/BENO
    status: examples_compatible
  datapipe: onescience.datapipes.cfd.BENODatapipe

runtime_package:
  kind: standard_runtime_package
  package_root: .
  standard_layout:
    workdir: .
    data_dir: data
    metadata_dir: metadata
    output_dir: validation_outputs
  apply_policy:
    mode: direct_use
    target: session_workdir
    overwrite: false
    protect_installed_onescience: true
  entry_files:
    - data/Dirichlet/RHS_N32_4c_all.npy
    - data/Dirichlet/SOL_N32_4c_all.npy
    - data/Dirichlet/BC_N32_4c_all.npy
    - metadata/beno_schema.json
    - scripts/validate_beno_dataset.py
    - files_sha256.jsonl
  entrypoints:
    preflight: scripts/validate_beno_dataset.py
    validate: scripts/validate_beno_dataset.py
    inference: null
    train: null
    finetune: null
    evaluate: null
    visualize: null
    deploy: null

files:
  model_files: []
  dataset_files:
    - path: data/Dirichlet/*.npy
      role: train_eval_inference_data
      description_zh: Dirichlet 边界条件下的 BENO NPY 数据文件,包含 RHS、SOL、BC 三类数组和 6 个几何前缀。
      required: true
      required_for: [dataset_validation, train, inference, evaluate]
      source:
        platform: modelscope
        repo_id: OneScience/beno
        repo_type: dataset
        download_method: command_ref
        command_ref: commands.download.download_dataset
      local_path: data/Dirichlet
    - path: data/Neumann/*.npy
      role: additional_boundary_data
      description_zh: Neumann 边界条件下的 BENO NPY 数据文件,可用于扩展训练或对比实验。
      required: true
      required_for: [dataset_validation]
      source:
        platform: modelscope
        repo_id: OneScience/beno
        repo_type: dataset
        download_method: command_ref
        command_ref: commands.download.download_dataset
      local_path: data/Neumann
    - path: files_sha256.jsonl
      role: file_size_sha256_inventory
      description_zh: 整理后数据文件的大小和 SHA256 清单,用于完整性校验。
      required: true
      required_for: [dataset_validation]
      source:
        platform: modelscope
        repo_id: OneScience/beno
        repo_type: dataset
        download_method: command_ref
        command_ref: commands.download.download_dataset
      local_path: files_sha256.jsonl
    - path: data_integrity_summary.json
      role: source_to_standardized_integrity_summary
      description_zh: 原始数据与整理后数据的文件名、大小、SHA256 对照摘要。
      required: true
      required_for: [dataset_validation]
      source:
        platform: modelscope
        repo_id: OneScience/beno
        repo_type: dataset
        download_method: command_ref
        command_ref: commands.download.download_dataset
      local_path: data_integrity_summary.json
  config_files:
    - path: metadata/beno_schema.json
      role: dataset_schema
      description_zh: 描述 BENO 数据文件命名、shape、dtype 和默认模型子集。
      required: true
      required_for: [dataset_validation, train, inference]
      source:
        platform: modelscope
        repo_id: OneScience/beno
        repo_type: dataset
        download_method: command_ref
        command_ref: commands.download.download_dataset
      local_path: metadata/beno_schema.json
  sample_files:
    - path: scripts/validate_beno_dataset.py
      role: dataset_validation_entry
      description_zh: 数据集读取验证脚本,检查文件结构、shape、dtype、可读性、统计清单和可选 SHA256。
      required: true
      required_for: [dataset_validation]
      source:
        platform: modelscope
        repo_id: OneScience/beno
        repo_type: dataset
        download_method: command_ref
        command_ref: commands.download.download_dataset
      local_path: scripts/validate_beno_dataset.py

relations:
  required_datasets: []
  optional_datasets: []
  compatible_models:
    - id: OneScience/BENO
      role: train_data
      required_for: [train, inference, evaluate, visualize]
      resource_ref:
        platform: modelscope
        repo_id: OneScience/BENO
        repo_type: model
        url: https://modelscope.cn/models/OneScience/BENO
        revision: main
        readme_path: README.md
        manifest_path: onescience_run_manifest.yaml
      expected_local_path: session_workdir/data
      expected_env: ONESCIENCE_BENO_DATA_DIR

run_matrix:
  scenarios:
    - name: validate_structure
      capability: dataset_validation
      default: true
      required_datasets:
        - id: OneScience/beno
          role: train_data
          local_path: data
      required_model_files: []
      required_dataset_files:
        - data/Dirichlet/*.npy
        - data/Neumann/*.npy
        - metadata/beno_schema.json
      preconditions:
        - 当前工作目录为数据集仓库根目录。
      command_refs:
        - commands.preflight.validate_dataset
      outputs:
        - 控制台输出 [OK] dataset validation completed
    - name: validate_integrity_full_hash
      capability: dataset_validation
      default: false
      required_datasets:
        - id: OneScience/beno
          role: train_data
          local_path: data
      required_model_files: []
      required_dataset_files:
        - files_sha256.jsonl
        - data/Dirichlet/*.npy
        - data/Neumann/*.npy
      preconditions:
        - 当前工作目录为数据集仓库根目录。
      command_refs:
        - commands.preflight.validate_dataset_full_hash
      outputs:
        - 控制台输出 checksum manifest verified in size+sha256 mode
    - name: provide_to_beno_model
      capability: train
      default: true
      required_datasets:
        - id: OneScience/beno
          role: train_data
          local_path: data
      required_model_files:
        - OneScience/BENO:conf/beno.yaml
      required_dataset_files:
        - data/Dirichlet/RHS_N32_4c_all.npy
        - data/Dirichlet/SOL_N32_4c_all.npy
        - data/Dirichlet/BC_N32_4c_all.npy
      preconditions:
        - 模型仓库 OneScience/BENO 已下载。
        - 设置 ONESCIENCE_BENO_DATA_DIR 为本仓库 data 目录。
      command_refs:
        - commands.prepare.export_dataset_env
      outputs:
        - 模型侧 scripts/preflight_check.py 可以读取数据集。

capabilities:
  dataset_validation: true
  train_input: true
  inference_input: true
  evaluation_input: true
  visualization_input: true
  preflight: true
  inference: false
  train: false
  finetune: false
  evaluate: false
  visualize: false
  deploy: false

commands:
  download:
    - name: download_dataset
      command: modelscope download --dataset OneScience/beno
      cwd: session_workdir
    - name: download_model
      command: modelscope download --model OneScience/BENO
      cwd: session_workdir
  prepare:
    - name: export_dataset_env
      command: export ONESCIENCE_BENO_DATA_DIR=/path/to/OneScience_beno/data
      cwd: .
  preflight:
    - name: validate_dataset
      command: python scripts/validate_beno_dataset.py
      cwd: .
    - name: validate_dataset_full_hash
      command: python scripts/validate_beno_dataset.py --full-hash
      cwd: .
  inference: []
  train: []
  finetune: []
  evaluate: []
  visualize: []
  deploy: []

expected_outputs:
  - name: validate_dataset
    paths: []
    success_criteria:
      - 控制台输出 [OK] dataset validation completed
  - name: validate_dataset_full_hash
    paths:
      - files_sha256.jsonl
    success_criteria:
      - 控制台输出 checksum manifest verified in size+sha256 mode: 36 files
  - name: model_consumption
    paths: []
    success_criteria:
      - 模型包 scripts/preflight_check.py 通过数据路径和 schema 检查。

diagnostics:
  - name: missing_data_root
    symptom: dataset data root does not exist
    action: 确认当前目录为 OneScience/beno 数据集仓库根目录,且 data 目录存在。
  - name: missing_npy
    symptom: missing required NPY files
    action: 对照 files_sha256.jsonl 重新上传或重新下载缺失文件。
  - name: shape_mismatch
    symptom: shape mismatch  dtype mismatch
    action: 确认没有用其他分辨率或其他 BENO 数据覆盖当前文件。
  - name: checksum_mismatch
    symptom: sha256 mismatch
    action: 删除损坏文件后重新下载 OneScience/beno。
  - name: model_cannot_find_data
    symptom: 模型侧报告 ONESCIENCE_BENO_DATA_DIR is not set  Data file not found
    action:  ONESCIENCE_BENO_DATA_DIR 设置为本仓库 data 目录,而不是仓库根目录或 data/Dirichlet。

domain_extension:
  cfd:
    dataset_family: BENO
    physics: elliptic partial differential equation
    boundary_types:
      - Dirichlet
      - Neumann
    prefixes:
      - N32_0c
      - N32_1c
      - N32_2c
      - N32_3c
      - N32_4c
      - N32_mix
    file_count: 36
    total_size_bytes: 540676608
    resolution: 32
    samples_per_file: 1000
    schema:
      BC:
        shape: [1000, 128, 4]
        dtype: float64
        note: 当前 OneScience BENO datapipe 使用通道 0:2 和通道 2;通道 3 在原始数据中为 NaN 占位,验证脚本会记录警告但不视为损坏。
      RHS:
        shape: [1000, 1024, 4]
        dtype: float64
      SOL:
        shape: [1000, 1024, 1]
        dtype: float64