Skip to main content

A tool package for Onsite

Project description

Project description

Onsite is a tool package for Onsite.

Update

  • Version 0.1.3

    Remove the 0 limitation for velocity.

  • Version 0.1.2

    Add feature: Plot.

  • Version 0.1.1

    Bug fixing.

  • Version 0.1.0

    Add feature: Automatically output test results into output dir.

Installation

To get started, you'll need to have Python 3.6+ installed. Simply install onsite using pip:

pip install onsite

And you’re good to go!

Usage

The usage of this library refered to the well-known reinforcement learning library OpenAI Gym.

A simple example:

# make env from scenario (OpenScenario XML)
env,observation = onsite.env.make(scenario,output_dir)
while True:
    # planning based on observation
    action = planner.act(observation)
    # obtain new observations from env
    observation,reward,done,info = env.step(action)
    # stop simulation if done
    if done:
        break

This is just an implementation of the classic “agent-environment loop”. Each timestep, the agent chooses an action, and the environment returns an observation and a reward.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

onsite-0.1.3-py3-none-any.whl (6.5 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