add gradient test framework (#3226)
* init grad op checker * can run * add GradeChecker class * use get_numeric_gradient * refine code * add softmax and cross entropy auto grad test * use close to judge op_grad and numeric_grad * add cpu and gpu compare * add comments * add support_gpu * fix allclose * fix name error and symplify code * optimize gradient checker * add test_cross_entropy_op * update gradient_checker.py * optimize code * use random.uniform instead of random.random * fix type bug * optimize check_grad * put SupportGPU into OperatorBase * typo
Showing
想要评论请 注册 或 登录