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

API change in Episode 4: Build End to End Models #9

Closed
billishyahao opened this issue Feb 28, 2023 · 1 comment
Closed

API change in Episode 4: Build End to End Models #9

billishyahao opened this issue Feb 28, 2023 · 1 comment

Comments

@billishyahao
Copy link

I am trying to run code block in jupyter notebook.
But it seems I encounter API mismatch issue.

@R.function
    def main(x: R.Tensor((1, 784), "float32"), 
             w0: R.Tensor((128, 784), "float32"), 
             b0: R.Tensor((128,), "float32"), 
             w1: R.Tensor((10, 128), "float32"), 
             b1: R.Tensor((10,), "float32")):
        with R.dataflow():
            lv0 = R.call_tir(linear0, (x, w0, b0), (1, 128), dtype="float32")
            lv1 = R.call_tir(relu0, (lv0,), (1, 128), dtype="float32")
            out = R.call_tir(linear1, (lv1, w1, b1), (1, 10), dtype="float32")
            R.output(out)
        return out

TypeError: got an unexpected keyword argument 'dtype'
Given that relax is under development, please help correct this API call.

@billishyahao
Copy link
Author

duplicate with #8

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