Commit ddc99ca1 authored by 郭羽's avatar 郭羽

训练数据时间更改

parent 9aeeb079
...@@ -709,7 +709,7 @@ if __name__ == '__main__': ...@@ -709,7 +709,7 @@ if __name__ == '__main__':
train_columns = model_columns + ["label", "timestamp"] train_columns = model_columns + ["label", "timestamp"]
trainSamples = samplesWithUserFeatures.select(*train_columns) trainSamples = samplesWithUserFeatures.select(*train_columns)
print("write to hdfs start...") print("write to hdfs start...")
splitTimestamp = int(time.mktime(time.strptime(endDay, "%Y%m%d"))) splitTimestamp = int(time.mktime(time.strptime(addDays(0), "%Y%m%d")))
splitAndSaveTrainingTestSamplesByTimeStamp(trainSamples, splitTimestamp, TRAIN_FILE_PATH) splitAndSaveTrainingTestSamplesByTimeStamp(trainSamples, splitTimestamp, TRAIN_FILE_PATH)
print("write to hdfs success...") print("write to hdfs success...")
timestmp7 = int(round(time.time())) timestmp7 = int(round(time.time()))
......
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