No module named torch.fx (torch 1.7.0)

i have this error > no module named torch.fx

i cant import torch.fx

torch properties:

  • torch 1.7.0

in first, i install torch 1.8.0 but when i have “RuntimeError: cuDNN error: CUDNN_STATUS_NOT_INITIALIZED - PyTorch” error, i install torch 1.7.0 then it solved. I read something like that: “torch.fx comes with torch 1.8.0” but i cant upgrade because of “RuntimeError: cuDNN error: CUDNN_STATUS_NOT_INITIALIZED - PyTorch” error.

how can i solve “torch.fx” error?

Hi @aysekonus, which version of JetPack-L4T are you running? You can check your L4T version with cat /etc/nv_tegra_release

Are you using the PyTorch wheels from this thread? https://forums.developer.nvidia.com/t/pytorch-for-jetson-version-1-10-now-available/72048

Have you tried testing the l4t-pytorch containers to see if you also have the issue there? https://catalog.ngc.nvidia.com/orgs/nvidia/containers/l4t-pytorch

L4T version is 4.4

and yes, i am using PyTorch 1.7.0 wheel from that thread.

also, i have not tried testing the l4t-pytorch containers. what is that for and how can i do

1 Like

You may want to try upgrading to a more recent version of JetPack or re-flashing your device to see if that fixes the issue.

The containers come with the components pre-installed and can help discern if it’s a PyTorch install issue on your side, or if it is something with your device setup (i.e. cuDNN). You can pick one of the container tags that matches your L4T version and follow the instructions on this page to run it: https://catalog.ngc.nvidia.com/orgs/nvidia/containers/l4t-pytorch

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.