Skip to content

Commit

Permalink
Merge pull request #3 from sisl/road_extension
Browse files Browse the repository at this point in the history
Merge branch road_extension into master
- Made this package compatible with `AutomotiveSimulator.jl` (successor to AutomotiveDrivingModels.jl) and `AutomotiveVisualization.jl` (successor to AutoViz.jl)
- Provides extended roadways to enable model driven vehicles to not reverse due to road ending
- Visualize such that lane boundaries for merge lanes are sensible. Specialized wrapper called `MergingRoadway` around roadway object with dedicated `add_renderable!`
- Cooperative IDM driver model
- Vehicle track reading uses only `Vector{Scenes}` rather than legacy code from `Records.jl` such as `ListRecord`
  • Loading branch information
raunakbh92 committed Apr 2, 2020
2 parents 0d196eb + 4314c38 commit 82c5d55
Show file tree
Hide file tree
Showing 18 changed files with 1,288 additions and 167 deletions.
6 changes: 2 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,7 @@ os:
- linux

julia:
- 1.0
- 1.1
- nightly
- 1

addons:
apt: # apt-get for linux
Expand All @@ -28,7 +26,7 @@ after_success:
jobs:
include:
- stage: "Documentation"
julia: 1.0
julia: 1
os: linux
script:
- git clone https://github.com/JuliaRegistries/General $(julia -e 'import Pkg; println(joinpath(Pkg.depots1(), "registries", "General"))')
Expand Down
8 changes: 5 additions & 3 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@ repo = "https://github.com/sisl/AutomotiveInteraction.jl.git"
version = "0.1.0"

[deps]
AutoViz = "82aa6e0c-a491-5edf-8d4b-c16b98e4ea17"
AutomotiveDrivingModels = "99497e54-f3d6-53d3-a3a9-fa9315a7f1ba"
AutomotiveSimulator = "6aa42d20-6c96-11ea-1103-339224409280"
AutomotiveVisualization = "0faf7fd0-6c98-11ea-1740-03605baa3b07"
DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0"
DelimitedFiles = "8bb1440f-4735-579b-a4ab-409b98df4dab"
Records = "5984c134-fa48-5ed5-a57f-fc2f6936871f"
Parameters = "d96e819e-fc66-5662-9728-84c9c7592b0a"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
Reel = "71555da5-176e-5e73-a222-aebc6c6e4f2f"
Revise = "295af30f-e4ad-537b-8983-00126c2a3abe"

[extras]
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@
Driver modeling using the [Interaction](https://interaction-dataset.com/) driving dataset

## Trajectory replay
Here is a video showing replay trajectories for the first 100 timesteps ![](docs/replay.gif)
Here is a video showing replay trajectories for the first 100 timesteps ![](docs/replay.gif)
19 changes: 12 additions & 7 deletions docs/src/driving_simulation.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
# Driving Simulation
```@docs
keep_vehicle_subset!
place_vehs_on_straight_road
place_vehs_on_separated_segments_road
make_def_models
make_TimLaneChanger_models
get_hallucination_scenes
run_vehicles
keep_vehicle_subset!,
make_def_models,
make_IDM_models,
make_cidm_models,
make_iidm_models,
make_TimLaneChanger_models,
get_hallucination_scenes,
run_vehicles,
compare2truth,
run_vehicles_curvept_overlay,
test_barrier_vehicle,
test_jumpy_vehicle
```
2 changes: 2 additions & 0 deletions docs/src/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,7 @@ This is the documentation for AutomotiveInteraction.jl.
Pages = [
"roadway_building.md",
"driving_simulation.md",
"visualization.md",
"veh_track_reading.md"
]
```
19 changes: 12 additions & 7 deletions docs/src/roadway_building.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,16 @@
# Roadway Building

```@docs
append_to_curve!
get_new_angle
bound_heading
append_headings
centerlines_txt2tracks
make_roadway_interaction
make_ngsim_roadway
append_to_curve!,
get_new_angle,
bound_heading,
append_headings,
centerlines_txt2tracks,
make_roadway_interaction,
make_roadway_ngsim,
make_roadway_interaction_with_extensions,
make_discont_roadway_straight,
make_discont_roadway_jagged,
MergingRoadway,
add_renderable!
```
7 changes: 7 additions & 0 deletions docs/src/veh_track_reading.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# Vehicle Track Reading
```@docs
INTERACTIONTrajdata,
carsinframe,
car_df_index,
read_veh_tracks
```
9 changes: 9 additions & 0 deletions docs/src/visualization.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Visualization
```@docs
video_trajdata_replay,
scenelist2video,
video_overlay_scenelists,
curvepts_overlay,
LaneOverlay,
scenelist2video_curvepts
```
69 changes: 58 additions & 11 deletions src/AutomotiveInteraction.jl
Original file line number Diff line number Diff line change
@@ -1,29 +1,76 @@
# This is a placeholder file which will later contain all exported functions and included .jl files

# This is the module file. It allows communication between different files within the src folder
# Also, determines which functions are provided by AutomotiveInteraction whenever someone says
# using AutomotiveInteraction
module AutomotiveInteraction

using AutomotiveDrivingModels
using AutoViz
using AutomotiveSimulator
using AutomotiveVisualization
using Reel

using DataFrames
using Records
using DelimitedFiles
using Parameters
using Random # For AbstractRNG in Base.rand for c-idm

export keep_vehicle_subset!,
export
keep_vehicle_subset!,
make_def_models,
make_IDM_models,
make_cidm_models,
make_iidm_models,
make_TimLaneChanger_models,
get_hallucination_scenes,
run_vehicles
run_vehicles,
compare2truth,
run_vehicles_curvept_overlay,
test_barrier_vehicle,
test_jumpy_vehicle
include("driving_simulation.jl")


export append_to_curve!,
export
append_to_curve!,
get_new_angle,
bound_heading,
append_headings,
centerlines_txt2tracks,
make_roadway_interaction,
make_roadway_ngsim
make_roadway_ngsim,
make_roadway_interaction_with_extensions,
make_discont_roadway_straight,
make_discont_roadway_jagged,
MergingRoadway,
add_renderable!
include("roadway_building.jl")

export
INTERACTIONTrajdata,
carsinframe,
car_df_index,
read_veh_tracks
include("veh_track_reading.jl")

export
video_trajdata_replay,
scenelist2video,
video_overlay_scenelists,
curvepts_overlay,
LaneOverlay,
scenelist2video_curvepts
include("visualization.jl")

export
MergingEnvironment,
main_lane,
merge_lane
include("environment.jl")

export
CooperativeIDM,
find_merge_vehicle
include("cooperative_IDM.jl")

export
MergeOverlay
include("overlays.jl")

end
end # End module
Loading

0 comments on commit 82c5d55

Please sign in to comment.