Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
OUTDATED Verse-library
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
AutonomyCourse_ECEIllinois
OUTDATED Verse-library
Commits
ec158735
Commit
ec158735
authored
2 years ago
by
sayanmitracode
Browse files
Options
Downloads
Patches
Plain Diff
cleaned up version of ball bounce
parent
075fa18a
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
demo/ball_bounces.py
+9
-1
9 additions, 1 deletion
demo/ball_bounces.py
with
9 additions
and
1 deletion
demo/ball_bounces.py
+
9
−
1
View file @
ec158735
...
...
@@ -64,8 +64,16 @@ from dryvr_plus_plus.example.example_sensor.fake_sensor import FakeSensor4
from
dryvr_plus_plus.scene_verifier.sensor.base_sensor
import
BaseSensor
if
__name__
==
"
__main__
"
:
ball_controller
=
'
./ball_bounces.py
'
'''
Defining and using a scenario involves the following 5 easy steps:
1. creating a basic scenario object with Scenario()
2. defining the agents that will populate the object, here we have two ball agents
3. adding the agents to the scenario using .add_agent()
4. initializing the agents for this scenario.
Note that agents are only initialized *in* a scenario, not individually outside a scenario
5. genetating the simulation traces or computing the reachable states
'''
bouncingBall
=
Scenario
()
ball_controller
=
'
./ball_bounces.py
'
myball1
=
BallAgent
(
'
red-ball
'
,
file_name
=
ball_controller
)
myball2
=
BallAgent
(
'
green-ball
'
,
file_name
=
ball_controller
)
bouncingBall
.
add_agent
(
myball1
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment