【Complex op】add complex support for sin, cos, tan, tanh#55380
Merged
luotao1 merged 9 commits intoJul 28, 2023
Merged
Conversation
|
你的PR提交成功,感谢你对开源项目的贡献! |
GGBond8488
reviewed
Jul 18, 2023
|
|
||
|
|
||
| class TestTanh_Complex64(TestTanh): | ||
| def init_dytpe(self): |
Contributor
There was a problem hiding this comment.
只是改变dtype,似乎input只有实部,没有虚部(虚部都为0)
GGBond8488
reviewed
Jul 25, 2023
| if self.dtype == np.float16: | ||
| return | ||
| self.check_grad(['X'], 'Out', check_prim=True) | ||
| # TODO(ScottWong98): set `check_prim=False` when `fill_any_like` supports `complex` dtype |
Contributor
There was a problem hiding this comment.
这里加个分支判断,只有complex类型的才设置check_prim=False,还有maxrelative等,不要影响正常的单测
Contributor
Author
|
@luotao1 麻烦涛姐帮我 review 一下 |
luotao1
approved these changes
Jul 28, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR types
New features
PR changes
OPs
Description
add complex support for
sin,cos,tan,tanh.