rock overview

35
Rock - The Robot Construction Kit http://rock-robotics.org Sylvain Joyeux DFKI Bremen - Forschungruppe Robotik & Universit ¨ at Bremen Director: Prof. Dr. Frank Kirchner www.dfki.de/robotics [email protected]

Upload: sylvain-joyeux

Post on 01-Nov-2014

373 views

Category:

Technology


0 download

DESCRIPTION

This is a presentation that has been given at the University of Rio de Janeiro in March. Video is here: http://www.youtube.com/watch?v=BLhW4ooKbAc

TRANSCRIPT

Page 1: Rock Overview

Rock - The Robot Construction Kithttp://rock-robotics.org

Sylvain Joyeux

DFKI Bremen - Forschungruppe Robotik& Universitat Bremen

Director: Prof. Dr. Frank Kirchnerwww.dfki.de/[email protected]

Page 2: Rock Overview

Who am I ?

Senior Researcher @DFKI Robotics Innovation Center inBremen

DFKI is a German public/private partnership for AI researchFocussing on architectures for long-term autonomy⇒ quit the “demo robotics” state of mind

PhD: plan manager for multi-robot systemsDFKI

Intelligent Mobility: autonomous navigation in unknown,unstructured, environmentsSauc-E, HROV: autonomous mission execution on AUVs.Resp. student project and on an oceanographic AUVVirgo4: long-term autonomy integrating learning methods

Now leader of the “Autonomy Team”

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 2/35

Page 3: Rock Overview

Rock: The Robot Construction Kit

Vizkit: Data Visualization

OpenSceneGraph, Qt, vtk

Data Logging And Replay

Very efficient logging

Long-term analysis and replay

Script-based system deployment

Distributed process management

Coordination

Script-based

Page 4: Rock Overview

Component Development

Page 5: Rock Overview

Component Development

oroGen workflow

all algorithms should be developed first in aframework-independent libraryrock-create-lib path/to/library

language of choice (currently): C++you then integrate the library’s functionality intocomponent(s)

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 5/35

Page 6: Rock Overview

Component Development

Framework-independent libraries

Critical !

no one can predict the future of frameworks⇒ the “hot” framework is ROS nowadays, was player three

years ago, what will it be in three years ?

industry / other partners will probably not want to use yourframework of choiceframeworks evolve

FortunatelyIt is finally becoming the standard: OpenCV, OpenNI, PCL,OpenRave, OMPL, Reflexxes, Gazebo, . . .

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 6/35

Page 7: Rock Overview

Component Development

Component interface

messagesmessage_driver/Message

message_producer::Task

message_driver::MessageDriver

configmessage_driver/Config

messagesmessage_driver/Message

message_consumer::Task

message_driver::MessageDriver

connections: "route" data

between the component ports

Connected ports need to have

the same type

input ports: allow a

component to get data

produced by other

components

output port: used to

send data to other

components

properties store configuration

values for the task

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 7/35

Page 8: Rock Overview

Component Development

Component description

task context ’BaseTask’ dooutput port(’solution’, ’/gps/Solution’).

doc "the GPS solution as reported by the hardware"

output port(’position_samples’, ’/base/samples/RigidBodyState’).doc "computed position in m"

error states :IO ERROR, :IO TIMEOUTproperty("utm_zone", "int", 32).

doc "UTM zone for conversion of WGS84 to UTM"

end

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 8/35

Page 9: Rock Overview

Component Development

Type description

a subset of C++helps integrating oroGen-free libraries⇒ no convertions / bindings necessary

namespace tutorials {struct Msg {

std::string value;};

}

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 9/35

Page 10: Rock Overview

Component Development

What is so special about it ?

separation between description and code⇒ easy to discover other people’s components

hard-realtime compatibleRTT core is “only” a component model and supportinginfrastructure. Independent of any communication layer“main” communication layer is CORBA. Full support fordata flow on ROS and POSIX message queues. Somesupport for YARP.can talk to multiple communication layers at the same time

Stopped Running

FatalError

RuntimeError

PreOperational

Output

ports

Input

ports

Properties

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 10/35

Page 11: Rock Overview

Component Development

Highlights

What you get for free is

dynamic reconfigurationrun what you need when you need itcomponent monitoringerror recoverycoordinationdeployment-time choices⇒ components can be deployed in the same thread, same

process or in different processes depending on yourapplication

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 11/35

Page 12: Rock Overview

Basic Services

Data Logging And Replay

Very efficient logging

Long-term analysis and replay

Page 13: Rock Overview

Basic Services

Logging

Low-overhead: 5% CPU for a whole system, from 1kHzcontrol loop ( 5 components) to high-level stereoprocessingSelf-contained: a log file is all you need to read the data⇒ guarantee to re-read years-old data

Future-proof: rock-convert “upgrades” old log files forwhich data types changed⇒ can reuse old datasets to test new / visualize new code

Interoperable: convertion tool to HDF5 for e.g. Matlab

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 13/35

