test_sympy_Lambdify.py 文件源码

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

项目:sym 作者: bjodah 项目源码 文件源码
def test_callback_factory():
    args = x, y = symbols('x y')
    expr = x + atan(y)
    cb = _callback_factory(args, [expr], 'numpy', np.float64, 'C')
    inp = np.array([17, 1])
    ref = 17 + np.arctan(1)
    assert np.allclose(cb(inp), ref)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号