EXP_Class::EXP_Class( const char *run_name, bool _evolution, bool _viewing, bool _re_evaluation, unsigned long _seed ){
  int output_nodes;
  evolution     = _evolution;
  viewing       = _viewing;
  re_evaluation = _re_evaluation;
  
  param     = new Parameters ( run_name );
  if( evolution ) param->set_random_root_seed( _seed );
  param->init_random_generator( );

// cout << "Initialising local variables" << endl;
  init_local_variables();
  //image_path=new string[param->nets[0]->get_num_output()];
}
Exemplo n.º 2
0
int Init(void *_ctx) {
	ctx = _ctx;

	switch(ctrl_init()) {
	case -1:
		return -1;
	case 0:
		return 0;
	}

	init_memory();

	ctrl_in = NULL;
	if (!init_ctrl_input(ctx)) {
		return 0;
	}

	nof_output_data_itf = 0;
	param_get_int_name("nof_output_data_itf",&nof_output_data_itf);

	if (init_remote_variables(ctx) == -1) {
		return -1;
	}

	nof_remote_itf = scan_remote_itf(ctx,nof_remote_variables);
	if (nof_remote_itf == -1) {
		return -1;
	}

	nof_local_variables = init_local_variables(ctx);
	if (nof_local_variables == -1) {
		return -1;
	}

	if (init_remote_itf(ctx,nof_remote_itf)) {
		return -1;
	}

	return 1;
}