Page 14: Rock Overview

Basic Services

vizkit: Log Replay / Data Visualization

visualization of log files“replay” log data into components⇒ test components⇒ regression testing

Video

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 14/35

Page 15: Rock Overview

Basic Services

GUI Design

can open standalone widgets / 3D views from task browser/ log browser⇒ ideal for one-shot data analysis sessions

all widgets are standard Qt widgets⇒ can be used to design complete GUIs, e.g. using Qt

Designer

design GUIs, bind it using vizkit

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 15/35

Page 16: Rock Overview

Data Processing Helpers

Page 17: Rock Overview

Data Processing Helpers

stream aligner: the problem

0 10 20 30 40t(ms)

Sensor Acquisition - when the sensor reads a value originating from the real world

Lidar, period=25ms

Cameras, period=17ms (60fps)

Motion Tracker

1 2 3 4 5

1 2

1 2

1 2

Servo, period=10ms1 2 3

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 17/35

Page 18: Rock Overview

Data Processing Helpers

stream aligner: the problem

0 10 500 510t(ms)

Sensor Processing - when samples arrive, are processed, and leave components

1

1

1

1

Laser

Filter1

1

1

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 18/35

Page 19: Rock Overview

Data Processing Helpers

stream aligner: latency

realigning adds latency⇒ you have to wait to know which samples can be safely

processedconcept of lookahead⇒ add more information to improve the latency situation

0 10

1

1

Laser

Filter

0 10

1

1

Laser

Filter

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 19/35

Page 20: Rock Overview

Data Processing Helpers

transformer

extension to the stream aligner conceptcomputes arbitrary geometric transformations betweenframesaligns (in time) the computed transformations with otherdata streamsoptionally interpolatesdistributed: one component only gets what it needs

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 20/35

Page 21: Rock Overview

Scripting-based execution

Page 22: Rock Overview

Scripting-based execution

Ruby-based scripting

gives access to all componentsgives access to processes⇒ can detect when a process crashes

gives access to ROS nodes / log files⇒ integrate ROS / Rock and log files seamlessly

Ideal for small-scale testing

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 22/35

Page 23: Rock Overview

Scripting-based execution

Example

require ’orocos’

Orocos.initializeOrocos.run ’message_consumer::Task’ => ’message_consumer’,’message_producer::Task’ => ’message_producer’ do

producer = Orocos.name service.get ’message_producer’consumer = Orocos.name service.get ’message_consumer’producer.messages.connect to consumer.messages

producer.configureproducer.startconsumer.configureconsumer.startOrocos.watch(producer, consumer)

end

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 23/35

Page 24: Rock Overview

System Integration

Page 25: Rock Overview

System Integration

Real-World Systems

are always more complex than we originally thinkhow to safely reuse (parts of) component networks ?how to simply combine different subsystems ?⇒ since they often share some subparts

how to do systematic error monitoring and error recovery

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 25/35

Page 26: Rock Overview

System Integration

The Concept: System Design

Subsystem Composition

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 26/35

Page 27: Rock Overview

System Integration

The Concept: System Monitoring

Hierarchy

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 27/35

Page 28: Rock Overview

System Integration

Highlights

offline system design⇒ can design integrated systems without writing a single

component

can manage multi-host systems transparentlyhigh-level runtime coordination⇒ can arbitrarily and safely switch between behaviours

extensive logging and display⇒ logs the whole system view

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 28/35

Page 29: Rock Overview

System Integration

The Means

syskit can be used as soon as oroGen is usedno need to “think syskit” from the very beginning. . . but it remains available when the complexity grows

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 29/35

Page 30: Rock Overview

System Integration

Results: An Overview

In the end

bachelor students are able to use syskit⇒ it is complex, but not that much

promotes separation of roles: many algorithm developers,one or two system integratorsproved incredibly useful on real-world systems

Sauc-E 2011 Intelligent Mobility Final

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 30/35

Page 31: Rock Overview

Conclusion

Page 32: Rock Overview

Conclusion

Scalability

At the level of computing power required

⇒ multi-host, multi-process deployments down tosingle-threaded, no-overhead deployments

⇒ run only what is needed at a certain point in time

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 32/35

Page 33: Rock Overview

Conclusion

Scalability

At the level of system complexity

use either command-line tools or (very simple) ruby scriptsfor small systemsuse model-based deployments when the complexity grows

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 33/35

Page 34: Rock Overview

Conclusion

Framework-independent Workflow

the “code libraries first, integrate later” workflow is anintegral part of Rockcan very easily integrate external libraries without anymodifications

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 34/35

Page 35: Rock Overview

Conclusion

A Proven Framework

we don’t reinvent the wheel(s)⇒ reuse as much as we can when it makes sense

based on Orocos/RTT, which is a componentimplementation used in a variety of systems including inindustry

Rock - The Robot Construction Kit http://rock-robotics.org

May 3, 2013 35/35