Commit 426d8a70 authored by Gauthier Quesnel's avatar Gauthier Quesnel
Browse files

benchmark: remove warnings

parent 65833f2d
Pipeline #17733 passed with stage
in 1 minute and 29 seconds
......@@ -14,7 +14,6 @@
#include <fstream>
using namespace std;
struct file_output
......@@ -54,7 +53,8 @@ file_output_observe(const irt::observer& obs,
fmt::print(output->os, "{},{}\n", t, msg.real[0]);
}
struct neuron {
struct neuron
{
irt::dynamics_id sum;
irt::dynamics_id integrator;
irt::dynamics_id quantifier;
......@@ -63,18 +63,14 @@ struct neuron {
irt::dynamics_id constant_cross;
};
struct neuron
make_neuron(irt::simulation* sim, long unsigned int i, double quantum) noexcept
make_neuron(irt::simulation* sim, double quantum) noexcept
{
using namespace boost::ut;
double tau_lif = 10;
double Vr_lif = 0.0;
double Vt_lif = 10.0;
auto& sum_lif = sim->adder_2_models.alloc();
auto& integrator_lif = sim->integrator_models.alloc();
auto& quantifier_lif = sim->quantifier_models.alloc();
......@@ -82,35 +78,31 @@ make_neuron(irt::simulation* sim, long unsigned int i, double quantum) noexcept
auto& constant_cross_lif = sim->constant_models.alloc();
auto& cross_lif = sim->cross_models.alloc();
sum_lif.default_input_coeffs[0] = -1.0/tau_lif;
sum_lif.default_input_coeffs[1] = 20.0/tau_lif;
sum_lif.default_input_coeffs[0] = -1.0 / tau_lif;
sum_lif.default_input_coeffs[1] = 20.0 / tau_lif;
constant_lif.default_value = 1.0;
constant_cross_lif.default_value = Vr_lif;
integrator_lif.default_current_value = 0.0;
quantifier_lif.default_adapt_state =
irt::quantifier::adapt_state::possible;
quantifier_lif.default_adapt_state = irt::quantifier::adapt_state::possible;
quantifier_lif.default_zero_init_offset = true;
quantifier_lif.default_step_size = quantum;
quantifier_lif.default_past_length = 3;
cross_lif.default_threshold = Vt_lif;
sim->alloc(sum_lif, sim->adder_2_models.get_id(sum_lif));
sim->alloc(integrator_lif, sim->integrator_models.get_id(integrator_lif));
sim->alloc(quantifier_lif, sim->quantifier_models.get_id(quantifier_lif));
sim->alloc(constant_lif, sim->constant_models.get_id(constant_lif));
sim->alloc(cross_lif, sim->cross_models.get_id(cross_lif));
sim->alloc(constant_cross_lif, sim->constant_models.get_id(constant_cross_lif));
sim->alloc(constant_cross_lif,
sim->constant_models.get_id(constant_cross_lif));
struct neuron neuron_model = {sim->adder_2_models.get_id(sum_lif),
struct neuron neuron_model = {
sim->adder_2_models.get_id(sum_lif),
sim->integrator_models.get_id(integrator_lif),
sim->quantifier_models.get_id(quantifier_lif),
sim->constant_models.get_id(constant_lif),
......@@ -118,7 +110,6 @@ make_neuron(irt::simulation* sim, long unsigned int i, double quantum) noexcept
sim->constant_models.get_id(constant_cross_lif),
};
// Connections
expect(sim->connect(quantifier_lif.y[0], integrator_lif.x[0]) ==
irt::status::success);
......@@ -128,36 +119,32 @@ make_neuron(irt::simulation* sim, long unsigned int i, double quantum) noexcept
irt::status::success);
expect(sim->connect(cross_lif.y[0], quantifier_lif.x[0]) ==
irt::status::success);
expect(sim->connect(cross_lif.y[0], sum_lif.x[0]) ==
irt::status::success);
expect(sim->connect(integrator_lif.y[0],cross_lif.x[0]) ==
expect(sim->connect(cross_lif.y[0], sum_lif.x[0]) == irt::status::success);
expect(sim->connect(integrator_lif.y[0], cross_lif.x[0]) ==
irt::status::success);
expect(sim->connect(integrator_lif.y[0],cross_lif.x[2]) ==
expect(sim->connect(integrator_lif.y[0], cross_lif.x[2]) ==
irt::status::success);
expect(sim->connect(constant_cross_lif.y[0],cross_lif.x[1]) ==
expect(sim->connect(constant_cross_lif.y[0], cross_lif.x[1]) ==
irt::status::success);
expect(sim->connect(constant_lif.y[0], sum_lif.x[1]) ==
irt::status::success);
return neuron_model;
}
void lif_benchmark(double simulation_duration, double quantum)
void
lif_benchmark(double simulation_duration, double quantum)
{
using namespace boost::ut;
irt::simulation sim;
expect(irt::is_success(sim.init(2600lu, 40000lu)));
struct neuron neuron_model = make_neuron(&sim,0,quantum);
struct neuron neuron_model = make_neuron(&sim, quantum);
irt::time t = 0.0;
std::string file_name = "output_lif_aqss_sd_"+
std::to_string(simulation_duration)+
"_q_"+std::to_string(quantum)+
".csv";
std::string file_name = "output_lif_aqss_sd_" +
std::to_string(simulation_duration) + "_q_" +
std::to_string(quantum) + ".csv";
file_output fo_a(file_name.c_str());
expect(fo_a.os != nullptr);
......@@ -167,7 +154,9 @@ void lif_benchmark(double simulation_duration, double quantum)
&file_output_initialize,
&file_output_observe,
nullptr);
sim.observe(sim.models.get(sim.qss2_integrator_models.get(neuron_model.integrator).id), obs_a);
sim.observe(sim.models.get(
sim.qss2_integrator_models.get(neuron_model.integrator).id),
obs_a);
expect(irt::status::success == sim.initialize(t));
......@@ -178,7 +167,15 @@ void lif_benchmark(double simulation_duration, double quantum)
} while (t < simulation_duration);
}
void izhikevich_benchmark(double simulation_duration, double quantum, double a, double b, double c, double d, double I, double vini)
void
izhikevich_benchmark(double simulation_duration,
double quantum,
double a,
double b,
double c,
double d,
double I,
double vini)
{
using namespace boost::ut;
irt::simulation sim;
......@@ -218,16 +215,14 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
integrator_a.default_current_value = vini;
quantifier_a.default_adapt_state =
irt::quantifier::adapt_state::possible;
quantifier_a.default_adapt_state = irt::quantifier::adapt_state::possible;
quantifier_a.default_zero_init_offset = true;
quantifier_a.default_step_size = quantum;
quantifier_a.default_past_length = 3;
integrator_b.default_current_value = 0.0;
quantifier_b.default_adapt_state =
irt::quantifier::adapt_state::possible;
quantifier_b.default_adapt_state = irt::quantifier::adapt_state::possible;
quantifier_b.default_zero_init_offset = true;
quantifier_b.default_step_size = quantum;
quantifier_b.default_past_length = 3;
......@@ -251,8 +246,8 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
sim.alloc(constant3, sim.constant_models.get_id(constant3), "tfun")));
!expect(irt::is_success(
sim.alloc(constant, sim.constant_models.get_id(constant), "1.0")));
!expect(irt::is_success(sim.alloc(
constant2, sim.constant_models.get_id(constant2), "-56.0")));
!expect(irt::is_success(
sim.alloc(constant2, sim.constant_models.get_id(constant2), "-56.0")));
!expect(irt::is_success(
sim.alloc(sum_a, sim.adder_2_models.get_id(sum_a), "sum_a")));
......@@ -280,14 +275,11 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
!expect(sim.models.size() == 14_ul);
expect(sim.connect(integrator_a.y[0], cross.x[0]) ==
irt::status::success);
expect(sim.connect(integrator_a.y[0], cross.x[0]) == irt::status::success);
expect(sim.connect(constant2.y[0], cross.x[1]) == irt::status::success);
expect(sim.connect(integrator_a.y[0], cross.x[2]) ==
irt::status::success);
expect(sim.connect(integrator_a.y[0], cross.x[2]) == irt::status::success);
expect(sim.connect(cross.y[0], quantifier_a.x[0]) ==
irt::status::success);
expect(sim.connect(cross.y[0], quantifier_a.x[0]) == irt::status::success);
expect(sim.connect(cross.y[0], product.x[0]) == irt::status::success);
expect(sim.connect(cross.y[0], product.x[1]) == irt::status::success);
expect(sim.connect(product.y[0], sum_c.x[0]) == irt::status::success);
......@@ -298,43 +290,31 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
expect(sim.connect(constant3.y[0], sum_c.x[3]) == irt::status::success);
expect(sim.connect(sum_c.y[0], sum_a.x[0]) == irt::status::success);
expect(sim.connect(integrator_b.y[0], sum_a.x[1]) ==
irt::status::success);
expect(sim.connect(integrator_b.y[0], sum_a.x[1]) == irt::status::success);
expect(sim.connect(cross2.y[0], sum_a.x[1]) == irt::status::success);
expect(sim.connect(sum_a.y[0], integrator_a.x[1]) ==
irt::status::success);
expect(sim.connect(cross.y[0], integrator_a.x[2]) ==
irt::status::success);
expect(sim.connect(sum_a.y[0], integrator_a.x[1]) == irt::status::success);
expect(sim.connect(cross.y[0], integrator_a.x[2]) == irt::status::success);
expect(sim.connect(quantifier_a.y[0], integrator_a.x[0]) ==
irt::status::success);
expect(sim.connect(cross2.y[0], quantifier_b.x[0]) ==
irt::status::success);
expect(sim.connect(cross2.y[0], quantifier_b.x[0]) == irt::status::success);
expect(sim.connect(cross2.y[0], sum_b.x[0]) == irt::status::success);
expect(sim.connect(quantifier_b.y[0], integrator_b.x[0]) ==
irt::status::success);
expect(sim.connect(sum_b.y[0], integrator_b.x[1]) ==
irt::status::success);
expect(sim.connect(sum_b.y[0], integrator_b.x[1]) == irt::status::success);
expect(sim.connect(cross2.y[0], integrator_b.x[2]) ==
irt::status::success);
expect(sim.connect(integrator_a.y[0], cross2.x[0]) ==
irt::status::success);
expect(sim.connect(integrator_b.y[0], cross2.x[2]) ==
irt::status::success);
expect(sim.connect(cross2.y[0], integrator_b.x[2]) == irt::status::success);
expect(sim.connect(integrator_a.y[0], cross2.x[0]) == irt::status::success);
expect(sim.connect(integrator_b.y[0], cross2.x[2]) == irt::status::success);
expect(sim.connect(sum_d.y[0], cross2.x[1]) == irt::status::success);
expect(sim.connect(integrator_b.y[0], sum_d.x[0]) ==
irt::status::success);
expect(sim.connect(integrator_b.y[0], sum_d.x[0]) == irt::status::success);
expect(sim.connect(constant.y[0], sum_d.x[1]) == irt::status::success);
std::string file_name = "output_izhikevitch_aqss_a_sd_"+
std::to_string(simulation_duration)+
"_q_"+std::to_string(quantum)+
"_a_"+std::to_string(a)+
"_b_"+std::to_string(b)+
"_c_"+std::to_string(c)+
"_d_"+std::to_string(d)+
".csv";
std::string file_name =
"output_izhikevitch_aqss_a_sd_" + std::to_string(simulation_duration) +
"_q_" + std::to_string(quantum) + "_a_" + std::to_string(a) + "_b_" +
std::to_string(b) + "_c_" + std::to_string(c) + "_d_" +
std::to_string(d) + ".csv";
file_output fo_a(file_name.c_str());
expect(fo_a.os != nullptr);
......@@ -344,14 +324,11 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
&file_output_initialize,
&file_output_observe,
nullptr);
file_name = "output_izhikevitch_aqss_b_sd_"+
std::to_string(simulation_duration)+
"_q_"+std::to_string(quantum)+
"_a_"+std::to_string(a)+
"_b_"+std::to_string(b)+
"_c_"+std::to_string(c)+
"_d_"+std::to_string(d)+
".csv";
file_name = "output_izhikevitch_aqss_b_sd_" +
std::to_string(simulation_duration) + "_q_" +
std::to_string(quantum) + "_a_" + std::to_string(a) + "_b_" +
std::to_string(b) + "_c_" + std::to_string(c) + "_d_" +
std::to_string(d) + ".csv";
file_output fo_b(file_name.c_str());
expect(fo_b.os != nullptr);
auto& obs_b = sim.observers.alloc(0.01,
......@@ -374,32 +351,59 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
expect(st == irt::status::success);
} while (t < simulation_duration);
};
BENCHMARK_P(LIF, AQSS, 10, 1,( double simulation_duration, double quantum))
BENCHMARK_P(LIF, AQSS, 10, 1, (double simulation_duration, double quantum))
{
lif_benchmark(simulation_duration,quantum);
lif_benchmark(simulation_duration, quantum);
}
BENCHMARK_P(Izhikevich, AQSS, 1, 1,( double simulation_duration, double quantum, double a, double b, double c, double d, double I, double vini))
BENCHMARK_P(Izhikevich,
AQSS,
1,
1,
(double simulation_duration,
double quantum,
double a,
double b,
double c,
double d,
double I,
double vini))
{
izhikevich_benchmark(simulation_duration,quantum,a,b,c,d,I,vini);
izhikevich_benchmark(simulation_duration, quantum, a, b, c, d, I, vini);
}
BENCHMARK_P_INSTANCE(LIF, AQSS, (1000,1e-2));
BENCHMARK_P_INSTANCE(LIF, AQSS, (1000, 1e-2));
// Regular spiking (RS)
BENCHMARK_P_INSTANCE(Izhikevich, AQSS, (1000,1e-2,0.02,0.2,-65.0,8.0,10.0,0.0));
BENCHMARK_P_INSTANCE(Izhikevich,
AQSS,
(1000, 1e-2, 0.02, 0.2, -65.0, 8.0, 10.0, 0.0));
// Intrinsical bursting (IB)
BENCHMARK_P_INSTANCE(Izhikevich, AQSS, (1000,1e-2,0.02,0.2,-55.0,4.0,10.0,0.0));
BENCHMARK_P_INSTANCE(Izhikevich,
AQSS,
(1000, 1e-2, 0.02, 0.2, -55.0, 4.0, 10.0, 0.0));
// Chattering spiking (CH)
BENCHMARK_P_INSTANCE(Izhikevich, AQSS, (1000,1e-2,0.02,0.2,-50.0,2.0,10.0,0.0));
BENCHMARK_P_INSTANCE(Izhikevich,
AQSS,
(1000, 1e-2, 0.02, 0.2, -50.0, 2.0, 10.0, 0.0));
// Fast spiking (FS)
BENCHMARK_P_INSTANCE(Izhikevich, AQSS, (1000,1e-2,0.1,0.2,-65.0,2.0,10.0,0.0));
BENCHMARK_P_INSTANCE(Izhikevich,
AQSS,
(1000, 1e-2, 0.1, 0.2, -65.0, 2.0, 10.0, 0.0));
// Thalamo-Cortical (TC)
BENCHMARK_P_INSTANCE(Izhikevich, AQSS, (1000,1e-2,0.02,0.25,-65.0,0.05,10.0,-87.0));
BENCHMARK_P_INSTANCE(Izhikevich,
AQSS,
(1000, 1e-2, 0.02, 0.25, -65.0, 0.05, 10.0, -87.0));
// Rezonator (RZ)
BENCHMARK_P_INSTANCE(Izhikevich, AQSS, (1000,1e-2,0.1,0.26,-65.0,2.0,10.0,-63.0));
BENCHMARK_P_INSTANCE(Izhikevich,
AQSS,
(1000, 1e-2, 0.1, 0.26, -65.0, 2.0, 10.0, -63.0));
// Low-threshold spiking (LTS)
BENCHMARK_P_INSTANCE(Izhikevich, AQSS, (1000,1e-2,0.02,0.25,-65.0,2.0,10.0,-63.0));
BENCHMARK_P_INSTANCE(Izhikevich,
AQSS,
(1000, 1e-2, 0.02, 0.25, -65.0, 2.0, 10.0, -63.0));
// Problematic (P)
BENCHMARK_P_INSTANCE(Izhikevich, AQSS, (1000,1e-2,0.2,2,-56.0,-16.0,-99.0,0.0));
BENCHMARK_P_INSTANCE(Izhikevich,
AQSS,
(1000, 1e-2, 0.2, 2, -56.0, -16.0, -99.0, 0.0));
int
main()
......@@ -408,7 +412,4 @@ main()
hayai::Benchmarker::AddOutputter(consoleOutputter);
hayai::Benchmarker::RunAllTests();
}
......@@ -14,7 +14,6 @@
#include <fstream>
using namespace std;
struct file_output
......@@ -54,8 +53,8 @@ file_output_observe(const irt::observer& obs,
fmt::print(output->os, "{},{}\n", t, msg.real[0]);
}
struct neuron {
struct neuron
{
irt::dynamics_id sum;
irt::dynamics_id integrator;
irt::dynamics_id constant;
......@@ -63,9 +62,8 @@ struct neuron {
irt::dynamics_id constant_cross;
};
struct neuron
make_neuron(irt::simulation* sim, long unsigned int i, double quantum) noexcept
make_neuron(irt::simulation* sim, double quantum) noexcept
{
using namespace boost::ut;
double tau_lif = 10.0;
......@@ -73,18 +71,14 @@ make_neuron(irt::simulation* sim, long unsigned int i, double quantum) noexcept
double Vt_lif = 10.0;
double V0 = 20.0;
auto& sum_lif = sim->qss1_wsum_2_models.alloc();
auto& integrator_lif = sim->qss1_integrator_models.alloc();
auto& constant_lif = sim->constant_models.alloc();
auto& constant_cross_lif = sim->constant_models.alloc();
auto& cross_lif = sim->qss1_cross_models.alloc();
sum_lif.default_input_coeffs[0] = -1.0/tau_lif;
sum_lif.default_input_coeffs[1] = V0/tau_lif;
sum_lif.default_input_coeffs[0] = -1.0 / tau_lif;
sum_lif.default_input_coeffs[1] = V0 / tau_lif;
constant_lif.default_value = 1.0;
constant_cross_lif.default_value = Vr_lif;
......@@ -94,33 +88,31 @@ make_neuron(irt::simulation* sim, long unsigned int i, double quantum) noexcept
cross_lif.default_threshold = Vt_lif;
sim->alloc(sum_lif, sim->qss1_wsum_2_models.get_id(sum_lif));
sim->alloc(integrator_lif, sim->qss1_integrator_models.get_id(integrator_lif));
sim->alloc(integrator_lif,
sim->qss1_integrator_models.get_id(integrator_lif));
sim->alloc(constant_lif, sim->constant_models.get_id(constant_lif));
sim->alloc(cross_lif, sim->qss1_cross_models.get_id(cross_lif));
sim->alloc(constant_cross_lif, sim->constant_models.get_id(constant_cross_lif));
sim->alloc(constant_cross_lif,
sim->constant_models.get_id(constant_cross_lif));
struct neuron neuron_model = {sim->qss1_wsum_2_models.get_id(sum_lif),
struct neuron neuron_model = {
sim->qss1_wsum_2_models.get_id(sum_lif),
sim->qss1_integrator_models.get_id(integrator_lif),
sim->constant_models.get_id(constant_lif),
sim->qss1_cross_models.get_id(cross_lif),
sim->constant_models.get_id(constant_cross_lif),
};
// Connections
expect(sim->connect(cross_lif.y[0], integrator_lif.x[1]) ==
irt::status::success);
expect(sim->connect(cross_lif.y[1], sum_lif.x[0]) ==
irt::status::success);
expect(sim->connect(integrator_lif.y[0],cross_lif.x[0]) ==
expect(sim->connect(cross_lif.y[1], sum_lif.x[0]) == irt::status::success);
expect(sim->connect(integrator_lif.y[0], cross_lif.x[0]) ==
irt::status::success);
expect(sim->connect(integrator_lif.y[0],cross_lif.x[2]) ==
expect(sim->connect(integrator_lif.y[0], cross_lif.x[2]) ==
irt::status::success);
expect(sim->connect(constant_cross_lif.y[0],cross_lif.x[1]) ==
expect(sim->connect(constant_cross_lif.y[0], cross_lif.x[1]) ==
irt::status::success);
expect(sim->connect(constant_lif.y[0], sum_lif.x[1]) ==
irt::status::success);
......@@ -129,22 +121,20 @@ make_neuron(irt::simulation* sim, long unsigned int i, double quantum) noexcept
return neuron_model;
}
void lif_benchmark(double simulation_duration, double quantum)
void
lif_benchmark(double simulation_duration, double quantum)
{
using namespace boost::ut;
irt::simulation sim;
expect(irt::is_success(sim.init(2600lu, 40000lu)));
struct neuron neuron_model = make_neuron(&sim,0,quantum);
struct neuron neuron_model = make_neuron(&sim, quantum);
irt::time t = 0.0;
std::string file_name = "output_lif_qss1_sd_"+
std::to_string(simulation_duration)+
"_q_"+std::to_string(quantum)+
".csv";
std::string file_name = "output_lif_qss1_sd_" +
std::to_string(simulation_duration) + "_q_" +
std::to_string(quantum) + ".csv";
file_output fo_a(file_name.c_str());
expect(fo_a.os != nullptr);
......@@ -154,7 +144,9 @@ void lif_benchmark(double simulation_duration, double quantum)
&file_output_initialize,
&file_output_observe,
nullptr);
sim.observe(sim.models.get(sim.qss1_integrator_models.get(neuron_model.integrator).id), obs_a);
sim.observe(sim.models.get(
sim.qss1_integrator_models.get(neuron_model.integrator).id),
obs_a);
expect(irt::status::success == sim.initialize(t));
......@@ -165,7 +157,16 @@ void lif_benchmark(double simulation_duration, double quantum)
} while (t < simulation_duration);
}
void izhikevich_benchmark(double simulation_duration, double quantum, double a, double b, double c, double d, double I, double vini)
void
izhikevich_benchmark(double simulation_duration,
double quantum,
double a,
double b,
double c,
double d,
double I,
double vini)
{
using namespace boost::ut;
irt::simulation sim;
......@@ -183,7 +184,6 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
auto& cross = sim.qss1_cross_models.alloc();
auto& cross2 = sim.qss1_cross_models.alloc();
double vt = 30.0;
constant.default_value = 1.0;
......@@ -210,7 +210,6 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
sum_d.default_input_coeffs[0] = 1.0;
sum_d.default_input_coeffs[1] = d;
sim.alloc(constant3, sim.constant_models.get_id(constant3));
sim.alloc(constant, sim.constant_models.get_id(constant));
sim.alloc(constant2, sim.constant_models.get_id(constant2));
......@@ -224,12 +223,9 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
sim.alloc(cross, sim.qss1_cross_models.get_id(cross));
sim.alloc(cross2, sim.qss1_cross_models.get_id(cross2));
expect(sim.connect(integrator_a.y[0], cross.x[0]) ==
irt::status::success);
expect(sim.connect(integrator_a.y[0], cross.x[0]) == irt::status::success);
expect(sim.connect(constant2.y[0], cross.x[1]) == irt::status::success);
expect(sim.connect(integrator_a.y[0], cross.x[2]) ==
irt::status::success);
expect(sim.connect(integrator_a.y[0], cross.x[2]) == irt::status::success);
expect(sim.connect(cross.y[1], product.x[0]) == irt::status::success);
expect(sim.connect(cross.y[1], product.x[1]) == irt::status::success);
......@@ -244,36 +240,24 @@ void izhikevich_benchmark(double simulation_duration, double quantum, double a,
// expect(sim.connect(integrator_b.y[0], sum_a.x[1]) ==
// irt::status::success);
expect(sim.connect(cross2.y[1], sum_a.x[1]) == irt::status::success);
expect(sim.connect(sum_a.y[0], integrator_a.x[0]) ==
irt::status::success);
expect(sim.connect(cross.y[0], integrator_a.x[1]) ==
irt::status::success);
expect(sim.connect(sum_a.y[0], integrator_a.x[0]) == irt::status::success);
expect(sim.connect(cross.y[0], integrator_a.x[1]) == irt::status::success);
expect(sim.connect(cross2.y[1], sum_b.x[0]) == irt::status::success);
expect(sim.connect(sum_b.y[0], integrator_b.x[0]) ==
irt::status::success);
expect(sim.connect(sum_b.y[0], integrator_b.x[0]) == irt::status::success);
expect(sim.connect(cross2.y[0], integrator_b.x[1]) ==
irt::status::success);
expect(sim.connect(integrator_a.y[0], cross2.x[0]) ==
irt::status::success);
expect(sim.connect(integrator_b.y[0], cross2.x[2]) ==
irt::status::success);
expect(sim.connect(cross2.y[0], integrator_b.x[1]) == irt::status::success);
expect(sim.connect(integrator_a.y[0], cross2.x[0]) == irt::status::success);
expect(sim.connect(integrator_b.y[0], cross2.x[2]) == irt::status::success);
expect(sim.connect(sum_d.y[0], cross2.x[1]) == irt::status::success);
expect(sim.connect(integrator_b.y[0], sum_d.x[0]) ==
irt::status::success);
expect(sim.connect(integrator_b.y[0], sum_d.x[0]) == irt::status::success);
expect(sim.connect(constant.y[0], sum_d.x[1]) == irt::status::success);