Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Dy2St] skip compare between func and module attribute to fix NumPy 1.25 error #55482

Merged
merged 2 commits into from
Jul 18, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
clean code
  • Loading branch information
SigureMo committed Jul 17, 2023
commit e0888a8992462dd5c74c36c04ebaf560947d24e7
5 changes: 1 addition & 4 deletions python/paddle/jit/dy2static/convert_call_func.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,10 +121,7 @@ def is_unsupported(func):
for v in m.__dict__.values():
if not callable(v):
continue
func_in_dict = func == v
if isinstance(func_in_dict, (list, numpy.ndarray)):
func_in_dict = numpy.array(func_in_dict).any()
if func_in_dict:
if func is v:
translator_logger.log(
2,
"Whitelist: {} is part of built-in module and does not have to be transformed.".format(
Expand Down