System description - sonyaa/roboflow GitHub Wiki

Currently the system works as follows:

Frontend

The frontend is written in JavaScript, using the Polymer library for custom HTML elements and Fabric.js for drawing.

app/index.html specifies the menu display (which tokens and buttons to display on the left) and the ROS services to call (i.e. to execute Manipulation step, call this service; to get list of saved Locations, call that service).

The main source code folder is app/elements, with the majority of things going on in app/elements/r-interface. r-interface.js ties everything together, and the individual parts are in the js folder. A visual program in RoboFlow is composed of nodes (node.js) and edges (edge.js). Adorners (adorner.js, adorners.js) are things that appear when you right-click on a node or an edge (currently there's just the 'delete' icon). Selectors (selector.js) are the bounding boxes that appear when a node is clicked. Options (OptionSet.js) appear when a node is double-clicked. Plugs (plug.js) are the filled circles that function as output of a node. Sockets (socket.js) are the unfilled circles that function as input of a node. For validation and execution of a program, the graph (graph.js) is abstracted from the program.

Backend

To get a list of saved Manipulations/Locations/Head Steps/Saved Procedures, to check preconditions and to execute steps, the frontend calls various services (the exception is the execution of Saved Procedures, which is not actually supported yet, but is very easy to do: see Issue). The service to get the list of Saved Procedures is in this repository (see directories nodes, launch, srv), the other services are in their respective repositories: Manipulation and Head Step is in pr2_pbd_app, Location is in rws_pr2_navigation.

What works

  • Creating/editing programs
  • Saving/loading programs (Note: editing loaded programs and re-saving them sometimes results in a bug (see Issue)
  • Executing programs that only have head steps

What doesn't

  • Executing programs with manipulation steps (Issue)
  • Executing programs with saved procedures (Issue)
  • Executing programs with navigation (actually, this should work, it's just not tested)
  • Setting object similarity threshold (Issue)