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

DaCe does not warn on excess arguments to dace.program #1263

Closed
computablee opened this issue May 25, 2023 · 1 comment · Fixed by #1283
Closed

DaCe does not warn on excess arguments to dace.program #1263

computablee opened this issue May 25, 2023 · 1 comment · Fixed by #1283

Comments

@computablee
Copy link
Contributor

Describe the bug
When passing more arguments to a function annotated with @dace.program, DaCe fails to warn the user.

To Reproduce
Steps to reproduce the behavior:

import dace

IMGDIM = dace.symbol('IMGDIM')

@dace.program
def imgcpy(img1: dace.float64[IMGDIM, IMGDIM], img2: dace.float64[IMGDIM, IMGDIM], coefficient: dace.float64):
    img1[:, :] = img2[:, :] * coefficient

imgcpy([[1, 2], [3, 4]], [[4, 3], [2, 1]], 0.0, 1.0)

Full output:

user@linux:~/Temp/dace$ python3 bug_reproducer.py 
WARNING: Casting list argument "img1" to ndarray
WARNING: Casting list argument "img2" to ndarray

Expected behavior
A notice that more arguments are being passed to imgcpy than imgcpy accepts.

Desktop (please complete the following information):

  • OS: Linux Mint 21.1 "Vera"
  • DaCe Version: 0.14.2
@tbennun
Copy link
Collaborator

tbennun commented Jun 28, 2023

Fixed in #1283

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants