This repository contains a full **Reinforcement Learning ** control system for trajectory-tracking quadcopters.
The environment is built on gym-pybullet-drones, with a custom modified RL environment that teaches a Crazyflie-style drone to fly:
- โ Circles
- โ Figure-8 paths
- โ Four-point patterns
- โ โGo-Toโ single-point moves
train python .\scripts\trainer.py # make sure you set a task to train [circle, four_points, figure8,goto]
test src/testing/tester.py The environment supports:
- Single-task RL (train only
circle, onlyfour_points, etc.) - Sequential training (train circle โ load model โ train figure8 โ โฆ)
Each task has its own set of waypoints and reward shaping.
Each trajectory is expressed as a list of waypoints:
The agent receives:
- Current position
- Velocity
- Orientation
- Angular velocity
- Relative vector to current waypoint
A live matplotlib window shows:
- Rolling mean episode reward
- Training stability
- Improvements over time
