-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TypeError: StockTradingEnv.reset() got an unexpected keyword argument 'seed' #1022
Comments
i am running to the same error |
Hello, I am also getting same above error on Colab, when running the Stock_NeurIPS2018_2_Train.ipynb from FinRL-Tutorials/1-Introduction/Stock_NeurIPS2018/Stock_NeurIPS2018_2_Train.ipynb python at Environment for training command
|
Hi, I have the same issue when running: df_summary = ensemble_agent.run_ensemble_strategy(A2C_model_kwargs, in: FinRL/examples/FinRL_Ensemble_StockTrading_ICAIF_2020.ipynb |
to
|
tired the proposed change to the file line 358 def reset(self, seed=None): , got this: |
Which file did you exactly change? Was it directly inside site-packages folder? |
i made a copy of the finrl to my own repository from : https://github.com/AI4Finance-Foundation/FinRL/tree/master/ |
Hi! I'm running into the same error and also tried the above way, changing to the file line 358, when running the Stock_NeurIPS2018_SB3.ipynb on Colab from |
the proposed change from def reset(self): |
Also getting the same error @thinkscriptfan pointed.
|
You can fix this by making modified class for StockTradingEnv:
|
I am new to Python , can you please clarify which area the above code was inserted ? thanks in advance. |
Right before calling the StockTradingEnv class. Place this before and then change StockTradingEnv to MyStockTradingEnv |
Sorry , Still not clear . , where is StockTradingEnv class called ? which file , which line ? |
srikantamehta is suggesting an alternative to my solution of fixing the above |
…, DummyVecEnv.reset() method passes a `seed` argument to its list of envs. Since StockTradingEnv.reset() does not expect any argument it results in an error. This commit fixes AI4Finance-Foundation#1022.
AI4Finance-Foundation#1022 StockTradingEnv.reset()' doesn't take any arguments. You can fix this by changing line 358 of finrl/meta/env_stock_trading/env_stocktrading.py from def reset(self): to def reset(self, seed=None):
The "StockTradingEnv.reset()" error should be related to modifications to the Release 2.0.0aXX (WIP) of Stable-Baselines3. |
Run Stock_NeurIPS2018_2_Train.ipynb in FinRL/examples
Colab report error
thanks!
The text was updated successfully, but these errors were encountered: