Re: Fixed. Next Q :)

[email protected] Fri, 23 Jul 2004 15:28:42 -0400
Newsgroups gmane.comp.graphics.fluidiom
Message-ID <[email protected]>
Gerald,

Yet, I will DEFINETLY be sharing my code. As as scientist nothing 
drives me more crazy than seeing a paper on someones implementation 
and then not being able to see the implementation itself. Often times 
they wont share the code with you anyways!

Before continuing, maybe I should be a little more explicit about what 
my system is like. I have attached a small jpg about what I envisioned 
as a a simple example of a creature. Cells connected by springs, 
forming a snake like shape.

The system I have grows cells within a 3d lattice. The system begins 
with a single cell and gene regulation controls the division of cells, 
the outgrowth of the neurons, cell death etc. What I am then left with 
is a morphology complete with a neural network. The resulting neural 
network is not trained so much as it is evolved. That said, it should 
be possible to incorporate growth within the physics engine at some 
point and therefore learning can begin during growth.

Anyways, once the morphology and the neural network are specified the 
idea is then to take it and place it in the physics envirnment to 
animate it. The simplest evolutionary strategy is to get it moving. 
Later when I get more computing power I will look to extend this by 
having creatures compete in some kind of game (See Karl Sims early 
work).

I agree with the boxes but I am not sure I see an easy solution to it. 
The 3d triangular coordinates seem problematic for this 
implementation. As for setting the cells as intervals, that is 
actuallt a great idea but with a box like shape there is still the 
problem that intervals need to occur on the diagonals.

For me, the easiest thing to do is to get a better understanding of te 
code by getting a HelloWorld example going where I can create a simple 
box, apply gravity to it, and evolve a small nn to appy forces to get 
it bouncing around.

Right now I am having serious problems getting the physics on. The 
Floor seems to be in place and from stepping through the code with a 
debugger I see that I am jumping into the mover portion and it seems 
to be appling gravitational forces on the joints but it still just 
hovers in mid air.

A second thing I found strange was that when I changed the position of 
the z axis (using x,z,y coridnate system) from -2 (which is is in the 
last example I send) to -3, it fliped the entire box upside down (?). 
Whereas before the lower joint was streatch out in the distance, 
changing the joing to -3 made top joint steach out. Changing it to -5 
really made it look stange.

Gerald: Any help I could get from you on this would be GREATLY 
appreciated. I am definetly one for academic honesty and so if you are 
interested you would definetly be incuded on the publication.

Thanks,
RDL









Quoting Gerald de Jong <[email protected]>:

> On Friday 23 July 2004 07:18, [email protected] wrote:
> > I seem to have "fixed" the problem of the plane not showing up by
> > moving the objects farther in the distance. It is visible then.
> 
> that would happen automatically if the whole thing was being animated
> like in 
> the main application.
> 
> > That said I am still having trouble turning on the physics
> manually. I
> > have set all the flags but I must have to fire an event somewhere.
> The
> > code seems to be very event driven and seems to be very coupled to
> a
> > GUI driven interface to control state and behaviour.
> 
> i disagree.  the fabric code is completely unaware of any GUI
> whatsoever.  in 
> fact, when i do the evolution, i do so with no GUI, and the fabric
> runs 
> lightning fast "in the dark".
> 
> the JOGL code is tied together with GUI because, well, it is GUI. 
> controlling 
> it is all done with Swing stuff.
> 
> > As well, it seems to "contort" stangely when it first starts before
> it
> > sets into its resting position. am pretty sure I positioned
> everything
> > correctly. I am wondering if there is some default values I forgot
> to
> > set on the intervals created in the MyFabricFactory.
> 
> i'm still having trouble figuring out what it is you want to create. 
> if you 
> want a cube, just write the XML in a ".fabric" file and load it up! 
> much 
> easier than re-coding the GUI.
> 
> > Again I am submitting my "HelloWorld" example if anyone wants to
> look
> > over this and offer suggestions. I am trying to get some bare
> bones
> > code to understand the essential components, how to drive how to
> drive
> > behaviour, and understand the realtionships between the.
> Hopefully
> > this will touch on all the essentials without having to navigate
> > through the GUI portion.
> 
> the essentials are in the "fabric", "factory", "sphere" and "visitor"
> 
> packages.  the rest is GUI.
> 
> > As well, I am still interested in displaying spheres on each
> vertex.
> 
> that's very easy, because as you have seen, spheres are already done.
>   you'd 
> only have to adjust the method:
> 
> private void decorate(Joint theJoint) 
> 
> in JoglFabric.java
> 
> it could be made switchable in the GUI.  i personally find the
> vertexes far 
> less interesting than the intervals.  why do you want to display
> spheres?
> 
> > My plan is to extend the engine Gerald has built and integrate it
> with
> > my own code which develops the morphology and neural networks of
> > virtual creatures.
> 
> now you're talkin`!
> 
> > Each sphere then will represent an individual cell. 
> 
> why not take intervals to be cells?  think different.
> 
> > The idea is that the evolved neural networks will then take control
> of
> > certian elastics which will act like muscles. The others which are
> not
> > controled by actuator neurons will simply be there to stabalize
> the
> > shape and give it a defined, low energy morphology.
> 
> sounds not unlike what i've been doing, although i've avoided NN. 
> how do you 
> expect to _train_ the networks.
> 
> > Again, two files below. I am avoiding anything fancy so you should
> be
> > able to just add them to a directory in the fluidiom package and
> > execute
> 
> maybe you should take a closer look at the existing code that gets
> everything 
> rolling.  just copy it and strip out whatever's irrelevant to what
> you want 
> to do.
> 
> better yet, think of a way to integrate your work using visitors and
> something 
> like the MuscleActivator that makes the creatures run.  there's an
> advantage 
> to trying to fit it in rather than rebuild the frontend.   i'm sure
> there 
> will be a way to do build more plugin-style, because the visitors can
> travel 
> anywhere they please.
> 
> PS.  i presume that you will also share your code, GPL?
> 
> -- 
> Gerald de Jong
> Beautiful Code BV
> Rotterdam, NL
> 
> 
> -------------------------------------------------------
> This SF.Net email is sponsored by BEA Weblogic Workshop
> FREE Java Enterprise J2EE developer tools!
> Get your free copy of BEA WebLogic Workshop 8.1 today.
> http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
> _______________________________________________
> Fluidiom-code mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/fluidiom-code
> 


========================
Rob Leclerc
Yale University
email: [email protected]
email: [email protected]
webpage: www.cpsc.ucalgary.ca/~leclerc
========================
clip_image002.jpg (image/pjpeg, 17.3 KB) - not displayed