Skip to content

Commit

Permalink
Re-run
Browse files Browse the repository at this point in the history
  • Loading branch information
fridrichmrtn committed Sep 13, 2022
1 parent 3db31bf commit 11e3e2e
Showing 1 changed file with 13 additions and 11 deletions.
24 changes: 13 additions & 11 deletions code/ingestion/run-ingestion.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,31 +24,33 @@

# CUSTOMER MODEL
#_prerun_optimize_recom(dataset_name)
# customer_model = construct_customer_model(
# dataset_name, time_steps=4, week_target=4)
# save_customer_model(
# customer_model, dataset_name, overwrite=True)
customer_model = construct_customer_model(
dataset_name, time_steps=4, week_target=4)
save_customer_model(
customer_model, dataset_name, overwrite=True)

# COMMAND ----------


#
## REES46

dataset_name = "rees46"
#dataset_name = "rees46"

# LOAD TRANSFORM
#events = construct_events(dataset_name)
#save_events(events, dataset_name)

# CUSTOMER MODEL
#_prerun_optimize_recom(dataset_name)
customer_model = construct_customer_model(
dataset_name, time_steps=7, week_target=4)
save_customer_model(customer_model,
dataset_name, overwrite=True)
# customer_model = construct_customer_model(
# dataset_name, time_steps=7, week_target=4)
# save_customer_model(customer_model,
# dataset_name, overwrite=True)

# COMMAND ----------

spark.table("churndb.rees46_customer_model").write.format("parquet")\
.mode("overwrite").save("dbfs:/mnt/rees46/raw/customer_model/")
spark.table("churndb.retailrocket_customer_model").write.format("parquet")\
.mode("overwrite").save("dbfs:/mnt/retailrocket/raw/customer_model/")
#spark.table("churndb.rees46_customer_model").write.format("parquet")\
# .mode("overwrite").save("dbfs:/mnt/rees46/raw/customer_model/")

0 comments on commit 11e3e2e

Please sign in to comment.