File tree Expand file tree Collapse file tree 9 files changed +88
-353973
lines changed Expand file tree Collapse file tree 9 files changed +88
-353973
lines changed File renamed without changes.
Original file line number Diff line number Diff line change 1+ mkdir data
2+ wget https://paddlerec.bj.bcebos.com/datasets/Beauty/beauty.txt
3+ mv beauty.txt ./data/
4+ python data_augment_candi_gen.py
Original file line number Diff line number Diff line change 1+ # Copyright (c) 2020 PaddlePaddle Authors. All Rights Reserved.
2+ #
3+ # Licensed under the Apache License, Version 2.0 (the "License");
4+ # you may not use this file except in compliance with the License.
5+ # You may obtain a copy of the License at
6+ #
7+ # http://www.apache.org/licenses/LICENSE-2.0
8+ #
9+ # Unless required by applicable law or agreed to in writing, software
10+ # distributed under the License is distributed on an "AS IS" BASIS,
11+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+ # See the License for the specific language governing permissions and
13+ # limitations under the License.
14+
15+ # global settings
16+
17+ runner :
18+ train_data_dir : " data/train/"
19+ train_reader_path : " data_reader" # importlib format
20+ use_gpu : False
21+ train_batch_size : 1
22+ data_batch_size : 1
23+ epochs : 1
24+ print_interval : 1
25+
26+ model_save_path : " output_model_bert4rec_demo"
27+ test_data_dir : " data/test/"
28+ infer_reader_path : " data_reader" # importlib format
29+ infer_batch_size : 1
30+ infer_load_path : " output_model_bert4rec_demo"
31+ infer_start_epoch : 0
32+ infer_end_epoch : 1
33+
34+
35+ # hyper parameters of user-defined network
36+ hyper_parameters :
37+ # optimizer config
38+ optimizer :
39+ learning_rate : 0.0001
40+ weight_decay : 0.01
41+
42+ _emb_size : 64
43+ _n_layer : 2
44+ _n_head : 2
45+ _voc_size : 54546
46+ _max_position_seq_len : 50
47+ _sent_types : 2
48+ hidden_act : " gelu"
49+ _dropout : 0.5
50+ _attention_dropout : 0.2
51+ _param_initializer : 0.02
52+ num_test_user : 1
53+
Original file line number Diff line number Diff line change 1515# global settings
1616
1717runner :
18- train_data_dir : " data/train"
18+ train_data_dir : " ../../../datasets/Beauty/ data/train"
1919 train_reader_path : " data_reader" # importlib format
2020 use_gpu : True
2121 train_batch_size : 1
2222 data_batch_size : 256
2323 epochs : 10
2424 print_interval : 100
2525
26- model_save_path : " output_model_bert4rec "
27- test_data_dir : " data/test"
26+ model_save_path : " output_model_bert4rec_all "
27+ test_data_dir : " ../../../datasets/Beauty/ data/test"
2828 infer_reader_path : " data_reader" # importlib format
2929 infer_batch_size : 1
30- infer_load_path : " output_model_bert4rec "
30+ infer_load_path : " output_model_bert4rec_all "
3131 infer_start_epoch : 9
3232 infer_end_epoch : 10
3333
You can’t perform that action at this time.
0 commit comments