# 为 pywr 场景读取 h5 DataFrame

转到集水节点 **Days Weir，** 单击 “编辑” **流量**

<figure><img src="https://2456626420-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FroBiEJ09sszXPUfSv5uk%2Fuploads%2Fgit-blob-122f78f6caa50d6525b64a7edbb7532b0c31aa7c%2Fimage%20(42).png?alt=media" alt="" width="563"><figcaption></figcaption></figure>

将弹出一个新窗口，选择 **PYWR\_参数** 然后点击 **保存**

<figure><img src="https://2456626420-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FroBiEJ09sszXPUfSv5uk%2Fuploads%2Fgit-blob-2d3f81de6e093c76b9f7a27004f7da6634059481%2Fimage%20(43).png?alt=media" alt=""><figcaption></figcaption></figure>

粘贴以下配置，然后 **保存**

\`\`json { “钥匙”：“Days Weir”， “情景”：“气候变化”， “类型”：“数据框参数”， “网址”：“泰晤士河\_流入\_pywr Scenarios.h5"， “index\_col”: “时间步”， “parse\_dates”：真 }

```

它应该看起来像下图

<figure><img src="../../.gitbook/assets/image (44).png" alt="" width="563"><figcaption></figcaption></figure>

重复集水区的程序 **降低\_泰晤士**使用以下配置

``json
{
	“关键”：“泰晤士河下游”，
	“情景”：“气候变化”，
	“类型”：“数据框参数”，
	“网址”：“泰晤士河_流入_pywr Scenarios.h5"，
	“index_col”: “时间步”，
	“parse_dates”：真
}
```

## 结果

由于总模拟次数为四次，这是因为我们使用的是单个 **pywr 场景** 设置为 **气候变化**，其中包含 4 个场景。这些场景中的每一个都将单独运行，所有 4 次仿真的结果将显示每个输出结果，如下所示

<figure><img src="https://2456626420-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FroBiEJ09sszXPUfSv5uk%2Fuploads%2Fgit-blob-7b985a4169f74776d6a0f395dce2058d3f7ca16e%2Fimage%20(45).png?alt=media" alt=""><figcaption><p>模拟_流量（较低）_泰晤士河）</p></figcaption></figure>

<figure><img src="https://2456626420-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FroBiEJ09sszXPUfSv5uk%2Fuploads%2Fgit-blob-e1c64630c4a4be54dae8d96da6d1a9b2b83600eb%2Fimage%20(48).png?alt=media" alt=""><figcaption><p>simulated_volume（新水库）</p></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://water-strategy.gitbook.io/waterstrategy/zhong-guo-ren/jiao-cheng/pywr-scenarios-reading-external-dataframe-and-adding-custom-rules/reading-h5-dataframe-for-pywr-scenarios.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
