---
title: オープンソース自動運転シミュレーター「AWSIM」のご紹介と実装事例
tags:  #unity #unitysync  
author: [Unity Technologies Japan](https://www.docswell.com/user/UnityJapan)
site: [Docswell](https://www.docswell.com/)
thumbnail: https://bcdn.docswell.com/page/5JGGLNZWJL.jpg?width=480
description: 弊社ではオープンソース自動運転OSのAutowareを開発しており、世界20ヵ国・500以上の企業、団体で使用されています。自動運転の開発において、シミュレーターはコストやリスクの面から非常に重要です。この度は弊社で開発したオープンソース自動運転シミュレーター「AWSIM」の実装事例をご紹介させていただきます。  こんな人におすすめ: ・自動運転に興味がある方 ・Unityをデジタルツインに利用したい方 ・機械学習データ生成やHILS等、Unityの様々なユースケースを知りたい方  受講者が得られる知見: ・自動運転シミュレーターに求められる技術 ・車両/LiDAR Sensor/ROS2/地図・交通等の実装事例 ・Unity Sensor SDKの活用事例  出演: 牧野 鷹秋 (株式会社ティアフォー)  -- 初出: SYNC 2022 #UnitySYNC https://events.unity3d.jp/sync/
published: October 25, 22
canonical: https://www.docswell.com/s/UnityJapan/K2V61K-sync2022_day1_track1_1335
---
# Page. 1

![Page Image](https://bcdn.docswell.com/page/5JGGLNZWJL.jpg)



# Page. 2

![Page Image](https://bcdn.docswell.com/page/47QXYQLQJP.jpg)

•
•
•
•
•


# Page. 3

![Page Image](https://bcdn.docswell.com/page/KE46WNDYJ1.jpg)

•
•
https://tier4.jp/
•
•
•
•
•
東京大学 大学院情報理工学系研究科 准教授、名古屋
大学未来社会創造機構客員准教授、株式会社ティア
フォー 創業者兼CTO、The Autoware Foundation 代表
理事。博士(工学)。
2004年慶応義塾大学理工学部情報工学科卒業、2008
年同大学院理工学研究科 開放環境科学専攻 後期博士
課程修了。カーネギーメロン大学、カリフォルニア
大学の研究員、名古屋大学大学院 情報科学研究科 准
教授を経て、現職。
専門はオぺレーティングシステム、組込みリアルタ
イムシステム、並列分散システム。


# Page. 4

![Page Image](https://bcdn.docswell.com/page/L71VY5ZNJG.jpg)

•
•
•
•
•


# Page. 5

![Page Image](https://bcdn.docswell.com/page/G7WLG56MJ2.jpg)



# Page. 6

![Page Image](https://bcdn.docswell.com/page/4JZMLNYM73.jpg)

•
•
•
•
•
•
•
•
•


# Page. 7

![Page Image](https://bcdn.docswell.com/page/YE6NW8D5EV.jpg)

60+
MEMBERS
•
•


# Page. 8

![Page Image](https://bcdn.docswell.com/page/GE55M93GE4.jpg)

20+
COUNTRIES
500+
COMPANIES


# Page. 9

![Page Image](https://bcdn.docswell.com/page/972N92ZDJR.jpg)

30+
Vehicles


# Page. 10

![Page Image](https://bcdn.docswell.com/page/DJYP4YRMJM.jpg)

•
•
•
•
•
•
•
•
•
ROS2 Documentation: Understanding topics
https://docs.ros.org/en/galactic/Tutorials/Beginner-CLITools/Understanding-ROS2-Topics/Understanding-ROS2-Topics.html


# Page. 11

![Page Image](https://bcdn.docswell.com/page/V7N5YPD3E8.jpg)

① Sensorデータを取得
② 各モジュールを通して
制御入力値を算出
③ ステア、アクセルなど
を入力して車両制御


# Page. 12

![Page Image](https://bcdn.docswell.com/page/YJ9YP3GP73.jpg)

① Sensorデータを取得
② 各モジュールを通して
制御入力値を算出
③ ステア、アクセルなど
を入力して車両制御


# Page. 13

![Page Image](https://bcdn.docswell.com/page/GJ86DMVXED.jpg)

① Sensorデータを取得
② 各モジュールを通して
制御入力値を算出
③ ステア、アクセルなど
を入力して車両制御


# Page. 14

![Page Image](https://bcdn.docswell.com/page/LJL9M35N7R.jpg)

① Sensorデータを取得
② 各モジュールを通して
制御入力値を算出
③ ステア、アクセルなど
を入力して車両制御


# Page. 15

![Page Image](https://bcdn.docswell.com/page/47MZYD3QJW.jpg)



# Page. 16

![Page Image](https://bcdn.docswell.com/page/P7R694QKE9.jpg)



# Page. 17

![Page Image](https://bcdn.docswell.com/page/PJXMQ255EX.jpg)

NDT Scan
Matching


# Page. 18

![Page Image](https://bcdn.docswell.com/page/3JKG9M6R7D.jpg)



# Page. 19

![Page Image](https://bcdn.docswell.com/page/LE3NWY6GE5.jpg)

•
•
•
•
•
•


# Page. 20

![Page Image](https://bcdn.docswell.com/page/8EDWK5VN7G.jpg)

Clock
Sensor Data
ROS2
Control Input


# Page. 21

![Page Image](https://bcdn.docswell.com/page/V7P9KGVNJ8.jpg)



# Page. 22

![Page Image](https://bcdn.docswell.com/page/2JVMV6ZYJQ.jpg)

実機に代わり、AWSIMで
シミュレーション


# Page. 23

![Page Image](https://bcdn.docswell.com/page/5EGGLN4WEL.jpg)

•
•


# Page. 24

![Page Image](https://bcdn.docswell.com/page/4JQXYQGQEP.jpg)



# Page. 25

![Page Image](https://bcdn.docswell.com/page/K746WN5YE1.jpg)



# Page. 26

![Page Image](https://bcdn.docswell.com/page/LJ1VY5WNEG.jpg)

•
•
•


# Page. 27

![Page Image](https://bcdn.docswell.com/page/GJWLG5RME2.jpg)

Autoware
起動
AWSIM
起動
車両初期
位置
自己位置
推定
自己位置
推定
目的地
セット
自動走行
開始
自動走行
目的地
到達
自動走行
目的地
到達


# Page. 28

![Page Image](https://bcdn.docswell.com/page/4EZMLNRMJ3.jpg)

•
•
•


# Page. 29

![Page Image](https://bcdn.docswell.com/page/Y76NW8R57V.jpg)

•
•
•


# Page. 30

![Page Image](https://bcdn.docswell.com/page/G755M98G74.jpg)

ROSBAG
Datasets
Annotation
Service
Evaluation
Service
Build
PreProcess
Train
Model
Service
Eval


# Page. 31

![Page Image](https://bcdn.docswell.com/page/9J2N92KDER.jpg)

ROSBAG
Datasets
① 機械学習で使
用するログを
Annotation Service
に登録
② 学習時に登録
済みAnnotation
データを読み込
む
Evaluation
Service
Model
Service
Annotation
Service
Build
PreProcess
Train
Eval
③ 学習後のモデ
ルを管理する
Model Serviceに
データを格納


# Page. 32

![Page Image](https://bcdn.docswell.com/page/DEYP4YNMEM.jpg)

ROSBAG
Datasets
① 機械学習で使
用するログを
Annotation Service
に登録
② 学習時に登録
済みAnnotation
データを読み込
む
Evaluation
Service
Model
Service
Annotation
Service
Build
PreProcess
Train
Eval
③ 学習後のモデ
ルを管理する
Model Serviceに
データを格納


# Page. 33

![Page Image](https://bcdn.docswell.com/page/VJN5YPX378.jpg)

ROSBAG
Datasets
① 機械学習で使
用するログを
Annotation Service
に登録
② 学習時に登録
済みAnnotation
データを読み込
む
Evaluation
Service
Model
Service
Annotation
Service
Build
PreProcess
Train
Eval
③ 学習後のモデ
ルを管理する
Model Serviceに
データを格納


# Page. 34

![Page Image](https://bcdn.docswell.com/page/YE9YP38PJ3.jpg)

ROSBAG
Datasets
① 機械学習で使
用するログを
Annotation Service
に登録
② 学習時に登録
済みAnnotation
データを読み込
む
Evaluation
Service
Model
Service
Annotation
Service
Build
PreProcess
Train
Eval
③ 学習後のモデ
ルを管理する
Model Serviceに
データを格納


# Page. 35

![Page Image](https://bcdn.docswell.com/page/GE86DM8X7D.jpg)



# Page. 36

![Page Image](https://bcdn.docswell.com/page/LEL9M3RNJR.jpg)



# Page. 37

![Page Image](https://bcdn.docswell.com/page/4JMZYDRQEW.jpg)



# Page. 38

![Page Image](https://bcdn.docswell.com/page/PJR694RK79.jpg)

•
•
•
•
•


# Page. 39

![Page Image](https://bcdn.docswell.com/page/PEXMQ2R57X.jpg)

•
•
•


# Page. 40

![Page Image](https://bcdn.docswell.com/page/3EKG9MRRJD.jpg)

•
•
•
WheelColliderのタイヤ摩擦係数を0にすること
で、独自のタイヤモデルを適用できる


# Page. 41

![Page Image](https://bcdn.docswell.com/page/L73NWY8G75.jpg)

•
•
•
WheelColliderのタイヤ摩擦係数を0にすること
で、独自のタイヤモデルを適用できる


# Page. 42

![Page Image](https://bcdn.docswell.com/page/87DWK5MNJG.jpg)

𝒚 = 𝑫 𝒔𝒊𝒏[𝑪 𝒂𝒓𝒄𝒕𝒂𝒏 𝑩𝒙 − 𝑬 𝑩𝒙 − 𝒂𝒓𝒄𝒕𝒂𝒏 𝑩𝒙 ]


# Page. 43

![Page Image](https://bcdn.docswell.com/page/2EVMV6RYEQ.jpg)



# Page. 44

![Page Image](https://bcdn.docswell.com/page/57GGLNMW7L.jpg)



# Page. 45

![Page Image](https://bcdn.docswell.com/page/4EQXYQRQ7P.jpg)

•
•
•
•
•
•
•


# Page. 46

![Page Image](https://bcdn.docswell.com/page/KJ46WN8Y71.jpg)



# Page. 47

![Page Image](https://bcdn.docswell.com/page/LE1VY52N7G.jpg)

① LiDAR情報とメッシュ
をUnity → RGLに転送
② ノイズ適用、
レイトレ点群作成、
データ整形
③ 点群データを
RGL → Unityに転送
VisualizeとPublish ROS2


# Page. 48

![Page Image](https://bcdn.docswell.com/page/GEWLG52M72.jpg)

① LiDAR情報とメッシュ
をUnity → RGLに転送
② ノイズ適用、
レイトレ点群作成、
データ整形
③ 点群データを
RGL → Unityに転送
VisualizeとPublish ROS2


# Page. 49

![Page Image](https://bcdn.docswell.com/page/47ZMLNDME3.jpg)

① LiDAR情報とメッシュ
をUnity → RGLに転送
② ノイズ適用、
レイトレ点群作成、
データ整形
③ 点群データを
RGL → Unityに転送
VisualizeとPublish ROS2


# Page. 50

![Page Image](https://bcdn.docswell.com/page/YJ6NW815JV.jpg)

① LiDAR情報とメッシュ
をUnity → RGLに転送
② ノイズ適用、
レイトレ点群作成、
データ整形
③ 点群データを
RGL → Unityに転送
VisualizeとPublish ROS2


# Page. 51

![Page Image](https://bcdn.docswell.com/page/GJ55M94GJ4.jpg)

•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•


# Page. 52

![Page Image](https://bcdn.docswell.com/page/LE3NWYGPE5.jpg)

•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•


# Page. 53

![Page Image](https://bcdn.docswell.com/page/8EDWK5137G.jpg)

•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•


# Page. 54

![Page Image](https://bcdn.docswell.com/page/V7P9KGQPJ8.jpg)

•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•


# Page. 55

![Page Image](https://bcdn.docswell.com/page/2JVMV65VJQ.jpg)

•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•


# Page. 56

![Page Image](https://bcdn.docswell.com/page/5EGGLN61EL.jpg)

TIER IVではレイトレLiDARを使用
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•
•


# Page. 57

![Page Image](https://bcdn.docswell.com/page/4JQXYQ4NEP.jpg)

•
•
•
•
•


# Page. 58

![Page Image](https://bcdn.docswell.com/page/K746WNQ3E1.jpg)

𝐼𝑛𝑡𝑟𝑖𝑠𝑖𝑐 𝑝𝑎𝑟𝑎𝑚𝑒𝑡𝑒𝑟𝑠 = (𝑓𝑥 𝑓𝑦 𝑐𝑥 𝑐𝑦 )
•
•
•
𝐷𝑖𝑠𝑡𝑜𝑟𝑡𝑖𝑜𝑛 𝑐𝑜𝑒𝑓𝑓𝑖𝑐𝑖𝑒𝑛𝑡𝑠 = (𝑘1 𝑘2 𝑝1 𝑝2 𝑘3 )
•
•
•


# Page. 59

![Page Image](https://bcdn.docswell.com/page/LJ1VY5PZEG.jpg)



# Page. 60

![Page Image](https://bcdn.docswell.com/page/GJWLG526E2.jpg)



# Page. 61

![Page Image](https://bcdn.docswell.com/page/4EZMLNDRJ3.jpg)



# Page. 62

![Page Image](https://bcdn.docswell.com/page/Y76NW8117V.jpg)



# Page. 63

![Page Image](https://bcdn.docswell.com/page/G755M94L74.jpg)



# Page. 64

![Page Image](https://bcdn.docswell.com/page/9J2N92V3ER.jpg)

•
•
•


# Page. 65

![Page Image](https://bcdn.docswell.com/page/DEYP4Y38EM.jpg)

•
•
•
•


# Page. 66

![Page Image](https://bcdn.docswell.com/page/VJN5YPV978.jpg)

•
•
•
•
MGRS座標系で原点オフセット


# Page. 67

![Page Image](https://bcdn.docswell.com/page/YE9YP363J3.jpg)

•
•
•


# Page. 68

![Page Image](https://bcdn.docswell.com/page/GE86DMZL7D.jpg)

•
•
•
•
•
•


# Page. 69

![Page Image](https://bcdn.docswell.com/page/LEL9M3DQJR.jpg)

3Dモデルから点群を作成


# Page. 70

![Page Image](https://bcdn.docswell.com/page/4JMZYDWKEW.jpg)



# Page. 71

![Page Image](https://bcdn.docswell.com/page/PJR694Y679.jpg)

•
•
•
•
•
•
•


# Page. 72

![Page Image](https://bcdn.docswell.com/page/PEXMQ2GD7X.jpg)

*.OSMのParserを通して
AWSIMにwaypointを作成


# Page. 73

![Page Image](https://bcdn.docswell.com/page/3EKG9M4DJD.jpg)

•
•
•


# Page. 74

![Page Image](https://bcdn.docswell.com/page/L73NWYLP75.jpg)

•
•
•
•
•
•
•


# Page. 75

![Page Image](https://bcdn.docswell.com/page/87DWK5N3JG.jpg)

ros-sharp
通信方式
ROS-TCP-Connector
ros2-for-unity
Ros bridge
独自TCPプロトコル
ROS2 native
C#/Msg Generator
C#/Msg Generator
Msg Generator
ライセンス
Apache 2.0
Apache 2.0
Apache 2.0
ROS1/ROS2
ROS1
ROS1/ROS2
ROS2
siemens
Unity technologies
Robotec.AI
https://github.com/siemens/ros-sharp
https://github.com/UnityTechnologies/ROS-TCP-Connector
https://github.com/RobotecAI/ros2-forunity
カスタムメッセージの追加
開発元
URL


# Page. 76

![Page Image](https://bcdn.docswell.com/page/VJP9KG5PE8.jpg)

ros-sharp
通信方式
ROS-TCP-Connector
ros2-for-unity
Ros bridge
独自TCPプロトコル
ROS2 native
C#/Msg Generator
C#/Msg Generator
Msg Generator
ライセンス
Apache 2.0
Apache 2.0
Apache 2.0
ROS1/ROS2
ROS1
ROS1/ROS2
ROS2
siemens
Unity technologies
Robotec.AI
https://github.com/siemens/ros-sharp
https://github.com/UnityTechnologies/ROS-TCP-Connector
https://github.com/RobotecAI/ros2-forunity
カスタムメッセージの追加
開発元
URL


# Page. 77

![Page Image](https://bcdn.docswell.com/page/2EVMV6PVEQ.jpg)

ros-sharp
通信方式
ROS-TCP-Connector
ros2-for-unity
Ros bridge
独自TCPプロトコル
ROS2 native
C#/Msg Generator
C#/Msg Generator
Msg Generator
ライセンス
Apache 2.0
Apache 2.0
Apache 2.0
ROS1/ROS2
ROS1
ROS1/ROS2
ROS2
siemens
Unity technologies
Robotec.AI
https://github.com/siemens/ros-sharp
https://github.com/UnityTechnologies/ROS-TCP-Connector
https://github.com/RobotecAI/ros2-forunity
カスタムメッセージの追加
開発元
URL


# Page. 78

![Page Image](https://bcdn.docswell.com/page/57GGLNP17L.jpg)

AWSIMで使用
ros-sharp
通信方式
ROS-TCP-Connector
ros2-for-unity
Ros bridge
独自TCPプロトコル
ROS2 native
C#/Msg Generator
C#/Msg Generator
Msg Generator
ライセンス
Apache 2.0
Apache 2.0
Apache 2.0
ROS1/ROS2
ROS1
ROS1/ROS2
ROS2
siemens
Unity technologies
Robotec.AI
https://github.com/siemens/ros-sharp
https://github.com/UnityTechnologies/ROS-TCP-Connector
https://github.com/RobotecAI/ros2-forunity
カスタムメッセージの追加
開発元
URL


# Page. 79

![Page Image](https://bcdn.docswell.com/page/4EQXYQ2N7P.jpg)

using UnityEngine;
public class HellowWorldPublisher: MonoBehaviour
{
void Start()
{
var stringPublisher = SimulatorROS2Node.CreatePublisher&lt;std_msgs.msg.string&gt;(“hello topic”);
stringPublisher.Publish(“hello world”);
}
}


# Page. 80

![Page Image](https://bcdn.docswell.com/page/KJ46WNL371.jpg)

using UnityEngine;
public class HellowWorldPublisher: MonoBehaviour
{
void Start()
{
var stringPublisher = SimulatorROS2Node.CreatePublisher&lt;std_msgs.msg.string&gt;(“hello topic”);
stringPublisher.Publish(“hello world”);
}
}
最小のコードはたった2行！


# Page. 81

![Page Image](https://bcdn.docswell.com/page/LE1VY5LZ7G.jpg)



# Page. 82

![Page Image](https://bcdn.docswell.com/page/GEWLG5V672.jpg)

LTE roter
CP Trans
OD perception
OD perception
NW Switch
SUB ECU
NW Switch
OD perception
Signage
ECU
OD perception
NW Switch
Outer Speaker
ECU
SUB ECU
FOA ECU
Display
NW Switch
NW Switch


# Page. 83

![Page Image](https://bcdn.docswell.com/page/47ZMLN4RE3.jpg)

•
•
•
•
•
•
Simulated data of a Velodyne Puck in a small room using Unity Sensor SDK
https://www.youtube.com/watch?v=ZXzTvtxx1bw&amp;t=45s


# Page. 84

![Page Image](https://bcdn.docswell.com/page/YJ6NW831JV.jpg)

•
•
•
•
•
Unity SystemGraph: Mechatronics systems simulation
https://www.youtube.com/watch?v=ZXzTvtxx1bw&amp;t=45s


# Page. 85

![Page Image](https://bcdn.docswell.com/page/GJ55M9LLJ4.jpg)



# Page. 86

![Page Image](https://bcdn.docswell.com/page/9E2N92L37R.jpg)



# Page. 87

![Page Image](https://bcdn.docswell.com/page/D7YP4YQ87M.jpg)



# Page. 88

![Page Image](https://bcdn.docswell.com/page/VEN5YPK9J8.jpg)



# Page. 89

![Page Image](https://bcdn.docswell.com/page/Y79YP3V3E3.jpg)



# Page. 90

![Page Image](https://bcdn.docswell.com/page/G786DMPLJD.jpg)

•
Examples : Cut-In
•
https://releases.asam.net/OpenSCENARIO/1.0.0/ASAM_OpenSCENARIO_BS-1-2_User-Guide_V1-0-0.html
•
•
•
•
•
Examples : Double Lane Changer
https://releases.asam.net/OpenSCENARIO/1.0.0/ASAM_OpenSCENARIO_BS-1-2_User-Guide_V1-0-0.html


# Page. 91

![Page Image](https://bcdn.docswell.com/page/L7L9M31QER.jpg)



# Page. 92

![Page Image](https://bcdn.docswell.com/page/4EMZYD5K7W.jpg)



# Page. 93

![Page Image](https://bcdn.docswell.com/page/PER69436J9.jpg)



