Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
F
ffm-baseline
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ML
ffm-baseline
Commits
56d3e094
Commit
56d3e094
authored
Feb 25, 2019
by
张彦钊
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of git.wanmeizhensuo.com:ML/ffm-baseline
修改模型训练参数num_epochs
parents
c1757fcc
b15d0eea
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
temp_count.scala
eda/feededa/src/main/scala/com/gmei/temp_count.scala
+7
-7
No files found.
eda/feededa/src/main/scala/com/gmei/temp_count.scala
View file @
56d3e094
...
@@ -756,7 +756,7 @@ object find_reason {
...
@@ -756,7 +756,7 @@ object find_reason {
val
all_clk
=
sc
.
sql
(
val
all_clk
=
sc
.
sql
(
s
"""
s
"""
|select
'${stat_date}' as stat_date,
ov.cl_id as device_id
|select ov.cl_id as device_id
|from online.tl_hdfs_maidian_view ov left join agency_id
|from online.tl_hdfs_maidian_view ov left join agency_id
|on ov.cl_id = agency_id.device_id
|on ov.cl_id = agency_id.device_id
|where ov.action = 'on_click_diary_card'
|where ov.action = 'on_click_diary_card'
...
@@ -771,10 +771,9 @@ object find_reason {
...
@@ -771,10 +771,9 @@ object find_reason {
//1.当天老用户中的点击用户数
//1.当天老用户中的点击用户数
val
old_clk_count
=
sc
.
sql
(
val
old_clk_count
=
sc
.
sql
(
s
"""
s
"""
|select '${stat_date}' as stat_date,count(
oc.device_id
) as old_clk_count
|select '${stat_date}' as stat_date,count(
distinct(oc.device_id)
) as old_clk_count
|from all_clk_diary_card oc inner join device_id_old
|from all_clk_diary_card oc inner join device_id_old
|on oc.device_id = device_id_old.device_id
|on oc.device_id = device_id_old.device_id
|group by stat_date
"""
.
stripMargin
"""
.
stripMargin
)
)
old_clk_count
.
show
()
old_clk_count
.
show
()
...
@@ -793,10 +792,9 @@ object find_reason {
...
@@ -793,10 +792,9 @@ object find_reason {
//2.当天新用户中的点击用户数
//2.当天新用户中的点击用户数
val
new_clk_count
=
sc
.
sql
(
val
new_clk_count
=
sc
.
sql
(
s
"""
s
"""
|select '${stat_date}' as stat_date,count(
oc.device_id
) as new_clk_count
|select '${stat_date}' as stat_date,count(
distinct(oc.device_id)
) as new_clk_count
|from all_clk_diary_card oc inner join device_id_new
|from all_clk_diary_card oc inner join device_id_new
|on oc.device_id = device_id_new.device_id
|on oc.device_id = device_id_new.device_id
|group by stat_date
"""
.
stripMargin
"""
.
stripMargin
)
)
//2.1 有点击的新用户
//2.1 有点击的新用户
...
@@ -815,8 +813,9 @@ object find_reason {
...
@@ -815,8 +813,9 @@ object find_reason {
val
old_count
=
sc
.
sql
(
val
old_count
=
sc
.
sql
(
s
"""
s
"""
|select '${stat_date}' as stat_date,count(distinct(dio.device_id)) as old_count
|select '${stat_date}' as stat_date,count(distinct(dio.device_id)) as old_count
|from device_id_old dio
inner
join agency_id
|from device_id_old dio
left
join agency_id
|on dio.device_id = agency_id.device_id
|on dio.device_id = agency_id.device_id
|where agency_id.device_id is null
"""
.
stripMargin
"""
.
stripMargin
)
)
...
@@ -824,8 +823,9 @@ object find_reason {
...
@@ -824,8 +823,9 @@ object find_reason {
val
new_count
=
sc
.
sql
(
val
new_count
=
sc
.
sql
(
s
"""
s
"""
|select '${stat_date}' as stat_date,count(distinct(din.device_id)) as new_count
|select '${stat_date}' as stat_date,count(distinct(din.device_id)) as new_count
|from device_id_new din
inner
join agency_id
|from device_id_new din
left
join agency_id
|on din.device_id = agency_id.device_id
|on din.device_id = agency_id.device_id
|where agency_id.device_id is null
"""
.
stripMargin
"""
.
stripMargin
)
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment