mdabros / SharpLearning

Machine learning for C# .Net
MIT License
383 stars 84 forks source link

Add support for Reinforcement Learning algorithms: QLearning, Sarsa etc. #98

Open jameschch opened 5 years ago

jameschch commented 5 years ago

There is currently support for most of the common (and some less common) ML algorithms in Sharp Learning. However, there does appear to be a lack in the area of Reinforcement Leaning and some might observe these algorithms are beginning to gain some traction.

If there is any appetite for extending into this area, I would propose as an initial baseline provision for QLearning and Sarsa, backed by Epsilon Greedy and Boltzmann approaches. A second stage could then continue with Thompson and UCB1 exploration, and finally the existing Neural Net and ensemble interfaces could probably produce a compound that resembled Deep Q Networks.

mdabros commented 5 years ago

Hi @jameschch,

Reinforcement learning is without doubt an extremely interesting field, with a lot of focus these days. It is also a field I am interested in learning more about, and it could be great to add some methods to SharpLearning. My approach would probably be to start with updating the Neural Net library. The current implementation defenitely needs an overhaul to make it more flexible for new problem types, and also to have it support GPU processing. My current hope is that the TorchSharp project could be used as a backend once it matures a bit more. After that, I would start looking into reinforcement learning algorithms based on neural nets, and continue from there. Since this is a sparetime project, reaching a reinforcement milestone is probably not in the near future though :-).

best regards Mads

jameschch commented 5 years ago

Yes I have no doubt you have your hands full with just concentrating on Neural Nets. It's refreshing using your library as it's terse and to the point. For RL I have been taking a very close look at Burlap which is quite broad-based and continuing to evolve. I find it's much simpler to bridge the gap from C# to Java than to Python.

mdabros commented 5 years ago

@jameschch I am glad you find SharpLearning terse and to the point, and thanks for the link to Burlap. It looks like a good source for inspiration.