Skip to main content

Reinforcement Learning Environments for train RL agents

Project description

TEG

TEG is a straightforward environment for Reinforcement Learning that enables the training of RL agents for a robot manipulator. It's based on the Gymnasium and Mujoco.

Installation

This project use python 3.7+

You can install it by using pip

pip install TEG

Or manually cloning the github repository

git clone https://github.com/Alexfm101/TEG.git 
cd TEG
python -m pip install -e .

Example

TEG environment are simple Python env classes to allow an AI agent to interact with them very simple. Here's an example:

from TEG.envs.UR5_v0 import UR5Env_v0

env = UR5Env_v0(simulation_frames=5, torque_control= 0.01, distance_threshold=0.05)

def main():
    for episode in range(5):
        print("episode {}".format(episode))
        env.reset()

        for t in range(1000):
            action = env.action_space.sample()
            observation, reward, done, info = env.step(action)
            
            
            if done:
                print("Episode finished after {} timesteps".format(t+1))
                break

    return env.robot, env.sim

if __name__ == '__main__':
    main()

🧾 License

The Apache 2.0 License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

TEG-1.0.0rc1.tar.gz (8.9 kB view hashes)

Uploaded Source

Built Distribution

TEG-1.0.0rc1-py3-none-any.whl (9.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page