def test_trunk_angles(): ret = _nf.trunk_angles(SIMPLE_TRUNK) assert_array_equal(ret, [np.pi/2, np.pi/2, np.pi/2, np.pi/2]) ret = _nf.trunk_angles(SIMPLE_TRUNK, neurite_type=NeuriteType.basal_dendrite) assert_array_equal(ret, [np.pi, np.pi]) ret = _nf.trunk_angles(SIMPLE_TRUNK, neurite_type=NeuriteType.axon) assert_array_equal(ret, [0.0]) ret = _nf.trunk_angles(SIMPLE, neurite_type=NeuriteType.apical_dendrite) nt.eq_(ret, [])