SCADA 压力流量清洗模块新增数据填补
This commit is contained in:
@@ -237,7 +237,7 @@ async def fastapi_valve_close_analysis(
|
||||
return result or "success"
|
||||
|
||||
|
||||
@router.get("/valveisolation/")
|
||||
@router.get("/valve_isolation_analysis/")
|
||||
async def valve_isolation_endpoint(network: str, accident_element: str):
|
||||
return analyze_valve_isolation(network, accident_element)
|
||||
|
||||
@@ -587,11 +587,10 @@ async def fastapi_scada_device_data_cleaning(
|
||||
if device_id in type_scada_data:
|
||||
values = [record["value"] for record in type_scada_data[device_id]]
|
||||
df[device_id] = values
|
||||
value_df = df.drop(columns=["time"])
|
||||
if device_type == "pressure":
|
||||
cleaned_value_df = Pdataclean.clean_pressure_data_df_km(value_df)
|
||||
cleaned_value_df = Pdataclean.clean_pressure_data_df_km(df)
|
||||
elif device_type == "pipe_flow":
|
||||
cleaned_value_df = Fdataclean.clean_flow_data_df_kf(value_df)
|
||||
cleaned_value_df = Fdataclean.clean_flow_data_df_kf(df)
|
||||
cleaned_value_df = pd.DataFrame(cleaned_value_df)
|
||||
cleaned_df = pd.concat([df["time"], cleaned_value_df], axis=1)
|
||||
influxdb_api.import_multicolumn_data_from_dict(
|
||||
|
||||
Reference in New Issue
Block a user