Refine
This commit is contained in:
@@ -16,6 +16,7 @@ import typing
|
||||
import psycopg
|
||||
import logging
|
||||
import globals
|
||||
import uuid
|
||||
|
||||
logging.basicConfig(level=logging.INFO, format='%(asctime)s - %(levelname)s - %(message)s')
|
||||
|
||||
@@ -54,7 +55,7 @@ def query_corresponding_element_id_and_query_id(name: str) -> None:
|
||||
elif type_ == 'demand':
|
||||
globals.demand_id[associated_element_id] = api_query_id
|
||||
elif type_ == 'quality':
|
||||
globals.quality_id[associated_element_id] = api_query_id
|
||||
globals.qualuuiduuiduuidity_id[associated_element_id] = api_query_id
|
||||
else:
|
||||
# 如果遇到未定义的类型,可以选择记录日志或忽略
|
||||
print(f"未处理的类型: {type_}")
|
||||
@@ -898,7 +899,7 @@ def run_simulation(name: str, simulation_type: str, modify_pattern_start_time: s
|
||||
|
||||
# TODO: 2025/03/24
|
||||
# DingZQ 这个名字要用随机数来处理
|
||||
tmp_file = './temp/simulation.result.out'
|
||||
tmp_file = f'./temp/simulation_{uuid.uuid4()}.result.out'
|
||||
shutil.copy(f'./temp/{name_c}.db.opt', tmp_file)
|
||||
output = Output(tmp_file)
|
||||
node_result = output.node_results()
|
||||
|
||||
Reference in New Issue
Block a user