Commit 6bc06110 authored by rico.liu's avatar rico.liu

update

parent bb1f93da
No preview for this file type
No preview for this file type
...@@ -16,7 +16,7 @@ def get_average(list): ...@@ -16,7 +16,7 @@ def get_average(list):
sum += item sum += item
return sum/len(list) return sum/len(list)
async def get_brand_info(brand_list,url_brand_list,name_list,url_name_list): def get_brand_info(brand_list,url_brand_list,name_list,url_name_list):
''' '''
获取指数品牌信息 获取指数品牌信息
...@@ -115,7 +115,7 @@ async def get_brand_info(brand_list,url_brand_list,name_list,url_name_list): ...@@ -115,7 +115,7 @@ async def get_brand_info(brand_list,url_brand_list,name_list,url_name_list):
async def get_predict_category_with_textcnn(name_list,url_name_list): def get_predict_category_with_textcnn(name_list,url_name_list):
''' '''
使用模型预测类别 使用模型预测类别
''' '''
...@@ -156,7 +156,7 @@ async def get_predict_category_with_textcnn(name_list,url_name_list): ...@@ -156,7 +156,7 @@ async def get_predict_category_with_textcnn(name_list,url_name_list):
async def get_classify_info(category_list,pre_category_list): def get_classify_info(category_list,pre_category_list):
''' '''
获取指数类别信息 获取指数类别信息
''' '''
...@@ -266,7 +266,7 @@ async def get_classify_info(category_list,pre_category_list): ...@@ -266,7 +266,7 @@ async def get_classify_info(category_list,pre_category_list):
# ] # ]
async def get_extract_model(channel_list,category_list,name_list,url_name_list,brand_list,param_dict_list): def get_extract_model(channel_list,category_list,name_list,url_name_list,brand_list,param_dict_list):
''' '''
提取型号 提取型号
''' '''
......
...@@ -13,7 +13,7 @@ from public.SKUMatchInfo.public_function import Index ...@@ -13,7 +13,7 @@ from public.SKUMatchInfo.public_function import Index
from elasticsearch import Elasticsearch from elasticsearch import Elasticsearch
async def get_sku_match_res(channel,sku_list,engine): def get_sku_match_res(channel,sku_list,engine):
'''对供应商提供的SKU进行排重''' '''对供应商提供的SKU进行排重'''
try: try:
...@@ -90,7 +90,7 @@ async def get_sku_match_res(channel,sku_list,engine): ...@@ -90,7 +90,7 @@ async def get_sku_match_res(channel,sku_list,engine):
msg = str(e) msg = str(e)
return code,msg,{} return code,msg,{}
async def get_sku_match_res_backup(channel,sku_list): def get_sku_match_res_backup(channel,sku_list):
'''对供应商提供的SKU进行排重''' '''对供应商提供的SKU进行排重'''
try: try:
...@@ -133,7 +133,7 @@ async def get_sku_match_res_backup(channel,sku_list): ...@@ -133,7 +133,7 @@ async def get_sku_match_res_backup(channel,sku_list):
return code,msg,{} return code,msg,{}
async def get_url_match_res(channel_type,url_list): def get_url_match_res(channel_type,url_list):
'''对供应商提供的url进行排重''' '''对供应商提供的url进行排重'''
try: try:
...@@ -203,7 +203,7 @@ async def get_url_match_res(channel_type,url_list): ...@@ -203,7 +203,7 @@ async def get_url_match_res(channel_type,url_list):
return code,msg,{} return code,msg,{}
async def get_name_match_res(channel_type,name_list): def get_name_match_res(channel_type,name_list):
'''对供应商提供的url中的名字进行排重''' '''对供应商提供的url中的名字进行排重'''
try: try:
...@@ -272,7 +272,7 @@ async def get_name_match_res(channel_type,name_list): ...@@ -272,7 +272,7 @@ async def get_name_match_res(channel_type,name_list):
return code,msg,{} return code,msg,{}
async def get_model_match_res(cust_category_list,zgc_brand_code_list,model_list,price_list): def get_model_match_res(cust_category_list,zgc_brand_code_list,model_list,price_list):
#模糊匹配,使用品牌+型号+价格 返回的结果按价格差的生序排列,取前三 #模糊匹配,使用品牌+型号+价格 返回的结果按价格差的生序排列,取前三
...@@ -431,7 +431,7 @@ async def get_model_match_res(cust_category_list,zgc_brand_code_list,model_list, ...@@ -431,7 +431,7 @@ async def get_model_match_res(cust_category_list,zgc_brand_code_list,model_list,
async def get_zgc_name_match_res(zgc_name_list): def get_zgc_name_match_res(zgc_name_list):
#匹配产品名称 #匹配产品名称
......
...@@ -12,7 +12,7 @@ import re ...@@ -12,7 +12,7 @@ import re
import pandas as pd import pandas as pd
async def get_zol_info(zgc_categoryname,brand,model): def get_zol_info(zgc_categoryname,brand,model):
#获取zol参数信息,使用品牌+型号进行搜索 #获取zol参数信息,使用品牌+型号进行搜索
try: try:
cname = ''.join(re.findall(r'[0-9\u4E00-\u9FA5]', str(brand))).strip() cname = ''.join(re.findall(r'[0-9\u4E00-\u9FA5]', str(brand))).strip()
...@@ -38,7 +38,7 @@ async def get_zol_info(zgc_categoryname,brand,model): ...@@ -38,7 +38,7 @@ async def get_zol_info(zgc_categoryname,brand,model):
async def get_zgc_params(zgc_categoryname,params_list): def get_zgc_params(zgc_categoryname,params_list):
#获取zgc参数项 #获取zgc参数项
try: try:
conn_zi_new = pymssql.connect(host='123.56.115.207', user='zgcprice3311',password='zgcprice20200628',database= 'ZI_NEW',autocommit=True) conn_zi_new = pymssql.connect(host='123.56.115.207', user='zgcprice3311',password='zgcprice20200628',database= 'ZI_NEW',autocommit=True)
...@@ -90,7 +90,7 @@ async def get_zgc_params(zgc_categoryname,params_list): ...@@ -90,7 +90,7 @@ async def get_zgc_params(zgc_categoryname,params_list):
return code,msg,{} return code,msg,{}
async def get_zgc_param_values(zgc_categoryname,id_list,param_value_dict_list): def get_zgc_param_values(zgc_categoryname,id_list,param_value_dict_list):
#获取zgc参数值 #获取zgc参数值
try: try:
conn_zi_new = pymssql.connect(host='123.56.115.207', user='zgcprice3311',password='zgcprice20200628',database= 'ZI_NEW',autocommit=True) conn_zi_new = pymssql.connect(host='123.56.115.207', user='zgcprice3311',password='zgcprice20200628',database= 'ZI_NEW',autocommit=True)
...@@ -199,7 +199,7 @@ async def get_zgc_param_values(zgc_categoryname,id_list,param_value_dict_list): ...@@ -199,7 +199,7 @@ async def get_zgc_param_values(zgc_categoryname,id_list,param_value_dict_list):
return code,msg,{} return code,msg,{}
async def get_ner_params(zgc_categorycode,name): def get_ner_params(zgc_categorycode,name):
#NER 识别产品参数 #NER 识别产品参数
try: try:
ner = LSTMNER(zgc_categorycode) ner = LSTMNER(zgc_categorycode)
......
...@@ -12,7 +12,7 @@ import datetime ...@@ -12,7 +12,7 @@ import datetime
import time import time
import uuid import uuid
async def stock_in_brand(new_brand_list): def stock_in_brand(new_brand_list):
#新建品牌 #新建品牌
...@@ -143,7 +143,7 @@ def dael_name_content(skuname,brand): ...@@ -143,7 +143,7 @@ def dael_name_content(skuname,brand):
async def get_new_name(category,brandname,params): def get_new_name(category,brandname,params):
try: try:
conn_zi_new = pymssql.connect(host='123.56.115.207', user='zgcprice3311',password='zgcprice20200628',database= 'ZI_NEW',autocommit=True) conn_zi_new = pymssql.connect(host='123.56.115.207', user='zgcprice3311',password='zgcprice20200628',database= 'ZI_NEW',autocommit=True)
cursor_zi_new = conn_zi_new.cursor() cursor_zi_new = conn_zi_new.cursor()
...@@ -314,7 +314,7 @@ async def get_new_name(category,brandname,params): ...@@ -314,7 +314,7 @@ async def get_new_name(category,brandname,params):
async def stock_in_product(zi_brandname_list,zi_brandcode_list,zi_subcategoryname,zi_subcategorycode,std_params_list,newname_list): def stock_in_product(zi_brandname_list,zi_brandcode_list,zi_subcategoryname,zi_subcategorycode,std_params_list,newname_list):
# #
try: try:
...@@ -740,7 +740,7 @@ def stock_in_params(params_dict_list,category_id_list,category_name_list,mode): ...@@ -740,7 +740,7 @@ def stock_in_params(params_dict_list,category_id_list,category_name_list,mode):
return code,msg return code,msg
async def stock_in_sku_relationship(sku_list,code_list,channel_list): def stock_in_sku_relationship(sku_list,code_list,channel_list):
#导入sku对应关系 #导入sku对应关系
...@@ -777,7 +777,7 @@ async def stock_in_sku_relationship(sku_list,code_list,channel_list): ...@@ -777,7 +777,7 @@ async def stock_in_sku_relationship(sku_list,code_list,channel_list):
async def stock_in_price(sku_list,goods_name_list,price_list,url_list,channel_id_list): def stock_in_price(sku_list,goods_name_list,price_list,url_list,channel_id_list):
#导入价格信息 #导入价格信息
try: try:
...@@ -1027,7 +1027,7 @@ async def stock_in_price(sku_list,goods_name_list,price_list,url_list,channel_id ...@@ -1027,7 +1027,7 @@ async def stock_in_price(sku_list,goods_name_list,price_list,url_list,channel_id
async def stock_in_attr_relationship(channel,categoryname_list,subtitle_list,outsubtitle_list): def stock_in_attr_relationship(channel,categoryname_list,subtitle_list,outsubtitle_list):
#导入参数项对应关系 #导入参数项对应关系
...@@ -1097,7 +1097,7 @@ def stock_in_category_relationship(channel,categoryname_list,zi_categoryname_lis ...@@ -1097,7 +1097,7 @@ def stock_in_category_relationship(channel,categoryname_list,zi_categoryname_lis
return code,msg return code,msg
''' '''
async def stock_in_category_relationship_to_server(channel,categoryname_list,zi_categoryname_list,zi_categorycode_list): def stock_in_category_relationship_to_server(channel,categoryname_list,zi_categoryname_list,zi_categorycode_list):
#导入类别对应关系(入服务库) #导入类别对应关系(入服务库)
......
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