2023-10-25 10:34:46 +08:00
|
|
|
|
"""
|
|
|
|
|
环境主动探索和记忆
|
|
|
|
|
要求输出探索结果(语义地图)对环境重点信息记忆。生成环境的语义拓扑地图,和不少于10个环境物品的识别和位置记忆,可以是图片或者文字或者格式化数据。
|
|
|
|
|
"""
|
|
|
|
|
|
|
|
|
|
from robowaiter.scene.scene import Scene
|
|
|
|
|
class SceneAEM(Scene):
|
|
|
|
|
def __init__(self, robot):
|
|
|
|
|
super().__init__(robot)
|
2023-11-15 12:04:49 +08:00
|
|
|
|
|
|
|
|
|
def _reset(self):
|
|
|
|
|
pass
|
|
|
|
|
def _run(self):
|
2023-11-15 15:09:51 +08:00
|
|
|
|
cur_objs = []
|
|
|
|
|
print('------------ 自主探索 ------------')
|
|
|
|
|
cur_objs = self.semantic_map.navigation_move(cur_objs, 0, 11)
|
|
|
|
|
print("物品列表如下:")
|
|
|
|
|
print(cur_objs)
|
2023-11-15 14:56:03 +08:00
|
|
|
|
|
2023-11-15 12:04:49 +08:00
|
|
|
|
pass
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if __name__ == '__main__':
|
|
|
|
|
import os
|
|
|
|
|
from robowaiter.robot.robot import Robot
|
|
|
|
|
|
|
|
|
|
robot = Robot()
|
|
|
|
|
|
|
|
|
|
# create task
|
|
|
|
|
task = SceneAEM(robot)
|
|
|
|
|
task.reset()
|
2023-11-15 15:09:51 +08:00
|
|
|
|
task.run()
|