From: Nikos Dimitrakopoulos Date: 2008-03-31T10:37:56+09:00 Subject: Re: Google Summer of Code proposal: GRuVeR: A General Ruby James Gray wrote: > As a person who served as a mentor for the last two years all I can > say is that I wish most of the proposals I saw were half this good. ;) > > It's clear you've put in a lot of thought about your project and you > have a solid plan for making it happen. The mentors that review this > will see that and I believe it will reflect very well on you. > > Good luck with the project! > First of all, really thanks for the wishes and the good comments! Now to the suggestions... :) > > Please understand this is not a complaint, but as I was reading > through the proposal, I found myself wondering about using constraint > processing in addition to genetic algorithms. I'm just mentioning > that here so you can factor it into your thinking. I'm not saying you > should toss your genetic algorithm idea, but it might be a bonus if > the system you develop could easily have the planned Charlie-based > integration swapped out for a Gecode/R backend (assuming someone was > willing to write it, of course): > > http://gecoder.rubyforge.org/ The truth is that even though I have heard of constraint programming, I had never really see what exactly it is. After reading some examples on the geocode/r site I must confess I found it at least interesting (if not exciting :) ). It has a same, basic idea in common with GA: describe your problem (somehow) or a way to find a solution and let the computer do the hard work for you :) It's really amazing actually! So, after some really quick thinking, I believe that it could be used *in conjunction* with the genetic algorithms at least in the first place. For example, most of the RVP problems have some constraints that have to be taken into account. So, what a better way to enforce these constraints than using constraint programming (this could even rhyme) :D You could for example use it to find some initial valid population that would evolve afterwards. Of course this doesn't means that the next generation would be valid but it is important anyway to have *some* good starting population to base upon the evolution that will take place. I don't know if this is feasible (and in what extent) but I believe that there must be some research work that we could use. If not, then we'll have to "brainstorm" a little more... :D I don't have the time today (or this week) to do it, but it's on the to-do list definitely. As for a complete swapping it is probably already in my thoughts. When I say "extensible" in the proposal I mean exactly this! That it would be nice to build the system (specifically mainly the public methods) in a way that is really unrelated to the backend (aka the inner parts/implementations of the library). This way when i want to solve the X problem i should call XProblem.new(some_data).solve and the XProblem should know which is the most efficient way to be solved if no further details are given by the user. The decision for this could be based on the kind of the problem and some characteristics of the data given (for example the number of the stops for a simple Traveling Salesman Problem). In the case where a user wants to explicitly define some parameters an imaginary example (for the sake of explaining my thoughts) could be: XProblem.new :data => some_data, :method => super_experimental_genetic_algorithm, :method_params => .. Something similar could be used regarding the data input/output. [note: mentor's support/experience will be really helpful regarding this certain aspect of the project] > > Disclaimer: I mentored the Gecode/R project last year and thus am > obviously biased in this matter. > > Anyway, this is just an idea I wanted to share. As I said the project looks really interesting and taken care of :) Kudos! I will probably play with it this week :) > > The project is pretty specialized, so it may not touch those of us in > the community not working directly in that area. However, I feel that > expanding Ruby into new frontiers like this definitely benefits us all. > I want to believe the same but only time can tell ;) Thanks a lot again for the feedback and the ideas. Cheers! -Nikos P.S.: /me is really tired - going to get some sleep before I update the proposal... :D -- Posted via http://www.ruby-forum.com/.