Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 

Repository files navigation

DQN With PyTorch (CartPole)

Single-file PyTorch DQN example with training and evaluation on CartPole.

Run

  1. Install dependencies:

    • pip install torch gymnasium numpy
  2. Train and evaluate:

    • python "Neural Network by Pytorch.py"

Output

  • Trains for 300 episodes by default.
  • Saves model to dqn_cartpole.pt.
  • Prints a final summary with rewards, loss, and eval score.

About

Lets build Neural Network using by Pytorh...

Resources

Stars

4 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages