[ Home | Docs | News | Resources | Download] |
GAUL Documentation: Porting GAUL applications to version 0.1848 |
Porting Applications from GAUL 0.1847 to 0.1848 A small number of changes in the GAUL API between versions 0.1847 and 0.1848 break backward compatibility. Although most applications will run successfully without changes, some applications will need to be modified. This document describes changes that will need to be made. ga_entity_setup() removed The ga_entity_setup() function was removed from the public API. While it recommended that any existing code relying on this function be rewritten, the following code snippet will presently perform the same task as the original ga_entity_setup() function. It is highly likely that any code to rewritten should be using ga_entity_blank() instead. /* "entity" is an entity_t, that needs to be initialised * and it belongs to the population_t labelled "pop". */ entity->chromosome=NULL; pop->chromosome_constructor(pop, entity); entity->data=NULL; entity->fitness=GA_MIN_FITNESS; Deprecated functions A number of functions are now deprecated, including ga_compare_genome(), ga_count_match_alleles(), ga_genome_hamming_similarity() and ga_genome_euclidian_similarity(). At the present time they may be re-enabled by defining the preprocessor constant COMPILE_DEPRECATED_FUNCTIONS prior to compilation. It is strongly recommended that applications relying on these functions are rewritten to avoid their use. Changed seed behaviour Formerly, the population was seeded with initial solutions within the genesis functions. Now, the evolution functions determine whether seeding is required and perform it. This should not effect any code except that which assumes that entities have been initiallized fully prior to the use of any evolution function. Such code may be fixed by calling ga_population_seed(), as appropriate. |
[ Home | Docs | News | Resources | Download] |
Hosted by: |
© 2005, "Stewart Adcock" <stewart@linux-domain.com> All rights reserved. |
All trademarks on this page are probably owned by their respective companies. You can insert you own favourite disclaimer here. |