diff --git a/bluepyopt/ephys/morphologies.py b/bluepyopt/ephys/morphologies.py index 27a6d5d4..9acd7dda 100644 --- a/bluepyopt/ephys/morphologies.py +++ b/bluepyopt/ephys/morphologies.py @@ -307,6 +307,8 @@ def load(morpho_filename, replace_axon): morpho = arbor.load_component(morpho_filename).component elif morpho_suffix == '.swc': morpho = arbor.load_swc_arbor(morpho_filename) + # turn loaded_morphology into morphology type + morpho = arbor.morphology(morpho.segment_tree) elif morpho_suffix == '.asc': morpho = arbor.load_asc(morpho_filename).morphology else: diff --git a/bluepyopt/ephys/templates/acc/decor_acc_template.jinja2 b/bluepyopt/ephys/templates/acc/decor_acc_template.jinja2 index 13ae43d1..ad2dbfe7 100644 --- a/bluepyopt/ephys/templates/acc/decor_acc_template.jinja2 +++ b/bluepyopt/ephys/templates/acc/decor_acc_template.jinja2 @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (decor {%- for mech, params in global_mechs.items() %} {%- if mech is not none %} diff --git a/bluepyopt/ephys/templates/acc/label_dict_acc_template.jinja2 b/bluepyopt/ephys/templates/acc/label_dict_acc_template.jinja2 index 508c0aa1..ca2e7dac 100644 --- a/bluepyopt/ephys/templates/acc/label_dict_acc_template.jinja2 +++ b/bluepyopt/ephys/templates/acc/label_dict_acc_template.jinja2 @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (label-dict {%- for loc, label in label_dict.items() %} {{ label.defn }} diff --git a/bluepyopt/tests/test_ephys/test_create_acc.py b/bluepyopt/tests/test_ephys/test_create_acc.py index baae6def..c1088596 100644 --- a/bluepyopt/tests/test_ephys/test_create_acc.py +++ b/bluepyopt/tests/test_ephys/test_create_acc.py @@ -537,7 +537,7 @@ def run_short_sim(cable_cell): arb_cell_model.properties.catalogue.extend(arbor.bbp_catalogue(), "BBP::") # Run a very short simulation to test mechanism instantiation - arb_cell_model.run(tfinal=0.1) + arb_cell_model.run(tfinal=0.1 *arbor.units.ms) @pytest.mark.unit diff --git a/bluepyopt/tests/test_ephys/testdata/acc/CCell/CCell_decor.acc b/bluepyopt/tests/test_ephys/testdata/acc/CCell/CCell_decor.acc index dd9c47e9..c1820f01 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/CCell/CCell_decor.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/CCell/CCell_decor.acc @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (decor (default (gSKv3_1bar_SKv3_1 65)) (paint (region "soma") (gSKv3_1bar_SKv3_1 65)) diff --git a/bluepyopt/tests/test_ephys/testdata/acc/CCell/CCell_label_dict.acc b/bluepyopt/tests/test_ephys/testdata/acc/CCell/CCell_label_dict.acc index 08c4efd5..2fcd0172 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/CCell/CCell_label_dict.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/CCell/CCell_label_dict.acc @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (label-dict (region-def "all" (all)) (region-def "apic" (tag 4)) diff --git a/bluepyopt/tests/test_ephys/testdata/acc/CCell/simple_axon_replacement.acc b/bluepyopt/tests/test_ephys/testdata/acc/CCell/simple_axon_replacement.acc index 7dee06c1..b5df598b 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/CCell/simple_axon_replacement.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/CCell/simple_axon_replacement.acc @@ -1,6 +1,6 @@ (arbor-component (meta-data - (version "0.1-dev")) + (version "0.9-dev")) (morphology (branch 0 -1 (segment 0 diff --git a/bluepyopt/tests/test_ephys/testdata/acc/expsyn/simple_cell_decor.acc b/bluepyopt/tests/test_ephys/testdata/acc/expsyn/simple_cell_decor.acc index ff1e8f1b..335b4ff1 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/expsyn/simple_cell_decor.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/expsyn/simple_cell_decor.acc @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (decor (paint (region "soma") (membrane-capacitance 0.01)) (paint (region "soma") (density (mechanism "default::pas"))) diff --git a/bluepyopt/tests/test_ephys/testdata/acc/expsyn/simple_cell_label_dict.acc b/bluepyopt/tests/test_ephys/testdata/acc/expsyn/simple_cell_label_dict.acc index fe69d135..ab69054e 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/expsyn/simple_cell_label_dict.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/expsyn/simple_cell_label_dict.acc @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (label-dict (region-def "all" (all)) (region-def "soma" (tag 1)) diff --git a/bluepyopt/tests/test_ephys/testdata/acc/l5pc/C060114A7_axon_replacement.acc b/bluepyopt/tests/test_ephys/testdata/acc/l5pc/C060114A7_axon_replacement.acc index 1723e930..e9f03844 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/l5pc/C060114A7_axon_replacement.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/l5pc/C060114A7_axon_replacement.acc @@ -1,6 +1,6 @@ (arbor-component (meta-data - (version "0.1-dev")) + (version "0.9-dev")) (morphology (branch 0 -1 (segment 0 diff --git a/bluepyopt/tests/test_ephys/testdata/acc/l5pc/C060114A7_modified.acc b/bluepyopt/tests/test_ephys/testdata/acc/l5pc/C060114A7_modified.acc index d47f3c7d..26451178 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/l5pc/C060114A7_modified.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/l5pc/C060114A7_modified.acc @@ -1,6 +1,6 @@ (arbor-component (meta-data - (version "0.1-dev")) + (version "0.9-dev")) (morphology (branch 0 -1 (segment 0 diff --git a/bluepyopt/tests/test_ephys/testdata/acc/l5pc/l5pc_decor.acc b/bluepyopt/tests/test_ephys/testdata/acc/l5pc/l5pc_decor.acc index 9b499549..2a7b5dfb 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/l5pc/l5pc_decor.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/l5pc/l5pc_decor.acc @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (decor (default (membrane-potential -65)) (default (temperature-kelvin 307.14999999999998)) diff --git a/bluepyopt/tests/test_ephys/testdata/acc/l5pc/l5pc_label_dict.acc b/bluepyopt/tests/test_ephys/testdata/acc/l5pc/l5pc_label_dict.acc index ea26ab1a..feec6f79 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/l5pc/l5pc_label_dict.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/l5pc/l5pc_label_dict.acc @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (label-dict (region-def "all" (all)) (region-def "soma" (tag 1)) diff --git a/bluepyopt/tests/test_ephys/testdata/acc/l5pc_py37/l5pc_decor.acc b/bluepyopt/tests/test_ephys/testdata/acc/l5pc_py37/l5pc_decor.acc index 017c701f..ba168a6f 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/l5pc_py37/l5pc_decor.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/l5pc_py37/l5pc_decor.acc @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (decor (default (membrane-potential -65)) (default (temperature-kelvin 307.14999999999998)) diff --git a/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_axon_replacement.acc b/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_axon_replacement.acc index 8b8d954e..5aad006f 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_axon_replacement.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_axon_replacement.acc @@ -1,6 +1,6 @@ (arbor-component (meta-data - (version "0.1-dev")) + (version "0.9-dev")) (morphology (branch 0 -1 (segment 0 diff --git a/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_cell_decor.acc b/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_cell_decor.acc index e5af159c..62686463 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_cell_decor.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_cell_decor.acc @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (decor (paint (region "soma") (membrane-capacitance 0.01)) (paint (region "soma") (density (mechanism "default::hh" ("gnabar" 0.10299326453483033) ("gkbar" 0.027124836082684685)))))) \ No newline at end of file diff --git a/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_cell_label_dict.acc b/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_cell_label_dict.acc index ea26ab1a..feec6f79 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_cell_label_dict.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_cell_label_dict.acc @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (label-dict (region-def "all" (all)) (region-def "soma" (tag 1)) diff --git a/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_modified.acc b/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_modified.acc index 89a99ad3..0e29834f 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_modified.acc +++ b/bluepyopt/tests/test_ephys/testdata/acc/simplecell/simple_modified.acc @@ -1,6 +1,6 @@ (arbor-component (meta-data - (version "0.1-dev")) + (version "0.9-dev")) (morphology (branch 0 -1 (segment 0 diff --git a/bluepyopt/tests/test_ephys/testdata/acc/templates/decor_acc_template.jinja2 b/bluepyopt/tests/test_ephys/testdata/acc/templates/decor_acc_template.jinja2 index b55ca0bc..60d1dc8c 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/templates/decor_acc_template.jinja2 +++ b/bluepyopt/tests/test_ephys/testdata/acc/templates/decor_acc_template.jinja2 @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (meta-data (info "test-decor")) (decor {%- for mech, params in global_mechs.items() %} diff --git a/bluepyopt/tests/test_ephys/testdata/acc/templates/label_dict_acc_template.jinja2 b/bluepyopt/tests/test_ephys/testdata/acc/templates/label_dict_acc_template.jinja2 index c439b12b..e2686dc0 100644 --- a/bluepyopt/tests/test_ephys/testdata/acc/templates/label_dict_acc_template.jinja2 +++ b/bluepyopt/tests/test_ephys/testdata/acc/templates/label_dict_acc_template.jinja2 @@ -1,5 +1,5 @@ (arbor-component - (meta-data (version "0.1-dev")) + (meta-data (version "0.9-dev")) (meta-data (info "test-label-dict")) (label-dict {%- for loc, label in label_dict.items() %}{# this is a comment #}