triton icon indicating copy to clipboard operation
triton copied to clipboard

Cannot import name 'libdevice' from 'triton.language'

Open mazhaojia123 opened this issue 10 months ago • 4 comments

I try the example from https://triton-lang.org/main/getting-started/tutorials/07-extern-functions.html#. And I get an error as follow.

image

The triton version I use is Triton2.3.0 under the python3.10.

mazhaojia123 avatar Apr 24 '24 03:04 mazhaojia123

Note: This problem seems to be resolved on main (triton-3.0.0)

(I was able to repro this issue on 2.2.0)

alat-rights avatar Apr 24 '24 18:04 alat-rights

Thank you, @alat-rights. I use a nightly build, and it works smoothly.

mazhaojia123 avatar Apr 25 '24 04:04 mazhaojia123

Good to hear.

I think it would be good to write unit tests for all of the tutorial code, so that Triton devs can catch these regressions.

alat-rights avatar Apr 25 '24 07:04 alat-rights

@mazhaojia123 @alat-rights The tutorials code are implicitly tied to the repo node that Triton is built and installed from for that version. I don't think there is any backwards compatibility guarantee. So you can clone a release branch and run that version of the tutorial that matches the Triton release you have installed, or run Triton nightly with tip of main branch or close to it.

fkouteib avatar Apr 25 '24 23:04 fkouteib