You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I just transferred it (FinRL-Tutorials/3-Practical/FinRL_MultiCrypto_Trading.ipynb) to a file (main.py)
Error 1:
If I want to DEBUG my script (main.py) - I get an error:
'''
conda activate base
(base) drulye@drulye-MS-7885:~/vscode/MCpypto$ conda activate base
/usr/bin/env /home/drulye/anaconda3/bin/python /home/drulye/.vscode/extensions/ms-python.python-2022.20.1/pythonFiles/lib/python/debugpy/adapter/../../debugpy/launcher 36507 -- /home/drulye/vscode/MCpypto/main.py
(base) drulye@drulye-MS-7885:~/vscode/MCpypto$ /usr/bin/env /home/drulye/anaconda3/bin/python /home/drulye/.vscode/extensions/ms-python.python-2022.20.1/pythonFiles/lib/python/debugpy/adapter/../../debugpy/launcher 36507 -- /home/drulye/vscode/MCpypto/main.py
/home/drulye/anaconda3/lib/python3.9/site-packages/scipy/__init__.py:146: UserWarning: A NumPy version >=1.16.5 and <1.23.0 is required for this version of SciPy (detected version 1.23.5
warnings.warn(f"A NumPy version >={np_minversion} and <{np_maxversion}"
QObject::moveToThread: Current thread (0x8cbc810) is not the object's thread (0x904ade0).
Cannot move to target thread (0x8cbc810)
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "/home/drulye/anaconda3/lib/python3.9/site-packages/cv2/qt/plugins" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
Available platform plugins are: xcb, eglfs, minimal, minimalegl, offscreen, vnc, webgl.
(base) drulye@drulye-MS-7885:~/vscode/MCpypto$
'''
Error 2:
If I want to RUN my script (main.py) - I get an error:
'''
conda activate base
(base) drulye@drulye-MS-7885:~/vscode/MCpypto$ conda activate base
/home/drulye/anaconda3/bin/python /home/drulye/vscode/MCpypto/main.py
(base) drulye@drulye-MS-7885:~/vscode/MCpypto$ /home/drulye/anaconda3/bin/python /home/drulye/vscode/MCpypto/main.py
/home/drulye/anaconda3/lib/python3.9/site-packages/scipy/__init__.py:146: UserWarning: A NumPy version >=1.16.5 and <1.23.0 is required for this version of SciPy (detected version 1.23.5
warnings.warn(f"A NumPy version >={np_minversion} and <{np_maxversion}"
binance successfully connected
Using cached file ./cache/BTCUSDT_ETHUSDT_ADAUSDT_BNBUSDT_XRPUSDT_SOLUSDT_DOTUSDT_DOGEUSDT_AVAXUSDT_UNIUSDT_binance_2021-09-01_2021-09-02_5m.pickle
tech_indicator_list: ['macd', 'rsi', 'cci', 'dx']
indicator: macd
indicator: rsi
indicator: cci
indicator: dx
Succesfully add technical indicators
Successfully transformed into array
| Arguments Remove cwd: ./test_ppo
Traceback (most recent call last):
File "/home/drulye/vscode/MCpypto/main.py", line 329, in <module>
train(start_date=TRAIN_START_DATE,
File "/home/drulye/vscode/MCpypto/main.py", line 89, in train
trained_model = agent.train_model(model=model,
File "/home/drulye/vscode/FinRL-Meta/agents/elegantrl_models.py", line 79, in train_model
train_and_evaluate(model)
File "/home/drulye/vscode/ElegantRL/elegantrl/train/run.py", line 95, in train_and_evaluate
agent = init_agent(args, gpu_id, env)
File "/home/drulye/vscode/ElegantRL/elegantrl/train/run.py", line 24, in init_agent
agent = args.agent_class(args.net_dim, args.state_dim, args.action_dim, gpu_id=gpu_id, args=args)
File "/home/drulye/vscode/ElegantRL/elegantrl/agents/AgentPPO.py", line 40, in __init__
AgentBase.__init__(self, net_dim, state_dim, action_dim, gpu_id, args)
File "/home/drulye/vscode/ElegantRL/elegantrl/agents/AgentBase.py", line 57, in __init__
self.act = act_class(net_dim, state_dim, action_dim).to(self.device)
File "/home/drulye/vscode/ElegantRL/elegantrl/agents/net.py", line 397, in __init__
self.net = build_mlp_net(dims=[state_dim, *dims, action_dim])
TypeError: Value after * must be an iterable, not int
(base) drulye@drulye-MS-7885:~/vscode/MCpypto$
'''
My script file:
main.py
Import Related Packages
import math
import numpy as np
import sys
sys.path.insert(0, "/home/drulye/vscode/FinRL")
sys.path.insert(0, "/home/drulye/vscode/ElegantRL")
sys.path.insert(0, "/home/drulye/vscode/FinRL-Meta")
from agents.elegantrl_models import DRLAgent as DRLAgent_erl
from agents.rllib_models import DRLAgent as DRLAgent_rllib
from agents.stablebaselines3_models import DRLAgent as DRLAgent_sb3
from meta.data_processor import DataProcessor
I just transferred it (FinRL-Tutorials/3-Practical/FinRL_MultiCrypto_Trading.ipynb) to a file (main.py)
Error 1:
If I want to DEBUG my script (main.py) - I get an error:
'''
'''
Error 2:
If I want to RUN my script (main.py) - I get an error:
'''
'''
My script file:
main.py
Import Related Packages
Function for Training
Function for Testing
Multiple Cryptocurrencies Trading Env
Set Parameters
Training
Testing
Plotting
TODO: Let's leave it for later
The text was updated successfully, but these errors were encountered: