FX Trading for >1 pair #1098
Unanswered
julianaddison
asked this question in
Q&A
Replies: 1 comment
-
Hi |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi, I've been trying the Forex example https://github.com/AI4Finance-Foundation/FinRL-Tutorials/blob/master/1-Introduction/ForexTrading_Demo.ipynb. I can run it for one forex pair (GBPUSD) using 1M candlestick intervals but have trouble running it for 2 forex pairs (GBPUSD and EURUSD).
There's a matrix multiplication issue when I try training the model with 2 or more forex pairs:
`
/usr/local/lib/python3.10/dist-packages/torch/nn/modules/linear.py in forward(self, input)
112
113 def forward(self, input: Tensor) -> Tensor:
--> 114 return F.linear(input, self.weight, self.bias)
115
116 def extra_repr(self) -> str:
RuntimeError: mat1 and mat2 shapes cannot be multiplied (5x34 and 33x64)
`
I'm unsure if this is a data preparation issue. I first processed GBPUSD and EURUSD separately into CSVs, and merged them into one CSV. Each CSV then contains 1M candlestick data and engineered features for one day for both forex pairs GBPUSD and EURUSD. Note the symbol columns refers to GBPUSD and EURUSD as GBPUSD=X and EURUSD=X respectively - also accounted for this in the config file. Attached a CSV file as an example.
forex_2023_1.csv
Do you have any idea what might be the issue?
Beta Was this translation helpful? Give feedback.
All reactions