redistribute the demands

This commit is contained in:
xinzish
2024-04-12 23:59:09 +08:00
parent 330248041f
commit e8fddfb71a
3 changed files with 24 additions and 4 deletions

View File

@@ -2,6 +2,7 @@ from tjnetwork import *
from get_realValue import *
from get_hist_data import *
import datetime
from api.s36_wda_cal import *
ids=['2498','3854','3853','2510','2514','4780','4854']
@@ -54,7 +55,12 @@ def get_l_tank_leve()->float:
# test interface
if __name__ == '__main__':
if get_current_data()==True:
tQ=get_current_total_Q()
print(f"the current tQ is {tQ}\n")
data=get_hist_data(ids,conver_beingtime_to_ucttime('2024-04-10 15:05:00'),conver_beingtime_to_ucttime('2024-04-10 15:10:00'))
# if get_current_data()==True:
# tQ=get_current_total_Q()
# print(f"the current tQ is {tQ}\n")
# data=get_hist_data(ids,conver_beingtime_to_ucttime('2024-04-10 15:05:00'),conver_beingtime_to_ucttime('2024-04-10 15:10:00'))
open_project("beibeizone")
regions=get_all_service_area_ids("beibeizone")
for region in regions:
t_basedmds=api.s36_wda_cal.get_total_base_demand("beibeizone",region)
print(f"{region}:{t_basedmds}")