smc77 / rlglue Goto Github PK
View Code? Open in Web Editor NEWR package for RL-Glue
License: Other
R package for RL-Glue
License: Other
Define agent interface for RL-Glue
Need to test the final implementation of the network connection, particularly the encoding of data.
Need to implement the task specification, as defined on http://glue.rl-community.org/wiki/Task_Spec.
We should be able to open up a socket connection and write strings as in the following example.
From one command window, start rl_glue.
Start a python session and run:
import socket
sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
sock.connect(("127.0.0.1", 4096))
sock.sendall('\x00\x00\x00\x01\x00\x00\x00\x00')
Then in RL-Glue you should see:
$ rl_glue
RL-Glue Version 3.04, Build 909
RL-Glue is listening for connections on port=4096
RL-Glue :: Experiment connected.
The equivalent in R doesn't work.
sock <- socketConnection(host="127.0.0.1", port=4096)
write('\\x00\\x00\\x00\\x01\\x00\\x00\\x00\\x00', sock)
close(sock)
RL-Glue defines a set of abstract types, such as actions and observations.
RL-Glue uses C structures for data. So in python, they use the struct module to convert the output: https://docs.python.org/2/library/struct.html.
As an example, '10' becomes: '\x00\x00\x00\x01\x00\x00\x00\x00'
import struct
struct.pack("!i", 1) + struct.pack("!i", 0)
I'm not sure how to do the equivalent in R.
Need to provide an interface for running experiments.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.