Genetic Programming in C# [closed]

2019-01-16 01:35发布

I've been looking for some good genetic programming examples for C#. Anyone knows of good online/book resources? Wonder if there is a C# library out there for Evolutionary/Genetic programming?

13条回答
Juvenile、少年°
2楼-- · 2019-01-16 02:20

I maintain a port of ECJ in C#. It's great.

查看更多
倾城 Initia
3楼-- · 2019-01-16 02:21

If you're interested in genetic algorithms or heuristic optimization in general you might want to take a look at HeuristicLab. It is developed for several years, 1.5 years since we released the new version. It is programmed in C# 4 and has a nice GUI. There are many algorithms already available like Genetic Algorithm, Genetic Programming, Evolution Strategy, Local Search, Tabu Search, Particle Swarm Optimization, Simulated Annealing and more. There are also several problems implemented like a vehicle routing problem, traveling salesman, real function optimization, knapsack, quadratic assignment problem, classification, regression, and many more. There are tutorials also and we have protocol buffers integrated so you can communicate with external programs for solution evaluation. It is licensed under GPL. In 2009 the software has received the Microsoft innovation award of Microsoft Austria.

We've also written a book on the subject: Genetic Algorithms and Genetic Programming.

查看更多
太酷不给撩
4楼-- · 2019-01-16 02:24

Do you mean actual genetic programming, as opposed to genetic algorithms in general?

If so, C#/.net isn't the best language for it. LISP, for example, has always been a mainstay of GP.

However, if you must, you're probably going to want to dynamically generate CIL / MSIL. You could do this using System.Reflection.Emit, however I'd recommend Mono.Cecil. It lacks good docs (as if reflection emit has them).. But it offers much better assembly emission and reflection.

Another issue is that it is less than trivial to load code, and later dispose of it, in the .net framework. At least, you cannot unload assemblies. You can unload appdomains, but the whole business of loading code into a seperate appdomain, and calling it externally can get pretty messy. .NET 3.5's System.Addin stuff should make this easier.

查看更多
迷人小祖宗
5楼-- · 2019-01-16 02:25

I have a free product that may help. The Genetic Algorithm Framework .Net 4.0 is a single .Net 4.0 assembly with some supporting articles.

查看更多
手持菜刀,她持情操
6楼-- · 2019-01-16 02:29

MSDN had an article last year about genetic programming: Genetic Algorithms: Survival of the Fittest with Windows Forms

查看更多
beautiful°
7楼-- · 2019-01-16 02:29

I've forked ECJ to C# .NET 4.0 if you are interested in a full-featured Evolutionary Computation framework. The package includes everything from the original ECJ Java project, including all of the working samples.

I also wrote 500 unit tests to verify many aspects of the conversion. But many more tests are needed. In particular, the distributed computation aspects are not fully tested. That's because I plan on converting from ECJ's simple use of sockets to a more robust strategy using WCF and WF. I'll also be reworking the framework to utilize TPL (Task Parallel Library).

Anyway, you can download the initial conversion here:

http://branecloud.codeplex.com

I am also in the process of converting several other frameworks from Java to .NET that relate to "synthetic intelligence" research (when I can find the time).

Ben

查看更多
登录 后发表回答