prices change

This commit is contained in:
chenxiaodong 2024-06-24 11:08:34 +08:00
parent c44b12896a
commit 879f01c22e
2 changed files with 16 additions and 8786 deletions

File diff suppressed because it is too large Load Diff

41
test.py
View File

@ -19,32 +19,23 @@
# model = YourModelClass() # 实例化你的模型 # model = YourModelClass() # 实例化你的模型
# model.load_state_dict(checkpoint) # model.load_state_dict(checkpoint)
# print(model) print(model)
# import pickle import pickle
#
# a = 'DDPG'
# b = 'PPO'
# c = 'SAC'
# d = 'TD3'
#
# a1 = '/reward_data.pkl'
# a2 = '/loss_data.pkl'
# a3 = '/test_data.pkl'
#
# filename = './Agent' + a + a3
#
# # 使用 'rb' 模式打开文件,读取二进制数据
# with open(filename, 'rb') as f:
# data = pickle.load(f)
#
# print(data)
import pandas as pd a = 'DDPG'
b = 'PPO'
c = 'SAC'
d = 'TD3'
# Load the CSV file a1 = '/reward_data.pkl'
file_path = 'data/prices_m.csv' a2 = '/loss_data.pkl'
price_df = pd.read_csv(file_path) a3 = '/test_data.pkl'
# Check the columns
print(price_df.columns)
filename = './Agent' + a + a3
# 使用 'rb' 模式打开文件,读取二进制数据
with open(filename, 'rb') as f:
data = pickle.load(f)
print(data)