devosoft / quorum-orgs-for-empirical Goto Github PK
View Code? Open in Web Editor NEWA module for Empirical that implements QuorumOrgs
A module for Empirical that implements QuorumOrgs
We need to factor out the additions we made to these files and use inheritance to pull in the base versions, add the quorum-specific code and keep on truckin'.
travis doesn't ssh and the sed trick does nothing useful
time to fix ltierally everything ever
recommend using sed in base dir so catch is cloned via https (shouldn't ever need to use ssh for it anyway)
[anyaejo@dev-intel16 quorum-orgs-for-Empirical]$ make all
g++ -Wall -Wno-unused-function -std=c++11 -O3 -I../Empirical/ standard-grid-quorum.cc -o standard-grid-quorum.out
In file included from ../Empirical/evo/StatsManager.h:14:0,
from standard-grid-quorum.cc:9:
../Empirical/evo/PopulationManager.h:151:5: error: ‘Signal’ does not name a type
Signalemp::vector<ORG*&> sig_clear;
^
../Empirical/evo/PopulationManager.h:152:5: error: ‘Signal’ does not name a type
Signalemp::vector<ORG*&> sig_update;
^
../Empirical/evo/PopulationManager.h:153:5: error: ‘Signal’ does not name a type
Signalemp::vector<ORG*&, ORG_, int&> sig_add_org; // args: new
^
../Empirical/evo/PopulationManager.h:154:5: error: ‘Signal’ does not name a type
Signal<emp::vector<ORG_>&, ORG_, int, int&> sig_add_org_birth; // args: new
^
../Empirical/evo/PopulationManager.h:166:5: error: ‘LinkKey’ does not name a type
LinkKey OnClear(const std::function<void(emp::vector<ORG_>&)> & fun) {
^
../Empirical/evo/PopulationManager.h:169:5: error: ‘LinkKey’ does not name a type
LinkKey OnUpdate(const std::function<void(emp::vector<ORG*>&)> & fun) {
^
../Empirical/evo/PopulationManager.h:172:5: error: ‘LinkKey’ does not name a type
LinkKey OnAddOrg(const std::function<void(emp::vector<ORG*>&, ORG_, int&)>
^
../Empirical/evo/PopulationManager.h:175:5: error: ‘LinkKey’ does not name a type
LinkKey OnAddOrgBirth(const std::function<void(emp::vector<ORG_>&, ORG_, in
^
../Empirical/evo/PopulationManager.h: In constructor ‘emp::evo::PopulationManager_Plugin<ORG, FIT_MANAGER>::PopulationManager_Plugin(const string&)’:
../Empirical/evo/PopulationManager.h:159:7: error: class ‘emp::evo::PopulationManager_Plugin<ORG, FIT_MANAGER>’ does not have any field named ‘sig_clear’
, sig_clear(to_string(world_name, "::pop_clear"))
^
../Empirical/evo/PopulationManager.h:160:7: error: class ‘emp::evo::PopulationManager_Plugin<ORG, FIT_MANAGER>’ does not have any field named ‘sig_update’
, sig_update(to_string(world_name, "::pop_update"))
^
../Empirical/evo/PopulationManager.h:161:7: error: class ‘emp::evo::PopulationManager_Plugin<ORG, FIT_MANAGER>’ does not have any field named ‘sig_add_org’
, sig_add_org(to_string(world_name, "::pop_add_org"))
^
../Empirical/evo/PopulationManager.h:162:7: error: class ‘emp::evo::PopulationManager_Plugin<ORG, FIT_MANAGER>’ does not have any field named ‘sig_add_org_birt’
, sig_add_org_birth(to_string(world_name, "::pop_add_org_birth"))
^
../Empirical/evo/PopulationManager.h: In member function ‘void emp::evo::PopulationManager_Plugin<ORG, FIT_MANAGER>::Clear()’:
../Empirical/evo/PopulationManager.h:180:11: error: ‘sig_clear’ was not declared in this scope
if (sig_clear.GetNumActions()) sig_clear.Trigger(pop);
^
../Empirical/evo/PopulationManager.h: In member function ‘void emp::evo::PopulationManager_Plugin<ORG, FIT_MANAGER>::Update()’:
../Empirical/evo/PopulationManager.h:183:21: error: ‘sig_update’ was not declared in this scope
void Update() { sig_update.Trigger(pop); }
^
../Empirical/evo/PopulationManager.h: In member function ‘int emp::evo::PopulationManager_Plugin<ORG, FIT_MANAGER>::AddOrg(ORG_)’:
../Empirical/evo/PopulationManager.h:187:7: error: ‘sig_add_org’ was not declared in this scope
sig_add_org.Trigger(pop, new_org, new_pos);
^
../Empirical/evo/PopulationManager.h: In member function ‘int emp::evo::PopulationManager_Plugin<ORG, FIT_MANAGER>::AddOrgBirth(ORG_, int)’:
../Empirical/evo/PopulationManager.h:192:7: error: ‘sig_add_org_birth’ was not declared in this scope
sig_add_org_birth.Trigger(pop, new_org, parent_pos, offspring_pos);
^
In file included from ../Empirical/evo/FitnessManager.h:14:0,
from ../Empirical/evo/World.h:94,
from quorum.cc:20,
from standard-grid-quorum.cc:18:
../Empirical/evo/../tools/WeightedSet.h: In member function ‘emp::WeightedSet& emp::WeightedSet::operator+=(emp::WeightedSet&)’:
../Empirical/evo/../tools/WeightedSet.h:115:26: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (auto i = 0; i < in_set.size(); i++) {
^
../Empirical/evo/../tools/WeightedSet.h: In member function ‘emp::WeightedSet& emp::WeightedSet::operator-=(emp::WeightedSet&)’:
../Empirical/evo/../tools/WeightedSet.h:123:26: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
for (auto i = 0; i < in_set.size(); i++) {
^
In file included from quorum.cc:26:0,
from standard-grid-quorum.cc:18:
QuorumOrg.h: In constructor ‘emp::evo::QuorumOrgGenome::QuorumOrgGenome(double, double, double, int, bool, bool)’:
QuorumOrg.h:36:10: warning: ‘emp::evo::QuorumOrgGenome::quorum_threshold’ will be initialized after [-Wreorder]
double quorum_threshold;
^
QuorumOrg.h:33:18: warning: ‘int emp::evo::QuorumOrgGenome::lineage’ [-Wreorder]
int lineage = -1;
^
QuorumOrg.h:46:3: warning: when initialized here [-Wreorder]
QuorumOrgGenome(double cprob, double airad, double qthresh, int lin, bool cmh
^
QuorumOrg.h:33:18: warning: ‘emp::evo::QuorumOrgGenome::lineage’ will be initialized after [-Wreorder]
int lineage = -1;
^
QuorumOrg.h:29:8: warning: ‘bool emp::evo::QuorumOrgGenome::can_make_HiAI’ [-Wreorder]
bool can_make_HiAI;
^
QuorumOrg.h:46:3: warning: when initialized here [-Wreorder]
QuorumOrgGenome(double cprob, double airad, double qthresh, int lin, bool cmh
^
QuorumOrg.h: In member function ‘unsigned int emp::evo::QuorumOrgState::remove_points(unsigned int)’:
QuorumOrg.h:109:16: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
if (remove <= points) {
^
QuorumOrg.h: In constructor ‘emp::evo::QuorumOrgState::QuorumOrgState(double, double, double, bool, unsigned int, int, bool, bool)’:
QuorumOrg.h:96:8: warning: ‘emp::evo::QuorumOrgState::mutate’ will be initialized after [-Wreorder]
bool mutate; // dunno if we'll want to do this by-org, but eh
^
QuorumOrg.h:89:7: warning: ‘int emp::evo::QuorumOrgState::points’ [-Wreorder]
int points;
^
QuorumOrg.h:124:3: warning: when initialized here [-Wreorder]
QuorumOrgState (double cprob, double aprob, double qthresh, bool mut,
^
QuorumOrg.h: In copy constructor ‘emp::evo::QuorumOrgState::QuorumOrgState(const emp::evo::QuorumOrgState&)’:
QuorumOrg.h:96:8: warning: ‘emp::evo::QuorumOrgState::mutate’ will be initialized after [-Wreorder]
bool mutate; // dunno if we'll want to do this by-org, but eh
^
QuorumOrg.h:89:7: warning: ‘int emp::evo::QuorumOrgState::points’ [-Wreorder]
int points;
^
QuorumOrg.h:135:3: warning: when initialized here [-Wreorder]
QuorumOrgState (const QuorumOrgState & other) : genome(other.genome.co_op_pro
^
QuorumOrg.h:89:7: warning: ‘emp::evo::QuorumOrgState::points’ will be initialized after [-Wreorder]
int points;
^
QuorumOrg.h:88:16: warning: ‘unsigned int emp::evo::QuorumOrgState::age’ [-Wreorder]
unsigned int age;
^
QuorumOrg.h:135:3: warning: when initialized here [-Wreorder]
QuorumOrgState (const QuorumOrgState & other) : genome(other.genome.co_op_pro
^
In file included from quorum.cc:27:0,
from standard-grid-quorum.cc:18:
QuorumManager.h: In member function ‘void emp::evo::QuorumManager<QuorumOrganism, POP_MANAGER>::SpacedSeed(double, int, const emp::evo::QuorumOrgGenome_, bool, double, const emp::evo::QuorumOrgGenome_)’:
QuorumManager.h:81:116: error: there are no arguments to ‘assert’ that depend on a template parameter, so a declaration of ‘assert’ must be available [-fpermissive]
seed != nullptr && "Must have non-null alt-seed when alt-density specified!");}
^
QuorumManager.h:81:116: note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated)
QuorumManager.h: In member function ‘unsigned int emp::evo::QuorumManager<QuorumOrganism, POP_MANAGER>::BottleneckEvent(double)’:
QuorumManager.h:139:5: warning: no return statement in function returning non-void [-Wreturn-type]
}
^
In file included from standard-grid-quorum.cc:18:0:
quorum.cc: At global scope:
quorum.cc:84:13: error: ‘StatsManager_Mapper’ in namespace ‘emp::evo’ does not name a template type
emp::evo::StatsManager_Mapper<QM> * Qmapper;
^
quorum.cc: In function ‘int execute(QuorumRunState<FOUNDATION, FOUNDATION_CONF>&)’:
quorum.cc:312:1: warning: no return statement in function returning non-void [-Wreturn-type]
}
^
standard-grid-quorum.cc: In function ‘int main(int, char__)’:
standard-grid-quorum.cc:32:9: error: ‘struct QuorumRunState<FOUNDATION, QuorumConfigBase>’ has no member named ‘Qmapper’
state.Qmapper = new emp::evo::StatsManager_Mapper<QM>(state.Qpop,
^
standard-grid-quorum.cc:32:33: error: ‘StatsManager_Mapper’ in namespace ‘emp::evo’ does not name a template type
state.Qmapper = new emp::evo::StatsManager_Mapper<QM>(state.Qpop,
^
standard-grid-quorum.cc:32:66: error: expected primary-expression before ‘>’ token
state.Qmapper = new emp::evo::StatsManager_Mapper<QM>(state.Qpop,
^
standard-grid-quorum.cc:32:75: warning: left operand of comma operator has no effect [-Wunused-value]
state.Qmapper = new emp::evo::StatsManager_Mapper<QM>(state.Qpop,
^
In file included from standard-grid-quorum.cc:18:0:
quorum.cc: In instantiation of ‘QuorumRunState<FOUNDATION, FOUNDATION_CONF>::QuorumRunState(FOUNDATION_CONF&, std::cxx11::string&) [with FOUNDATION = FOUNDATION; FOUNDATION_CONF = QuorumConfigBase; std::cxx11::string = std::cxx11::basic_string]’:
standard-grid-quorum.cc:30:76: required from here
quorum.cc:107:5: error: ‘QWorld<emp::evo::QuorumOrganism, FOUNDATION> {aka class emp::evo::World<emp::evo::QuorumOrganism, emp::evo::QuorumManager<emp::evo::QuorumOrganism, FOUNDATION> >}’ has no member named ‘set_available_points’
Qpop->set_available_points(config->AVAILABLE_PRIVATE_PTS());
^
quorum.cc: In instantiation of ‘configure_stats_manager(QuorumRunState<FOUNDATION, FOUNDATION_CONF>&)::<lambda()> [with FOUNDATION = FOUNDATION; FOUNDATION_CONF = QuorumConfigBase]’:
quorum.cc:233:41: required from ‘struct configure_stats_manager(QuorumRunState<FOUNDATION, FOUNDATION_CONF>&) [with FOUNDATION = FOUNDATION; FOUNDATION_CONF = QuorumConfigBase]::<lambda()>’
quorum.cc:235:3: required from ‘void configure_stats_manager(QuorumRunState<FOUNDATION, FOUNDATION_CONF>&) [with FOUNDATION = FOUNDATION; FOUNDATION_CONF = QuorumConfigBase]’
standard-grid-quorum.cc:39:64: required from here
quorum.cc:235:3: error: ‘class emp::evo::World<emp::evo::QuorumOrganism, emp::evo::QuorumManager<emp::evo::QuorumOrganism, FOUNDATION> >’ has no member named ‘get_available_points’
};
^
quorum.cc: In instantiation of ‘void configure_stats_manager(QuorumRunState<FOUNDATION, FOUNDATION_CONF>&) [with FOUNDATION = FOUNDATION; FOUNDATION_CONF = QuorumConfigBase]’:
standard-grid-quorum.cc:39:64: required from here
quorum.cc:235:3: error: conversion from ‘configure_stats_manager(QuorumRunState<FOUNDATION, FOUNDATION_CONF>&) [with FOUNDATION = FOUNDATION; FOUNDATION_CONF = QuorumConfigBase]::<lambda()>’ to non-scalar type ‘std::function<double()>’ requested
In file included from ../Empirical/evo/StatsManager.h:4:0,
from standard-grid-quorum.cc:9:
/opt/software/GCC/5.2/include/c++/6.0.0/functional: In substitution of ‘template<class Functor, class> std::function<Res(ArgTypes ...)>::function(Functor) [with Functor = configure_stats_manager(QuorumRunState<FOUNDATION, FOUNDATION_CONF>&) [with FOUNDATION = FOUNDATION; FOUNDATION_CONF = QuorumConfigBase]::<lambda()>; = ]’:
quorum.cc:245:3: required from ‘void configure_stats_manager(QuorumRunState<FOUNDATION, FOUNDATION_CONF>&) [with FOUNDATION = FOUNDATION; FOUNDATION_CONF = QuorumConfigBase]’
standard-grid-quorum.cc:39:64: required from here
/opt/software/GCC/5.2/include/c++/6.0.0/functional:2057:9: internal compiler error: tree check: expected class ‘type’, have ‘exceptional’ (error_mark) in strip_typedefs, at cp/tree.c:1414
typename = Requires<Callable<Functor>, void>>
^
0xf289c7 tree_class_check_failed(tree_node const, tree_code_class, char const, int, char const)
../../gnu-5.2/gcc/tree.c:9563
0x7bc217 tree_class_check(tree_node, tree_code_class, char const, int, char const)
../../gnu-5.2/gcc/tree.h:2981
0x7bc217 strip_typedefs(tree_node, bool)
../../gnu-5.2/gcc/cp/tree.c:1414
0x6466d0 canonicalize_type_argument
../../gnu-5.2/gcc/cp/pt.c:6886
0x67b700 convert_template_argument
../../gnu-5.2/gcc/cp/pt.c:7157
0x68d51f type_unification_real
../../gnu-5.2/gcc/cp/pt.c:17708
0x699fa9 fn_type_unification(tree_node, tree_node, tree_node, tree_node* const, unsigned int, tree_node, unification_kind_t, int, bool, bool)
../../gnu-5.2/gcc/cp/pt.c:16971
0x603234 add_template_candidate_real
../../gnu-5.2/gcc/cp/call.c:3059
0x603c8c add_template_candidate
../../gnu-5.2/gcc/cp/call.c:3160
0x603c8c add_candidates
../../gnu-5.2/gcc/cp/call.c:5316
0x5ffa3d build_user_type_conversion_1
../../gnu-5.2/gcc/cp/call.c:3671
0x607f40 build_user_type_conversion(tree_node, tree_node_, int, int)
../../gnu-5.2/gcc/cp/call.c:3849
0x75fd3a ocp_convert(tree_node_, tree_node_, int, int, int)
../../gnu-5.2/gcc/cp/cvt.c:880
0x76deb5 expand_default_init
../../gnu-5.2/gcc/cp/init.c:1678
0x76deb5 expand_aggr_init_1
../../gnu-5.2/gcc/cp/init.c:1848
0x76e6c4 build_aggr_init(tree_node_, tree_node_, int, int)
../../gnu-5.2/gcc/cp/init.c:1597
0x6167ec build_aggr_init_full_exprs
../../gnu-5.2/gcc/cp/decl.c:5898
0x6167ec check_initializer
../../gnu-5.2/gcc/cp/decl.c:6042
0x635004 cp_finish_decl(tree_node_, tree_node_, bool, tree_node_, int)
../../gnu-5.2/gcc/cp/decl.c:6714
0x6662d4 tsubst_expr(tree_node_, tree_node_, int, tree_node_, bool)
../../gnu-5.2/gcc/cp/pt.c:14540
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See http://gcc.gnu.org/bugs.html for instructions.
make: *** [standard-grid-quorum] Error 1
Absolutely necessary for this level of refactoring:
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.