|
@@ -655,10 +655,10 @@ def video_new_rank2(data, size, top_K, flow_pool_P, ab_code, exp_config=None):
|
|
|
flow_recall_rank = flow_recall_rank[top_K:]
|
|
|
# 按概率 p 及score排序获取 size - k 个视频
|
|
|
flow_num = 0
|
|
|
- flowConfig = "0"
|
|
|
+ flowConfig = 0
|
|
|
if exp_config and exp_config['flowConfig']:
|
|
|
flowConfig = exp_config['flowConfig']
|
|
|
- if flowConfig == "1" and len(rov_recall_rank) > 0:
|
|
|
+ if flowConfig == 1 and len(rov_recall_rank) > 0:
|
|
|
for recall_item in rank_result:
|
|
|
flow_recall_name = recall_item.get("flowPool", '')
|
|
|
flow_num = flow_num + 1
|
|
@@ -814,10 +814,10 @@ def video_sanke_rank(data, size, top_K, flow_pool_P, ab_Code='', exp_config=None
|
|
|
rank_result.extend(flow_recall_rank[:top_K])
|
|
|
flow_recall_rank = flow_recall_rank[top_K:]
|
|
|
flow_num = 0
|
|
|
- flowConfig ="0"
|
|
|
+ flowConfig =0
|
|
|
if exp_config and exp_config['flowConfig']:
|
|
|
flowConfig = exp_config['flowConfig']
|
|
|
- if flowConfig == "1" and len(rov_recall_rank) > 0:
|
|
|
+ if flowConfig == 1 and len(rov_recall_rank) > 0:
|
|
|
rank_result.extend(rov_recall_rank[:top_K])
|
|
|
for recall_item in rank_result:
|
|
|
flow_recall_name = recall_item.get("flowPool", '')
|