Skip to content
Snippets Groups Projects
Unverified Commit 43d5ce05 authored by Sam Yates's avatar Sam Yates Committed by GitHub
Browse files

Add exception for cross-group GJ error. (#686)

parent 2dc9520e
No related branches found
No related tags found
No related merge requests found
......@@ -26,11 +26,16 @@ bad_probe_id::bad_probe_id(cell_member_type probe_id):
probe_id(probe_id)
{}
gj_unsupported_domain_decomposition::gj_unsupported_domain_decomposition(cell_gid_type gid_0, cell_gid_type gid_1):
arbor_exception(pprintf("No support for gap junctions across domain decomposition groups for gid {} and {}", gid_0, gid_1)),
gid_0(gid_0),
gid_1(gid_1)
{}
gj_kind_mismatch::gj_kind_mismatch(cell_gid_type gid_0, cell_gid_type gid_1):
arbor_exception(pprintf("Cells on gid {} and {} connected via gap junction have different cell kinds", gid_0, gid_1)),
gid_0(gid_0),
gid_1(gid_1)
arbor_exception(pprintf("Cells on gid {} and {} connected via gap junction have different cell kinds", gid_0, gid_1)),
gid_0(gid_0),
gid_1(gid_1)
{}
bad_event_time::bad_event_time(time_type event_time, time_type sim_time):
......
......@@ -50,6 +50,13 @@ struct gj_kind_mismatch: arbor_exception {
cell_gid_type gid_0, gid_1;
};
// Domain decomposition errors:
struct gj_unsupported_domain_decomposition: arbor_exception {
gj_unsupported_domain_decomposition(cell_gid_type gid_0, cell_gid_type gid_1);
cell_gid_type gid_0, gid_1;
};
// Simulation errors:
struct bad_event_time: arbor_exception {
......
......@@ -90,8 +90,7 @@ void mc_cell_group::generate_deps_gids(const recipe& rec, std::vector<cell_gid_t
throw bad_cell_description(cell_kind::cable1d_neuron, g);
if (!gid_to_loc.count(peer)) {
// actually an error in the domain decomposition...
throw bad_cell_description(cell_kind::cable1d_neuron, g);
throw gj_unsupported_domain_decomposition(g, peer);
}
if (!visited.count(peer)) {
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment