Package ec

Examples of ec.BreedingPipeline.produce()


                                                       
                // start breedin'!
                for(int x = from[subpop]; x < from[subpop] + numinds[subpop]; x++)
                    {
                    space.setIndex(threadnum, x);
                    if (bp.produce(1, 1, x, subpop, newpop.subpops[subpop].individuals, state, threadnum) != 1)
                        state.output.fatal( "The pipelines should produce one individual at a time!" );
                    }
                                                                       
                bp.finishProducing(state,subpop,threadnum);
                }
View Full Code Here


                // start breedin'!
                                       
                x=from[subpop];
                int upperbound = from[subpop]+numinds[subpop];
                while(x<upperbound)
                    x += bp.produce(1,upperbound-x,x,subpop,
                        newpop.subpops[subpop].individuals,
                        state,threadnum);
                if (x>upperbound) // uh oh!  Someone blew it!
                    state.output.fatal("Whoa!  A breeding pipeline overwrote the space of another pipeline in subpopulation " + subpop + ".  You need to check your breeding pipeline code (in produce() ).");
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.