modify thirdparty package:sdformat

This commit is contained in:
AIRC exercise 2019-05-24 09:27:01 +08:00
parent 5c8ee87a61
commit 23ed3a27ed
23 changed files with 382 additions and 0 deletions

View File

@ -0,0 +1,28 @@
# Gazebo_exercise优化控制SDF标签使用说明
2019-05-20 by tjpu_zenglei@sina.com
## 优化控制SDF标签设计总体思路
为方便用户使用集中管理自主实现的优化SDF标签统一设计并实现了基于SDFormat包的优化控制标签。
针对目前Gazebo_exercise已经优化的模型预处理模块、UpdatePhysics模块、dxHashSpace::collide模块等分别添加标签<event_signal>(用于设置模型预处理模块并行参数)、<updatephysics_dxprocessislands>用于设置UpdatePhysics模块并行参数<dxhashspace_collide>用于设置collide模块并行参数<collide_space>(用于选择碰撞空间数据结构类型)。
## SDF标签使用说明
所有优化控制标签均为标签<exercise_opt>子标签,<exercise_opt>为标签<world>子标签,如下所示。
```
<world>
...
<exercise_opt>
<event_signal parallel_type=1 threads=7 />
<collide_space>1</collide_space>
<dxhashspace_collide threads=7 />
<updatephysics_dxprocessislands parallel_type=1 threads=4 />
</exercise_opt>
...
</world>
```
标签释义如下:
- <exercise_opt>标签:优化总开关。
- <event_signal>标签用于设置模型预处理模块并行优化参数parallel_type为1~5表示OpenMp优化一般设置为1即可其他是采用不同的任务并发方式threads为开启的线程数parallel_type为其他数字时表示不开启优化。
- <collide_space>标签用于设置碰撞更新模块中碰撞空间的类型值为1时表示SAP空间类型其他数字表示默认的Hash空间类型。
- <dxhashspace_collide>标签用于设置碰撞更新模块中dxHashSpace::collide模块并行参数<collide_space>标签设置为1时该参数没有意义其他情况下threads大于1表示采用OpenMP并行优化threads为开启的线程数否则不开启优化。
- <updatephysics_dxprocessislands>标签用于设置物理更新模块中dxProcessIslands模块并行参数parallel_type为1~5表示OpenMp优化一般设置为1即可其他是采用不同的任务并发方式threads为开启的线程数parallel_type为其他数字时表示不开启优化。

View File

@ -25,6 +25,9 @@ set (sdfs
surface.sdf surface.sdf
visual.sdf visual.sdf
world.sdf world.sdf
exercise_opt.sdf
server.sdf
event.sdf
) )
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat/1.0/) install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat/1.0/)

View File

@ -0,0 +1,45 @@
<!-- Exercise_opt -->
<!--
***********************************************************
**Description: the gazebo_exercise labels to optimize *
**Author: zenglei *
**Date: 2019-05-15 *
**Version: V1.0 *
***********************************************************
-->
<element name="exercise_opt" required="0">
<description>The Gazebo_exercise tag specifies the on-off and properties of the optimization.</description>
<element name="process_messages_switch" type="bool" default="1" required="0">
<description>whether optimize the logic of the topic to pub in the World::processMessages or not</description>
</element>
<element name="collide_space" type="int" default="0" required="0">
<description>target the type of the collide space</description>
</element>
<element name="event_signal" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="updatephysics_dxprocessislands" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="dxhashspace_collide" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="threads" type="int" default="0" required="0">
<description>The number of thread to parallel.</description>
</attribute>
</element>
</element> <!-- exercise_opt -->

View File

@ -63,4 +63,5 @@
<include filename="population.sdf" required="*"/> <include filename="population.sdf" required="*"/>
<include filename="event.sdf" required="0"/> <include filename="event.sdf" required="0"/>
<include filename="server.sdf" required="0"/> <include filename="server.sdf" required="0"/>
<include filename="exercise_opt.sdf" required="0"/>
</element> <!-- End World --> </element> <!-- End World -->

View File

@ -26,6 +26,9 @@ set (sdfs
surface.sdf surface.sdf
visual.sdf visual.sdf
world.sdf world.sdf
exercise_opt.sdf
server.sdf
event.sdf
) )
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat/1.2) install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat/1.2)

View File

