コード例 #1
0
ファイル: test_feature_compat.py プロジェクト: markovg/NeuroM
    def test_get_remote_bifurcation_angles(self):
        _close(_nrt.remote_bifurcation_angles(self.sec_nrn),
               get('remote_bifurcation_angles', self.ref_nrn))

        for t in NeuriteType:
            _close(_nrt.remote_bifurcation_angles(self.sec_nrn, neurite_type=t),
                   get('remote_bifurcation_angles', self.ref_nrn, neurite_type=t))

        ba = [_bf.remote_bifurcation_angle(b)
              for b in i_chain2(self.sec_nrn_trees, iterator_type=Section.ibifurcation_point)]

        _close(ba, get('remote_bifurcation_angles', self.ref_nrn))
コード例 #2
0
def test_remote_bifurcation_angles():
    ref_remote_bifangles = list(nf.remote_bifurcation_angles(NEURON))
    remote_bifangles = get_feature('remote_bifurcation_angles', NEURON)
    nt.eq_(len(remote_bifangles), 40)
    assert_allclose(remote_bifangles, ref_remote_bifangles)
    remote_bifangles = get_feature('remote_bifurcation_angles',
                                   NEURON,
                                   neurite_type=NeuriteType.all)
    nt.eq_(len(remote_bifangles), 40)
    assert_allclose(remote_bifangles, ref_remote_bifangles)

    s = get_feature('remote_bifurcation_angles',
                    NEURON,
                    neurite_type=NeuriteType.axon)
    nt.eq_(len(s), 10)

    s = get_feature('remote_bifurcation_angles',
                    NEURON,
                    neurite_type=NeuriteType.basal_dendrite)
    nt.eq_(len(s), 20)

    s = get_feature('remote_bifurcation_angles',
                    NEURON,
                    neurite_type=NeuriteType.apical_dendrite)
    nt.eq_(len(s), 10)
コード例 #3
0
ファイル: test_get_features.py プロジェクト: markovg/NeuroM
def test_remote_bifurcation_angles():
    ref_remote_bifangles = list(nf.remote_bifurcation_angles(NEURON))
    remote_bifangles = get_feature('remote_bifurcation_angles', NEURON)
    assert len(remote_bifangles) == 40
    assert_allclose(remote_bifangles, ref_remote_bifangles)
    remote_bifangles = get_feature('remote_bifurcation_angles',
                                   NEURON,
                                   neurite_type=NeuriteType.all)
    assert len(remote_bifangles) == 40
    assert_allclose(remote_bifangles, ref_remote_bifangles)

    s = get_feature('remote_bifurcation_angles',
                    NEURON,
                    neurite_type=NeuriteType.axon)
    assert len(s) == 10

    s = get_feature('remote_bifurcation_angles',
                    NEURON,
                    neurite_type=NeuriteType.basal_dendrite)
    assert len(s) == 20

    s = get_feature('remote_bifurcation_angles',
                    NEURON,
                    neurite_type=NeuriteType.apical_dendrite)
    assert len(s) == 10
コード例 #4
0
ファイル: test_neuritefunc.py プロジェクト: joewgraham/NeuroM
def test_remote_bifurcation_angles():
    remote_bif_angles = list(_nf.remote_bifurcation_angles(SIMPLE))
    assert_allclose(remote_bif_angles, (pi, pi))