Working with RLPark source code

RLPark source code is available on github and can be downloaded using git with the following command:
git clone git://github.com/rlpark/rlpark.git

RLPark is composed of different Eclipse projects, here is a description of the most important ones:
  • rlpark.plugin.apache: Apache Math library
  • rlpark.plugin.opencv: Javacv library, the Java Interface to OpenCV and other libraries
  • rlpark.plugin.rltoys: the reinforcement learning library
  • rlpark.plugin.rltoysview: visualization code of rltoys data structures for Zephyr
  • rlpark.plugin.robot: Java abstraction for robot interaction
  • rlpark.example.demos: main demos of rltoys algorithms

To import these projects in Eclipse:
  1. Install Zephyr plugins in Eclipse (see Download Eclipse Plugins on the Zephyr Download page)
  2. Import RLPark projects by going to File->Import...->Existing Projects into Workspace
  3. Select RLPark projects download with the git command above and follow the instructions

Coding Conventions in RLPark

RLPark source code formatting conventions are close to Java built-in conventions in Eclipse (and identical to Zephyr conventions). These conventions are available on the code conventions for the Java programming language. In the project properties of rlpark.plugin.rltoys, they can be seen in: Java Code Style->Formatter. The few points specific to RLPark are:
  • Name of constants are in mixed case with the first letter of each internal word capitalized: ThisIsAConstant, as opposed to all upper case.
  • Access methods should be prefixed by get only when a copy is returned by the method:
    class A {
     private B b;
     
     B b() {
       return b;
     }
      
     B getB() {
       return b != null ? b.copy() : null;
     } 
    }
    
Note that, when working in RLPark projects, Eclipse should reformat automatically your code with respect to RLPark conventions everytime you save your file.

Documentation