SCADA 压力流量清洗模块新增数据填补
This commit is contained in:
@@ -405,10 +405,8 @@ class CompositeQueries:
|
||||
pressure_df = df[pressure_ids]
|
||||
# 重置索引,将 time 变为普通列
|
||||
pressure_df = pressure_df.reset_index()
|
||||
# 移除 time 列,准备输入给清洗方法
|
||||
value_df = pressure_df.drop(columns=["time"])
|
||||
# 调用清洗方法
|
||||
cleaned_value_df = clean_pressure_data_df_km(value_df)
|
||||
cleaned_value_df = clean_pressure_data_df_km(pressure_df)
|
||||
# 添加 time 列到首列
|
||||
cleaned_df = pd.concat([pressure_df["time"], cleaned_value_df], axis=1)
|
||||
# 将清洗后的数据写回数据库
|
||||
@@ -432,10 +430,8 @@ class CompositeQueries:
|
||||
flow_df = df[flow_ids]
|
||||
# 重置索引,将 time 变为普通列
|
||||
flow_df = flow_df.reset_index()
|
||||
# 移除 time 列,准备输入给清洗方法
|
||||
value_df = flow_df.drop(columns=["time"])
|
||||
# 调用清洗方法
|
||||
cleaned_value_df = clean_flow_data_df_kf(value_df)
|
||||
cleaned_value_df = clean_flow_data_df_kf(flow_df)
|
||||
# 添加 time 列到首列
|
||||
cleaned_df = pd.concat([flow_df["time"], cleaned_value_df], axis=1)
|
||||
# 将清洗后的数据写回数据库
|
||||
|
||||
Reference in New Issue
Block a user