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

TypeError in limit_dims_to_max method of Kernel.py #3953

Open
JoeruCodes opened this issue Mar 27, 2024 · 1 comment
Open

TypeError in limit_dims_to_max method of Kernel.py #3953

JoeruCodes opened this issue Mar 27, 2024 · 1 comment

Comments

@JoeruCodes
Copy link

JoeruCodes commented Mar 27, 2024

The lambda function of reshape_and_permute expects a lambda function which takes in a List[sint] as input. But the lambda function here takes x as input which is then used as an input for limit_size method which expects a List[int]

self.reshape_and_permute(lambda x: self._limit_size(x, tmp + [math.inf] * (len(self.full_shape)-len(tmp))), None)

When I looked into the implementation of reshape_and_permute method, this lambda function is given a List[sint] as input from the shape method of shapetracker

image

@JoeruCodes
Copy link
Author

changing x: Tuple[int] to x: Tuple[sint] or an assertion should do the job...

def _limit_size(self, x: Tuple[int], max_size: List[Union[int,float]]) -> Tuple[int, ...]:

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

No branches or pull requests

1 participant