Compare commits

...

13 Commits

Author SHA1 Message Date
Dobromir Popov
fdde2ff587 Add model files to gitignore 2025-04-09 15:51:30 +03:00
Dobromir Popov
690c61f230 Setup Git LFS for model files 2025-04-09 15:40:05 +03:00
Dobromir Popov
0148964409 Add model files to gitignore 2025-04-09 15:38:51 +03:00
Dobromir Popov
3e924b32ac models 2025-03-10 18:27:34 +02:00
Dobromir Popov
8dafb6d310 Merge commit '621a2505bd55db0f8295e5379638d7b1c7523620' 2025-03-10 16:43:19 +02:00
Dobromir Popov
621a2505bd models 2025-03-10 16:42:49 +02:00
Dobromir Popov
08b8da7c8f fix refactoring 2025-03-10 16:38:37 +02:00
Dobromir Popov
e884f0c9e6 added continious mode. fixed errors 2025-03-10 15:37:02 +02:00
Dobromir Popov
cfddc996d7 fixes 2025-03-10 14:53:21 +02:00
Dobromir Popov
6f78703ba1 plot charts 2025-03-10 14:48:29 +02:00
Dobromir Popov
715261a3f9 improvements 2025-03-10 13:32:35 +02:00
Dobromir Popov
2b1f00cbfc working on GPU 2025-03-10 13:15:30 +02:00
Dobromir Popov
643bc154a2 improvements 2025-03-10 13:07:07 +02:00
17 changed files with 193766 additions and 219 deletions

23
.gitignore vendored
View File

@ -32,6 +32,27 @@ crypto/sol/.vs/*
crypto/brian/models/best/*
crypto/brian/models/last/*
crypto/brian/live_chart.html
crypto/gogo2/models/*
crypto/gogo2/trading_bot.log
*.log
crypto/gogo2/checkpoints/trading_agent_episode_*.pt
*trading_agent_continuous_*.pt
*trading_agent_episode_*.pt
crypto/gogo2/models/trading_agent_continuous_150.pt
crypto/gogo2/checkpoints/trading_agent_episode_0.pt
crypto/gogo2/checkpoints/trading_agent_episode_10.pt
crypto/gogo2/checkpoints/trading_agent_episode_20.pt
crypto/gogo2/checkpoints/trading_agent_episode_40.pt
crypto/gogo2/models/trading_agent_best_pnl.pt
crypto/gogo2/models/trading_agent_best_reward.pt
crypto/gogo2/models/trading_agent_best_winrate.pt
crypto/gogo2/models/trading_agent_continuous_0.pt
crypto/gogo2/models/trading_agent_continuous_50.pt
crypto/gogo2/models/trading_agent_continuous_100.pt
crypto/gogo2/models/trading_agent_continuous_150.pt
crypto/gogo2/models/trading_agent_emergency.pt
crypto/gogo2/models/trading_agent_episode_0.pt
crypto/gogo2/models/trading_agent_episode_10.pt
crypto/gogo2/models/trading_agent_episode_20.pt
crypto/gogo2/models/trading_agent_episode_30.pt
crypto/gogo2/models/trading_agent_final.pt

1
crypto/gogo2/.gitattributes vendored Normal file
View File

@ -0,0 +1 @@
*.pt filter=lfs diff=lfs merge=lfs -text

1
crypto/gogo2/.gitignore vendored Normal file
View File

@ -0,0 +1 @@
*.pt

View File

@ -6,7 +6,7 @@
"type": "python",
"request": "launch",
"program": "main.py",
"args": ["--mode", "train", "--episodes", "1000"],
"args": ["--mode", "train", "--episodes", "100"],
"console": "integratedTerminal",
"justMyCode": true
},
@ -36,6 +36,15 @@
"args": ["--mode", "live"],
"console": "integratedTerminal",
"justMyCode": true
},
{
"name": "Continuous Training",
"type": "python",
"request": "launch",
"program": "main.py",
"args": ["--mode", "continuous", "--refresh-data"],
"console": "integratedTerminal",
"justMyCode": true
}
]
}

View File

@ -16,4 +16,9 @@ C:\Users\popov\miniforge3\Lib\site-packages\torch\amp\grad_scaler.py:132: UserWa
2025-03-10 12:11:30,927 - INFO - Starting training on device: cpu
2025-03-10 12:11:30,928 - ERROR - Training failed: 'TradingEnvironment' object has no attribute 'initialize_price_predictor'
2025-03-10 12:11:30,928 - INFO - Exchange connection closed
Backend tkagg is interactive backend. Turning interactive mode on.
Backend tkagg is interactive backend. Turning interactive mode on.
2025-03-10 12:35:14,489 - INFO - Episode 34: Reward=232.41, Balance=$98.47, Win Rate=70.6%, Trades=17, Episode PnL=$-1.33, Total PnL=$-559.78, Max Drawdown=7.0%, Pred Accuracy=99.9%

View File

@ -0,0 +1 @@
{"best_reward": 202.7441047517104, "best_pnl": 9.268344827764809, "best_win_rate": 73.33333333333333, "last_episode": 30, "timestamp": "2025-03-10T17:57:19.913481"}

4
crypto/gogo2/cuda.py Normal file
View File

@ -0,0 +1,4 @@
import torch
print(f"PyTorch version: {torch.__version__}")
print(f"CUDA available: {torch.cuda.is_available()}")
print(f"CUDA version: {torch.version.cuda if torch.cuda.is_available() else 'Not available'}")

File diff suppressed because it is too large Load Diff

View File

@ -46,6 +46,12 @@ pip install -r requirements.txt
```bash
MEXC_API_KEY=your_api_key
MEXC_API_SECRET=your_api_secret
cuda support
```bash
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118
```
## Usage

View File

@ -6,4 +6,5 @@ python-dotenv>=0.19.0
ccxt>=2.0.0
websockets>=10.0
tensorboard>=2.6.0
scikit-learn
scikit-learn
mplfinance

File diff suppressed because it is too large Load Diff

Binary file not shown.

Before

Width:  |  Height:  |  Size: 60 KiB

After

Width:  |  Height:  |  Size: 170 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 86 KiB