scenariogeneration


Namescenariogeneration JSON
Version 0.14.9 PyPI version JSON
download
home_pagehttps://github.com/pyoscx/scenariogeneration
SummaryGeneration of OpenSCENARIO and OpenDRIVE xml files
upload_time2024-12-04 13:41:44
maintainerNone
docs_urlNone
authorMikael Andersson, Irene Natale, Andreas Tingberg
requires_python>=3.6
licenseMPL-2.0
keywords opendrive openscenario xml
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            ![Python](https://github.com/pyoscx/scenariogeneration/actions/workflows/python.yml/badge.svg?branch=main)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)

# scenariogeneration

The Python scenariogeneration package is a collection of libraries for generating OpenSCENARIO (.xosc) and OpenDRIVE (.xodr) XML files.

This combined package (which includes the former pyoscx, pyodrx) can be used to jointly generate OpenSCENARIO based scenarios with interlinked OpenDRIVE based road network maps. Nevertheless, it is still possible to separately generate OpenSCENARIO or OpenDRIVE files by using only a subset of the provided functionality.

The package consists of the __scenario_generator__ module and two Python subpackages, __xosc__ (OpenSCENARIO) and __xodr__ (OpenDRIVE), together with some support functionality for auto generation with parametrization as well as easy viewing with [esmini](https://github.com/esmini/esmini).

The user documentation can be found [here](https://pyoscx.github.io/), the API documentation [here](https://pyoscx.github.io/scenariogeneration/index.html) and the change log in [release_notes.md](https://github.com/pyoscx/scenariogeneration/blob/main/release_notes.md)

Please note that this is not an official implementation of either OpenSCENARIO or OpenDRIVE.

## Coverage

As of V0.11.0, the coverage of the modules varies:
- The xosc module has full coverage of OpenSCENARIO V1.0.0, and most of V1.1.0 and V1.2.0, if something is missing please raise an issue or make a pull request.
- The xodr module has coverage of basic roads, junctions, signals, and objects, based on OpenDrive (V 1.7.1).

For more details se xodr_coverage.txt and xosc_missing_features.txt

## Getting Started

```
pip install scenariogeneration
```
then run any of the examples provided

### Prerequisites

Been tested with Python >3.6.9.
With Python versions <3.7 the order of certain xml-elements might not be the same between generations.

### Installing

```
pip install scenariogeneration
```

## Usage

Please see the user guide for more information: https://pyoscx.github.io/

### Running with esmini

Esmini can be used to visualize the generated scenarios. Visit https://github.com/esmini/esmini and follow the "Binaries and demos" section.
Your scenarios can be visualized directly by making use of *esmini* in the following way:

```
from scenariogeneration import esmini

def Scenario(ScenarioGenerator): ...


if __name__ == "__main__":
    s = Scenario()

    esmini(s,esminipath ='path to esmini', index_to_run = 'first')
```
where *index_to_run* can be 'first', 'random', 'middle' or an integer, and esmini will run that scenario/road for you.

## Related work

### esmini

[esmini](https://github.com/esmini/esmini) is a basic OpenSCENARIO player

### clothoids

[pyclothoids](https://github.com/phillipd94/pyclothoids), used for construction and optimization of clothoids geometries

### blender implementation

[blender + scenariogeneration](https://github.com/johschmitz/blender-driving-scenario-creator)

## Authors

See [AUTHORS](https://github.com/pyoscx/scenariogeneration/blob/main/AUTHORS) file

## Data formats

The wrappers is based on the OpenSCENARIO and OpenDRIVE standards.

[OpenDRIVE](https://www.asam.net/standards/detail/opendrive/)

describes the static content of a scenario, like the road, lanes, signs and so on.

[OpenSCENARIO](https://www.asam.net/standards/detail/openscenario/)

describes the dynamic content on top of a road network, e.g. traffic maneuvers, weather conditions, and so on.
            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/pyoscx/scenariogeneration",
    "name": "scenariogeneration",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.6",
    "maintainer_email": null,
    "keywords": "OpenDRIVE, OpenSCENARIO, xml",
    "author": "Mikael Andersson, Irene Natale, Andreas Tingberg",
    "author_email": "andmika@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/d7/98/8501a4cd4dfee4fe8dff9f9c61579cc05c0376e383604270a35f93c583eb/scenariogeneration-0.14.9.tar.gz",
    "platform": null,
    "description": "![Python](https://github.com/pyoscx/scenariogeneration/actions/workflows/python.yml/badge.svg?branch=main)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n\n# scenariogeneration\n\nThe Python scenariogeneration package is a collection of libraries for generating OpenSCENARIO (.xosc) and OpenDRIVE (.xodr) XML files.\n\nThis combined package (which includes the former pyoscx, pyodrx) can be used to jointly generate OpenSCENARIO based scenarios with interlinked OpenDRIVE based road network maps. Nevertheless, it is still possible to separately generate OpenSCENARIO or OpenDRIVE files by using only a subset of the provided functionality.\n\nThe package consists of the __scenario_generator__ module and two Python subpackages, __xosc__ (OpenSCENARIO) and __xodr__ (OpenDRIVE), together with some support functionality for auto generation with parametrization as well as easy viewing with [esmini](https://github.com/esmini/esmini).\n\nThe user documentation can be found [here](https://pyoscx.github.io/), the API documentation [here](https://pyoscx.github.io/scenariogeneration/index.html) and the change log in [release_notes.md](https://github.com/pyoscx/scenariogeneration/blob/main/release_notes.md)\n\nPlease note that this is not an official implementation of either OpenSCENARIO or OpenDRIVE.\n\n## Coverage\n\nAs of V0.11.0, the coverage of the modules varies:\n- The xosc module has full coverage of OpenSCENARIO V1.0.0, and most of V1.1.0 and V1.2.0, if something is missing please raise an issue or make a pull request.\n- The xodr module has coverage of basic roads, junctions, signals, and objects, based on OpenDrive (V 1.7.1).\n\nFor more details se xodr_coverage.txt and xosc_missing_features.txt\n\n## Getting Started\n\n```\npip install scenariogeneration\n```\nthen run any of the examples provided\n\n### Prerequisites\n\nBeen tested with Python >3.6.9.\nWith Python versions <3.7 the order of certain xml-elements might not be the same between generations.\n\n### Installing\n\n```\npip install scenariogeneration\n```\n\n## Usage\n\nPlease see the user guide for more information: https://pyoscx.github.io/\n\n### Running with esmini\n\nEsmini can be used to visualize the generated scenarios. Visit https://github.com/esmini/esmini and follow the \"Binaries and demos\" section.\nYour scenarios can be visualized directly by making use of *esmini* in the following way:\n\n```\nfrom scenariogeneration import esmini\n\ndef Scenario(ScenarioGenerator): ...\n\n\nif __name__ == \"__main__\":\n    s = Scenario()\n\n    esmini(s,esminipath ='path to esmini', index_to_run = 'first')\n```\nwhere *index_to_run* can be 'first', 'random', 'middle' or an integer, and esmini will run that scenario/road for you.\n\n## Related work\n\n### esmini\n\n[esmini](https://github.com/esmini/esmini) is a basic OpenSCENARIO player\n\n### clothoids\n\n[pyclothoids](https://github.com/phillipd94/pyclothoids), used for construction and optimization of clothoids geometries\n\n### blender implementation\n\n[blender + scenariogeneration](https://github.com/johschmitz/blender-driving-scenario-creator)\n\n## Authors\n\nSee [AUTHORS](https://github.com/pyoscx/scenariogeneration/blob/main/AUTHORS) file\n\n## Data formats\n\nThe wrappers is based on the OpenSCENARIO and OpenDRIVE standards.\n\n[OpenDRIVE](https://www.asam.net/standards/detail/opendrive/)\n\ndescribes the static content of a scenario, like the road, lanes, signs and so on.\n\n[OpenSCENARIO](https://www.asam.net/standards/detail/openscenario/)\n\ndescribes the dynamic content on top of a road network, e.g. traffic maneuvers, weather conditions, and so on.",
    "bugtrack_url": null,
    "license": "MPL-2.0",
    "summary": "Generation of OpenSCENARIO and OpenDRIVE xml files",
    "version": "0.14.9",
    "project_urls": {
        "Download": "https://github.com/pyoscx/scenariogeneration/archive/v0.14.9.tar.gz",
        "Homepage": "https://github.com/pyoscx/scenariogeneration"
    },
    "split_keywords": [
        "opendrive",
        " openscenario",
        " xml"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d7988501a4cd4dfee4fe8dff9f9c61579cc05c0376e383604270a35f93c583eb",
                "md5": "9036486330c84ae1f716f34347a1229e",
                "sha256": "fa6ad743cafea7b487dee6257abd9dc17182fd5c4e64ae2f30653e37d2d54e8f"
            },
            "downloads": -1,
            "filename": "scenariogeneration-0.14.9.tar.gz",
            "has_sig": false,
            "md5_digest": "9036486330c84ae1f716f34347a1229e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6",
            "size": 205274,
            "upload_time": "2024-12-04T13:41:44",
            "upload_time_iso_8601": "2024-12-04T13:41:44.357053Z",
            "url": "https://files.pythonhosted.org/packages/d7/98/8501a4cd4dfee4fe8dff9f9c61579cc05c0376e383604270a35f93c583eb/scenariogeneration-0.14.9.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-12-04 13:41:44",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "pyoscx",
    "github_project": "scenariogeneration",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "scenariogeneration"
}
        
Elapsed time: 0.39282s