You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
======================================================================
FAIL: test_0dim_inplace_add (__main__.TestAddModule)
----------------------------------------------------------------------
assert (
AssertionError: Check graph failed: graph result [[1.392592 1.2263045 1.4627435]
[1.3013713 1.7706606 1.7302301]] not equals to eager result [[0.788282 0.6219945 0.8584335]
[0.6970614 1.1663506 1.12592 ]].
合并lixiang 的#7276 分支(解决inplace op 跑graph 测试参数deepcopy的分支Fix_autotest_inplace_bug)再跑测试还是会报错,报错信息:
Traceback (most recent call last):
File "/home/fengdaochao/fdz/oneflow/python/oneflow/test_utils/automated_test_util/torch_flow_dual_object.py", line 757, in new_f
res = f(test_case)
File "/home/fengdaochao/fdz/oneflow/python/oneflow/test/modules/test_add.py", line 180, in test_0dim_inplace_add
x += y.mean()
File "/home/fengdaochao/fdz/oneflow/python/oneflow/test_utils/automated_test_util/torch_flow_dual_object.py", line 500, in dual_method
check_eager_graph_tensor(oneflow_res, test_g_res)
File "/home/fengdaochao/fdz/oneflow/python/oneflow/test_utils/automated_test_util/torch_flow_dual_object.py", line 232, in check_eager_graph_tensor
assert (
AssertionError: Check graph failed: graph result [[1.8136338 1.1563476 0.9524027 ]
[1.8796235 0.99145484 1.845683 ]] not equals to eager result [[1.3421042 0.684818 0.4808731 ]
[1.4080939 0.51992524 1.3741534 ]].
背景信息
将test_add.py中的test_0dim_inplace_add(test_case) 打开check_graph=True ,再跑test_add.py报错,报错信息如下:
合并lixiang 的#7276 分支(解决inplace op 跑graph 测试参数deepcopy的分支Fix_autotest_inplace_bug)再跑测试还是会报错,报错信息:
在oneflow下做了测试eager 和graph的结果是不对齐的
输出结果:
x : tensor([[ 0.3299, -0.2933, 0.3413], [-2.1822, 0.5900, -0.3539]], dtype=oneflow.float32) y: tensor([[-0.1691, -0.9497, 1.6760], [-0.4748, -0.7713, -2.3149]], dtype=oneflow.float32) eager, 非inplace ------------------------------------- tensor([[ 0.1608, -1.2430, 2.0173], [-2.6569, -0.1812, -2.6687]], dtype=oneflow.float32) eager, inplace ------------------------------------- tensor([[ 0.1608, -1.2430, 2.0173], [-2.6569, -0.1812, -2.6687]], dtype=oneflow.float32) graph, inplace ------------------------------------- tensor([[-0.0082, -2.1926, 3.6933], [-3.1317, -0.9525, -4.9836]], dtype=oneflow.float32)
@strint
The text was updated successfully, but these errors were encountered: