Commit 18dbee01 authored by mxx's avatar mxx

1

parent e7b2c71b
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.5.2 (D:\Program Files\Anaconda3\python.exe)" project-jdk-type="Python SDK" />
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.5.2 (D:\Program Files\anaconda3\python.exe)" project-jdk-type="Python SDK" />
</project>
\ No newline at end of file
......@@ -2,7 +2,7 @@
<module type="PYTHON_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$" />
<orderEntry type="inheritedJdk" />
<orderEntry type="jdk" jdkName="Python 3.5.2 (D:\Program Files\anaconda3\python.exe)" jdkType="Python SDK" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>
\ No newline at end of file
This diff is collapsed.
import redis
import json
params_dict={
#recommend方法
'startFacter':0.5,'cpaBiasRatioFacter':1.0,
'cpaOrientRatioFacter':0.5,
'cpaBiasThresholdFacter':2.0,
'cpcTargetRatioFacter':0.5,
'cpcOrientRatioFacter':0.01,
'cpcBiasThresholdFacter':1.0,
#熔断
'fuseOrientCostG1dFacter':50000.0,
'fuseOrientCostConvertbiasFacter':2.0,
#白名单参数
'wSlotOrientationConfidenceFacter':0.2,
'wSlotOrientationCostConvertBiasFacter':1.2,
#高置信黑名单参数
'bOrientConfidenceFacter1':1.0,
'bOrientCostConvertbiasFacter1':1.2,
'bSlotOrientationConfidenceFacter1':0.5,
'bSlotOrientationCostConvertBiasFacter1':3.5,
#低置信黑名单参数
'bOrientConfidenceFacter2':1.0,
'bOrientCostConvertbiasFacter2':1.5,
'bSlotOrientationConfidenceFacter2':0.5,
'bSlotOrientRadioFacter2':2.0,
}
params_key="NZ_K??_auto_manage_params"
params_value=json.dumps(params_dict)
......@@ -105,7 +105,7 @@ sql='''select advert_id,account_id,
when length(match_tag_nums)=22 then substr(match_tag_nums,13)
else match_tag_nums end match_tag_nums,avg(fee) fee
from advert.dws_advert_order_wide_v4_level_6_di
where dt>='{0}' and dt<='{1}' and advert_id is not null
where dt>='{0}' and dt<='{1}' and advert_id is not null and fee>0
group by advert_id,account_id,
case when length(match_tag_nums)=16 then substr(match_tag_nums,7)
when length(match_tag_nums)=22 then substr(match_tag_nums,13)
......
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