Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Pinoxchio
apollo
提交
dc0c898a
A
apollo
项目概览
Pinoxchio
/
apollo
与 Fork 源项目一致
从无法访问的项目Fork
通知
2
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
A
apollo
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
dc0c898a
编写于
9月 06, 2020
作者:
S
storypku
提交者:
Xiangquan Xiao
9月 06, 2020
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Docs|Scripts: improved record downloader renamed from rosbag_helper.py
上级
5602ccf6
变更
5
隐藏空白更改
内联
并排
Showing
5 changed file
with
160 addition
and
67 deletion
+160
-67
docs/demo_guide/README.md
docs/demo_guide/README.md
+31
-27
docs/demo_guide/README_cn.md
docs/demo_guide/README_cn.md
+47
-37
docs/demo_guide/record_helper.py
docs/demo_guide/record_helper.py
+79
-0
docs/howto/how_to_launch_Apollo.md
docs/howto/how_to_launch_Apollo.md
+1
-1
docs/specs/D-kit/Waypoint_Following/Apollo_Installation_cn.md
.../specs/D-kit/Waypoint_Following/Apollo_Installation_cn.md
+2
-2
未找到文件。
docs/demo_guide/README.md
浏览文件 @
dc0c898a
...
...
@@ -14,48 +14,52 @@ Setup steps:
1.
Start the docker release environment using the command:
```
bash docker/scripts/dev_start.sh
```
```
bash docker/scripts/dev_start.sh
```
2.
Enter the docker release environment:
```
bash docker/scripts/dev_into.sh
```
```
bash docker/scripts/dev_into.sh
```
3.
Build Apollo in the Container:
```
bash apollo.sh build
```
`Note:`
If you do not have a GPU, you can use the following script instead
```
bash apollo.sh build_cpu
```
```
bash apollo.sh build
```
`Note:`
If you do not have a GPU, you can use the following script instead
```
bash apollo.sh build_cpu
```
4.
Bootstrap to start ros call and Monitor module and Dreamview
```
bash scripts/bootstrap.sh
```
```
bash scripts/bootstrap.sh
```
5.
Download demo record:
```
cd docs/demo_guide/
python rosbag_helper.py demo_3.5.record
```
```
cd docs/demo_guide/
python record_helper.py demo_3.5.record
```
6.
Now you can play the record:
```
cyber_recorder play -f docs/demo_guide/demo_3.5.record --loop
```
```
cyber_recorder play -f docs/demo_guide/demo_3.5.record --loop
```
The `--loop` option enables record to keep playing the bag in a loop playback mode.
The
`--loop`
option enables record to keep playing the bag in a loop playback
mode.
7.
Open Chrome and go to
**localhost:8888**
to access Apollo Dreamview, which
opens the screen below.
!
[](
images/dv_trajectory.png
)
The car in Dreamview is happy to move around!
opens the screen below. !
[](
images/dv_trajectory.png
)
The car in Dreamview is
happy to move around!
Congratulations!
docs/demo_guide/README_cn.md
浏览文件 @
dc0c898a
# 运行线下演示
如果你没有车辆及车载硬件, Apollo还提供了一个计算机模拟环境,可用于演示和代码调试。
如果你没有车辆及车载硬件, Apollo 还提供了一个计算机模拟环境,可用于演示和代码调
试。
线下演示首先要Fork并且Clone Apollo在GitHub的代码,然后需要设置docker的release环境,请参照
[
how_to_build_and_release
](
https://github.com/ApolloAuto/apollo/blob/master/docs/howto/how_to_build_and_release.md
)
文档中的
[
Install docker
](
https://github.com/ApolloAuto/apollo/blob/master/docs/howto/how_to_build_and_release.md#docker
)
章节。
线下演示首先要 Fork 并且 Clone Apollo 在 GitHub 的代码,然后需要设置 docker 的
release 环境,请参照
[
how_to_build_and_release
](
https://github.com/ApolloAuto/apollo/blob/master/docs/howto/how_to_build_and_release.md
)
文
档中
的
[
Install docker
](
https://github.com/ApolloAuto/apollo/blob/master/docs/howto/how_to_build_and_release.md#docker
)
章
节。
Apollo演示的安装步骤:
Apollo
演示的安装步骤:
1.
运行如下命令启动
docker的release
环境:
1.
运行如下命令启动
docker 的 release
环境:
```
bash docker/scripts/dev_start.sh
```
```
bash docker/scripts/dev_start.sh
```
2.
运行如下命令进入
docker的release
环境:
2.
运行如下命令进入
docker 的 release
环境:
```
bash docker/scripts/dev_into.sh
```
```
bash docker/scripts/dev_into.sh
```
3.
在Docker中编译Apollo:
```
bash apollo.sh build
```
`Note:`
如果没有GPU,请使用下面的命令
3.
在 Docker 中编译 Apollo:
```
bash apollo.sh build_cpu
```
```
bash apollo.sh build
```
4.
启动DreamView
```
bash scripts/bootstrap.sh
```
`Note:`
如果没有 GPU,请使用下面的命令
5.
下载demo record:
```
cd docs/demo_guide/
python rosbag_helper.py demo_3.5.record
```
```
bash apollo.sh build_cpu
```
6.
运行如下命令回放record:
4.
启动 DreamView
```
cyber_recorder play -f docs/demo_guide/demo_3.5.record --loop
```
```
bash scripts/bootstrap.sh
```
选项 `--loop` 用于设置循环回放模式.
5.
下载 demo record:
7.
打开Chrome浏览器,在地址栏输入
**localhost:8888**
即可访问Apollo Dreamview,如下图所示:
!
[](
images/dv_trajectory.png
)
现在你能看到有一辆汽车在模拟器里移动!
```
cd docs/demo_guide/
python record_helper.py demo_3.5.record
```
恭喜你完成了Apollo的演示步骤!
6.
运行如下命令回放 record:
```
cyber_recorder play -f docs/demo_guide/demo_3.5.record --loop
```
选项
`--loop`
用于设置循环回放模式.
7.
打开 Chrome 浏览器,在地址栏输入
**localhost:8888**
即可访问 Apollo Dreamview,
如下图所示: !
[](
images/dv_trajectory.png
)
现在你能看到有一辆汽车在模拟器里移
动!
恭喜你完成了 Apollo 的演示步骤!
docs/demo_guide/r
osbag
_helper.py
→
docs/demo_guide/r
ecord
_helper.py
浏览文件 @
dc0c898a
...
...
@@ -15,52 +15,65 @@
# See the License for the specific language governing permissions and
# limitations under the License.
###############################################################################
"""
A script for downloading Apollo record files
"""
import
os
import
sys
import
argparse
import
subprocess
import
urllib.request
import
urllib.parse
import
urllib.error
DOWNLOAD_LINK_PREFIX
=
"https://github.com/ApolloAuto/apollo/releases/download"
URL_LIST
=
[
"https://github.com/ApolloAuto/apollo/releases/download/v1.5.0/demo_1.5.bag"
,
"https://github.com/ApolloAuto/apollo/releases/download/v2.0.0/demo_2.0.bag"
,
"https://github.com/ApolloAuto/apollo/releases/download/v2.0.0/apollo_2.0_camera_sample.bag"
,
"https://github.com/ApolloAuto/apollo/releases/download/v2.5.0/demo_2.5.bag"
,
"https://github.com/ApolloAuto/apollo/releases/download/v1.0.0/demo_1.0.bag"
,
"https://github.com/ApolloAuto/apollo/releases/download/v3.5.0/demo_3.5.record"
,
URL_LISTING
=
[
"v1.0.0/demo_1.0.bag"
,
"v1.5.0/demo_1.5.bag"
,
"v2.0.0/demo_2.0.bag"
,
"v2.0.0/apollo_2.0_camera_sample.bag"
,
"v2.5.0/demo_2.5.bag"
,
"v3.5.0/demo_3.5.record"
,
]
URL_DICT
=
{}
for
link
in
URL_LIST
:
name
=
link
.
split
(
"/"
)[
-
1
]
URL_DICT
[
name
]
=
link
def
build_urls
():
urls
=
{}
for
u
in
URL_LISTING
:
urls
[
os
.
path
.
basename
(
u
)]
=
"{}/{}"
.
format
(
DOWNLOAD_LINK_PREFIX
,
u
)
return
urls
def
retrieve_rosbag
(
bagname
):
if
bagname
not
in
URL_DICT
:
def
download_record
(
record_name
,
urls
):
"""
Match and download record from urls, and save it locally
"""
if
record_name
not
in
urls
:
print
(
"bag[%s] is unknown, use one of the following rosbag names:
\n
%s"
%
(
bagname
,
", "
.
join
([
name
for
name
in
URL_DICT
.
keys
()])))
"Unknown record: {}. Type
\"
{} --help
\"
on available records."
.
format
(
record_name
,
sys
.
argv
[
0
]))
return
False
url
=
URL_DICT
[
bag
name
]
print
(
"Downloading
from %s"
%
url
)
re
t
=
os
.
system
(
'wget %s -O %s'
%
(
url
,
bagname
)
)
return
re
t
==
0
url
=
urls
[
record_
name
]
print
(
"Downloading
{}"
.
format
(
url
)
)
re
sult
=
subprocess
.
run
([
"wget"
,
url
,
"-O"
,
record_name
]
)
return
re
sult
.
returncode
==
0
if
__name__
==
"__main__"
:
import
argparse
urls
=
build_urls
()
name_desc
=
"record name. Available records: {}"
.
format
(
", "
.
join
(
u
for
u
in
urls
))
parser
=
argparse
.
ArgumentParser
(
description
=
'retrieve demo rosbag file from remote'
)
description
=
"A script for downloading Apollo demo records"
)
parser
.
add_argument
(
'name'
,
"name"
,
type
=
str
,
help
=
'rosbag names. You can choose one of [%s]'
%
", "
.
join
(
[
name
for
name
in
URL_DICT
.
keys
()]))
help
=
name_desc
)
args
=
parser
.
parse_args
()
if
retrieve_rosbag
(
args
.
name
):
print
(
"Download %s success"
%
args
.
name
)
requested_record
=
args
.
name
success
=
download_record
(
requested_record
,
urls
)
if
success
:
print
(
"Successfully downloaded {}"
.
format
(
requested_record
))
else
:
print
(
"
Download %s failed"
%
args
.
name
)
print
(
"
Bad luck, failed to download {}"
.
format
(
requested_record
)
)
docs/howto/how_to_launch_Apollo.md
浏览文件 @
dc0c898a
...
...
@@ -59,7 +59,7 @@ To see if the system works, use the demo 'record' to "feed" the system.
```
# You need to download the demo record using the following commands
cd docs/demo_guide/
python3 r
osbag
_helper.py demo_3.5.record
python3 r
ecord
_helper.py demo_3.5.record
# You can now replay this demo "record" in a loop with the '-l' flag
cyber_recorder play -f docs/demo_guide/demo_3.5.record -l
...
...
docs/specs/D-kit/Waypoint_Following/Apollo_Installation_cn.md
浏览文件 @
dc0c898a
...
...
@@ -533,7 +533,7 @@ c.回放数据包
在终端输入以下命令下载数据包:
```
python
docs/demo_guide/rosbag
_helper.py demo_3.5.record
python
3 docs/demo_guide/record
_helper.py demo_3.5.record
```
输入以下命令可以回放数据包,在浏览器DreamView中应该可以看到回放画面。
...
...
@@ -606,4 +606,4 @@ function check_esd_files() {
fi
}
```
不同的apollo版本可能对检查的库文件名称的要求不同,可根据实际情况建立软连接。
\ No newline at end of file
不同的apollo版本可能对检查的库文件名称的要求不同,可根据实际情况建立软连接。
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录