kaolin
kaolin copied to clipboard
NameError: name 'Usd' is not defined
kal.io.usd.create_stage(stagename)
---------------------------------------------------------------------------
NameError Traceback (most recent call last)
[<ipython-input-12-43e16bc41c30>](https://localhost:8080/#) in <module>()
1 stagename = './recon_stage5.usd';
----> 2 stage = kal.io.usd.create_stage(stagename)
3 usdmesh = kal.io.usd.add_mesh(stage, '/World/mesh', triverts[0], trifaces[0])
4 stage.Save()
[/content/kaolin/kaolin/io/usd.py](https://localhost:8080/#) in create_stage(file_path, up_axis)
372 """
373 assert os.path.exists(os.path.dirname(file_path)), f'Directory {os.path.dirname(file_path)} not found.'
--> 374 stage = Usd.Stage.CreateNew(str(file_path))
375 world = stage.DefinePrim('/World', 'Xform')
376 stage.SetDefaultPrim(world)
NameError: name 'Usd' is not defined
Hi @MotivaCG !
Did you previously get this warning? https://github.com/NVIDIAGameWorks/kaolin/blob/master/kaolin/io/usd.py#L32
Nope it didn't trigger that warning you can check it on your own https://colab.research.google.com/drive/1m4jRzuQY2sSpjaS2i-pUgKuMsCf16vRU?usp=sharing
Can you try from pxr import Usd
? This is weird because I do see that usd-core
is getting installed during kaolin installation.