()
| 15 | |
| 16 | |
| 17 | def read_config(): |
| 18 | bs_dic = {} |
| 19 | cur_path = os.path.dirname(os.path.realpath(__file__)) |
| 20 | config_path = os.path.join(cur_path, "config.yaml") |
| 21 | models=[] |
| 22 | with open(config_path, 'r', encoding='utf-8') as f: |
| 23 | config = yaml.safe_load(f.read()) |
| 24 | models = config["test_model"] |
| 25 | stock_tf = config["stocktf"] |
| 26 | for model in models: |
| 27 | bs_dic[model]=config['model_batchsize'][model] |
| 28 | |
| 29 | print("=" * 30) |
| 30 | print('%-20s%s'%("Model", "batch_size")) |
| 31 | for model in models: |
| 32 | print('%-20s%s'%(model, bs_dic[model])) |
| 33 | print("=" * 30) |
| 34 | return stock_tf, bs_dic, models |
| 35 | |
| 36 | |
| 37 | if __name__ == "__main__": |
no test coverage detected