Commit 2611aa17 authored by 赵威's avatar 赵威

Merge branch 'offic' into 'master'

Offic

See merge request !567
parents 051d2f64 169a1760
......@@ -422,7 +422,7 @@ class ESPerform(object):
"_script": {
"order": "desc",
"script": {
"inline": "10*doc['topic_ctr_30'].value+doc['like_rate_30'].value+2*doc['topic_ctr_all'].value+doc['like_rate_all'].value"
"inline": "3*doc['topic_ctr_30'].value+2*doc['topic_ctr_all'].value"
},
"type": "number"
}
......@@ -452,7 +452,7 @@ class ESPerform(object):
topic_id_dict = dict()
for item in result_dict["hits"]:
topic_id_dict[str(item["_source"]["id"])] = item["_source"]["user_id"]
logging.info("get_tag_topic_list_dict:gyz" + str(q) + str(result_dict))
logging.info("get_tag_topic_list_dict:zw" + str(q) + str(result_dict))
return topic_id_list, topic_id_dict
except:
logging.error("catch exception,err_msg:%s" % traceback.format_exc())
......@@ -546,7 +546,7 @@ class ESPerform(object):
"_script": {
"order": "desc",
"script": {
"inline": "10*doc['pictorial_ctr_30'].value+10*doc['like_rate_30'].value+3*doc['pictorial_ctr_all'].value+2*doc['like_rate_all'].value"
"inline": "3*doc['pictorial_ctr_30'].value+2*doc['pictorial_ctr_all'].value"
},
"type": "number"
}
......@@ -567,7 +567,7 @@ class ESPerform(object):
offset=0, size=size)
pictorial_id_list = [item["_source"]["id"] for item in result_dict["hits"]]
logging.info("get_tag_pictorial_id_list:gyz" + str(q) + str(result_dict))
logging.info("get_tag_pictorial_id_list:zw" + str(q) + str(result_dict))
return pictorial_id_list
except:
logging.error("catch exception,err_msg:%s" % traceback.format_exc())
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment