test_rotate_utils.py 文件源码

python
阅读 21 收藏 0 点赞 0 评论 0

项目:pytomo3d 作者: computational-seismology 项目源码 文件源码
def test_rotate_12_ne():

    d1 = np.array([1.0, 0.0])
    d2 = np.array([0.0, 1.0])

    n, e = rotate.rotate_12_ne(d1, d2, 30, 120)

    n_true = np.array([np.sqrt(3)/2.0, -0.5])
    e_true = np.array([0.5, np.sqrt(3)/2.0])
    npt.assert_allclose(n, n_true)
    npt.assert_allclose(e, e_true)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号