AI4Finance-Foundation / AI4Finance-Foundation/FinRL-Meta

An error when running examples /FinRL_Ensemble_StockTrading_ICAIF_2020.ipynb

Aperta
#294 5 commenti 1 reazione 0 assegnatari Vedi su GitHub
bug
Lingua principale
Python
Stelle
1.9k
Fork
751
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Descrizione

I was running the example in the title, and run into this error "If using all scalar values, you must pass an index". The error traces back to the code below and it is because trade_env.render() in finrl.agents.stablebaselines3.models.py returns None. It seems that the version of the stablebaselines3 I installed is not correct. Has anyone run into a similar issue?

```
for i in range(len(trade_data.index.unique())):
action, _states = model.predict(trade_obs)
trade_obs, rewards, dones, info = trade_env.step(action)
if i == (len(trade_data.index.unique()) - 2):
# print(env_test.render())
**last_state = trade_env.render()**

**df_last_state = pd.DataFrame({"last_state": last_state})**
```

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.