@ -0,0 +1,45 @@
<!-- Exercise_opt -->
<!--
***********************************************************
**Description: the gazebo_exercise labels to optimize *
**Author: zenglei *
**Date: 2019-05-15 *
**Version: V1.0 *
***********************************************************
-->
<element name="exercise_opt" required="0">
<description>The Gazebo_exercise tag specifies the on-off and properties of the optimization.</description>
<element name="process_messages_switch" type="bool" default="1" required="0">
<description>whether optimize the logic of the topic to pub in the World::processMessages or not</description>
</element>
<element name="collide_space" type="int" default="0" required="0">
<description>target the type of the collide space</description>
</element>
<element name="event_signal" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="updatephysics_dxprocessislands" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="dxhashspace_collide" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="threads" type="int" default="0" required="0">
<description>The number of thread to parallel.</description>
</attribute>
</element>
</element> <!-- exercise_opt -->

View File

@ -63,4 +63,5 @@
<include filename="population.sdf" required="*"/> <include filename="population.sdf" required="*"/>
<include filename="event.sdf" required="0"/> <include filename="event.sdf" required="0"/>
<include filename="server.sdf" required="0"/> <include filename="server.sdf" required="0"/>
<include filename="exercise_opt.sdf" required="0"/>
</element> <!-- End World --> </element> <!-- End World -->

View File

@ -27,6 +27,9 @@ set (sdfs
surface.sdf surface.sdf
visual.sdf visual.sdf
world.sdf world.sdf
exercise_opt.sdf
server.sdf
event.sdf
) )
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat/1.3) install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat/1.3)

View File

@ -0,0 +1,45 @@
<!-- Exercise_opt -->
<!--
***********************************************************
**Description: the gazebo_exercise labels to optimize *
**Author: zenglei *
**Date: 2019-05-15 *
**Version: V1.0 *
***********************************************************
-->
<element name="exercise_opt" required="0">
<description>The Gazebo_exercise tag specifies the on-off and properties of the optimization.</description>
<element name="process_messages_switch" type="bool" default="1" required="0">
<description>whether optimize the logic of the topic to pub in the World::processMessages or not</description>
</element>
<element name="collide_space" type="int" default="0" required="0">
<description>target the type of the collide space</description>
</element>
<element name="event_signal" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="updatephysics_dxprocessislands" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="dxhashspace_collide" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="threads" type="int" default="0" required="0">
<description>The number of thread to parallel.</description>
</attribute>
</element>
</element> <!-- exercise_opt -->

View File

@ -63,4 +63,5 @@
<include filename="population.sdf" required="*"/> <include filename="population.sdf" required="*"/>
<include filename="event.sdf" required="0"/> <include filename="event.sdf" required="0"/>
<include filename="server.sdf" required="0"/> <include filename="server.sdf" required="0"/>
<include filename="exercise_opt.sdf" required="0"/>
</element> <!-- End World --> </element> <!-- End World -->

View File

@ -42,6 +42,9 @@ set (sdfs
transceiver.sdf transceiver.sdf
visual.sdf visual.sdf
world.sdf world.sdf
exercise_opt.sdf
server.sdf
event.sdf
) )
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat/1.4) install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat/1.4)

View File

@ -0,0 +1,45 @@
<!-- Exercise_opt -->
<!--
***********************************************************
**Description: the gazebo_exercise labels to optimize *
**Author: zenglei *
**Date: 2019-05-15 *
**Version: V1.0 *
***********************************************************
-->
<element name="exercise_opt" required="0">
<description>The Gazebo_exercise tag specifies the on-off and properties of the optimization.</description>
<element name="process_messages_switch" type="bool" default="1" required="0">
<description>whether optimize the logic of the topic to pub in the World::processMessages or not</description>
</element>
<element name="collide_space" type="int" default="0" required="0">
<description>target the type of the collide space</description>
</element>
<element name="event_signal" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="updatephysics_dxprocessislands" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="dxhashspace_collide" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="threads" type="int" default="0" required="0">
<description>The number of thread to parallel.</description>
</attribute>
</element>
</element> <!-- exercise_opt -->

View File

@ -63,4 +63,5 @@
<include filename="population.sdf" required="*"/> <include filename="population.sdf" required="*"/>
<include filename="event.sdf" required="0"/> <include filename="event.sdf" required="0"/>
<include filename="server.sdf" required="0"/> <include filename="server.sdf" required="0"/>
<include filename="exercise_opt.sdf" required="0"/>
</element> <!-- End World --> </element> <!-- End World -->

View File

@ -53,6 +53,9 @@ set (sdfs
transceiver.sdf transceiver.sdf
visual.sdf visual.sdf
world.sdf world.sdf
exercise_opt.sdf
server.sdf
event.sdf
) )
set (SDF_SCHEMA) set (SDF_SCHEMA)

View File

