emission_detect_model/README.md

142 lines
3.6 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 污染物排放动态监测接口文档
## 接口文档
### Docker服务地址
`xxx.xxx.xxx.xxx:8788/emission/`
### 接口调用方式
POST
### 输入
输入为json串具体内容如下
```
{
"key": ['company', 'unit', 'time', 'boiler', 'steam', ..., 'lat']
"data":[
[第一条数据顺序与key相同],
[第二条数据],
...
[第n条数据],
]
}
```
`key`字段表示输入数据的列名,`data`字段为传入的机组和排放值的二维数组,具体如下:
|字段|类型|含义|是否由爬虫获取|
|----|----|----|----|
|company|str|电厂名称|否|
|unit|str|机组编号|否|
|time|str|时间,'yyyy-mm-dd hh:MM:ss'|是|
|boiler|str|锅炉类型|否|
|steam|str|汽轮机类型|否|
|cold|str|冷却方式|否|
|pressure|str|压力参数|否|
|capacity|float|装机容量|否|
|nox|float|氮氧化物($NO_x$)浓度数值($mg/m^3$)|是|
|so2|float|二氧化硫($SO_2$)浓度数值($mg/m^3$)|是|
|smoke|float|烟气浓度($mg/m^3$)|是|
|flow|float|烟气流量($m^3/h$)|是|
|o2|float|含氧量($O_2$, %)|是|
|temp|float|温度(℃)|是|
|evaporation|float|机组额定蒸发量(t/h)|否|
|caloric|float|低位发热值(一般为10-30 GJ/t)|视情况而定|
|lon|str|经度|否|
|lat|str|纬度|否|
### 输出
输出为json串包含如下字段
```
{
"code": 200, # 若调用错误code为406
"msg": "若code为406返回该字段",
"data": {"company": [], "unit":[], "coal":[], ..., "pm10":[]} # 若code为200返回该字段
}
```
`data`字段对应模型返回的当前时刻的结果,具体如下:
|字段|类型|含义|
|----|----|----|
|company|str|电厂名称|
|unit|str|机组编号|
|time|str|时间,'yyyy-mm-dd hh:MM:ss'|
|coal|float|该时刻对应的煤耗(t)|
|co|float|一氧化碳排放量(kg)|
|co2|float|二氧化碳排放量(kg)|
|vocs|float|VOCs排放量(kg)|
|pm25|float|PM2.5排放量(kg)|
|pm10|float|PM10排放量(kg)|
## 示例
### 输入示例
```
{
"key": ["boiler",
"steam",
"cold",
"pressure",
"nox",
"so2",
"smoke",
"flow",
"o2",
"temp",
"evaporation",
"caloric",
"capacity",
"lon",
"lat",
"time",
"company",
"unit"],
"data": [
["煤粉", "凝气式", "空冷-直接空冷", "超超临界", 3.68, 21.42, 3.60, 1644322.11, 6.78, 56.01, 2080.0, 12.96, 600, 118.72, 43.59, "2023-06-28 11:21:07", "浙江秀舟热电", "1"],
["W火焰炉", "凝气式", "空冷-间接空冷", "超临界", 4.68, 12.42, 2.60, 1147852.11, 9.32, 56.01, 1060.0, 12.96, 1000, 118.72, 43.59, "2023-06-28 11:21:07", "浙江秀舟热电", "2"],
]
}
```
### 输出示例(调用成功)
```
{
"code": 200,
"data": {
"company": [
"浙江秀舟热电",
"浙江秀舟热电"
],
"unit": [
"1",
"2"
],
"time": [
"2023-06-28 11:21:07",
"2023-06-28 11:21:07"
]
"coal": [
473.88829463709556,
444.42982231624063
],
"co": [
947.7765892741911,
888.8596446324813
],
"co2": [
188.88,
256.99
]
"vocs": [
1023.5987164161264,
959.9684162030799
],
"pm25": [
0.35560232895598914,
0.28232093872217645
],
"pm10": [
1.3631422609979584,
1.0822302651016766
]
}
}
```
### 输出示例(调用失败)
```
{
"code": 406,
"msg": "Input is None, please check!" # or other Exception
}
```