# **Deep Q-Learning** Agent playing **CartPole-v1**
This is a trained model of a **Deep Q-Learning** agent playing **CartPole-v1**.

## Usage

```python
from huggingface_hub import hf_hub_download
import torch
from dqn_model import DQN

model_path = hf_hub_download(repo_id="figurek1m/dqn-cartpole", filename="dqn_cartpole.pth")
q_network = DQN(input_dim=4, output_dim=2)
q_network.load_state_dict(torch.load(model_path))
q_network.eval()

env = gym.make("CartPole-v1")
```
Downloads last month

-

Downloads are not tracked for this model. How to track
Video Preview
loading

Evaluation results