@ -0,0 +1,45 @@
<!-- Exercise_opt -->
<!--
***********************************************************
**Description: the gazebo_exercise labels to optimize *
**Author: zenglei *
**Date: 2019-05-15 *
**Version: V1.0 *
***********************************************************
-->
<element name="exercise_opt" required="0">
<description>The Gazebo_exercise tag specifies the on-off and properties of the optimization.</description>
<element name="process_messages_switch" type="bool" default="1" required="0">
<description>whether optimize the logic of the topic to pub in the World::processMessages or not</description>
</element>
<element name="collide_space" type="int" default="0" required="0">
<description>target the type of the collide space</description>
</element>
<element name="event_signal" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="updatephysics_dxprocessislands" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="dxhashspace_collide" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="threads" type="int" default="0" required="0">
<description>The number of thread to parallel.</description>
</attribute>
</element>
</element> <!-- exercise_opt -->

View File

@ -63,4 +63,5 @@
<include filename="population.sdf" required="*"/> <include filename="population.sdf" required="*"/>
<include filename="event.sdf" required="0"/> <include filename="event.sdf" required="0"/>
<include filename="server.sdf" required="0"/> <include filename="server.sdf" required="0"/>
<include filename="exercise_opt.sdf" required="0"/>
</element> <!-- End World --> </element> <!-- End World -->

View File

@ -54,6 +54,9 @@ set (sdfs
transceiver.sdf transceiver.sdf
visual.sdf visual.sdf
world.sdf world.sdf
exercise_opt.sdf
server.sdf
event.sdf
) )
set (SDF_SCHEMA) set (SDF_SCHEMA)

View File

@ -0,0 +1,60 @@
<!-- Exercise_opt -->
<!--
***********************************************************
**Description: the gazebo_exercise labels to optimize *
**Author: zenglei *
**Date: 2019-05-15 *
**Version: V1.0 *
***********************************************************
-->
<element name="exercise_opt" required="0">
<description>The Gazebo_exercise tag specifies the on-off and properties of the optimization.</description>
<element name="process_messages_switch" type="bool" default="1" required="0">
<description>whether optimize the logic of the topic to pub in the World::processMessages or not</description>
</element>
<element name="collide_space" type="int" default="0" required="0">
<description>target the type of the collide space</description>
</element>
<element name="event_signal" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
<attribute name="tbb_type" type="int" default="25" required="0">
<description>the size of block to tbb thread</description>
</attribute>
<attribute name="tbb_block_size" type="int" default="0" required="0">
<description>the type to block partion</description>
</attribute>
</element>
<element name="updatephysics_dxprocessislands" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
<attribute name="tbb_type" type="int" default="25" required="0">
<description>the size of block to tbb thread</description>
</attribute>
<attribute name="tbb_block_size" type="int" default="0" required="0">
<description>the type to block partion</description>
</attribute>
</element>
<element name="dxhashspace_collide" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="threads" type="int" default="0" required="0">
<description>The number of thread to parallel.</description>
</attribute>
</element>
</element> <!-- exercise_opt -->

View File

@ -0,0 +1,45 @@
<!-- Exercise_opt -->
<!--
***********************************************************
**Description: the gazebo_exercise labels to optimize *
**Author: zenglei *
**Date: 2019-05-15 *
**Version: V1.0 *
***********************************************************
-->
<element name="exercise_opt" required="0">
<description>The Gazebo_exercise tag specifies the on-off and properties of the optimization.</description>
<element name="process_messages_switch" type="bool" default="1" required="0">
<description>whether optimize the logic of the topic to pub in the World::processMessages or not</description>
</element>
<element name="collide_space" type="int" default="0" required="0">
<description>target the type of the collide space</description>
</element>
<element name="event_signal" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="updatephysics_dxprocessislands" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="parallel_type" type="int" default="0" required="0">
<description>The type of parallel.</description>
</attribute>
<attribute name="threads" type="int" default="8" required="0">
<description>The numbers of the threads.</description>
</attribute>
</element>
<element name="dxhashspace_collide" required="0">
<description>target the number of the thread that used by parallel.</description>
<attribute name="threads" type="int" default="0" required="0">
<description>The number of thread to parallel.</description>
</attribute>
</element>
</element> <!-- exercise_opt -->

View File

@ -63,4 +63,5 @@
<include filename="population.sdf" required="*"/> <include filename="population.sdf" required="*"/>
<include filename="event.sdf" required="0"/> <include filename="event.sdf" required="0"/>
<include filename="server.sdf" required="0"/> <include filename="server.sdf" required="0"/>
<include filename="exercise_opt.sdf" required="0"/>
</element> <!-- End World --> </element> <!-- End World -->

View File

View File

View File