You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While running the command, pytest test/test_cpp_api_parity.py -k Loss -v, I am getting the following error:
ImportError while importing test module '/home/ankit_jha/test/pytorch/test/test_cpp_api_parity.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
test/test_cpp_api_parity.py:10: in <module>
import torch
torch/__init__.py:81: in <module>
from torch._C import *
E ImportError: No module named _C
I have build PyTorch in develop mode. I have to push some changes to C++ Frontend. Since, I am new to PyTorch, I am not sure if it's because of my environment or if it is a bug.
OS (e.g., Linux): Ubuntu 18.04
How you installed PyTorch (conda, pip, source): pip
Build command you used (if compiling from source): python setup.py develop
Python version: 3.6
The text was updated successfully, but these errors were encountered:
You could try running the test from another directory, this sometimes happens if there is a file named torch.py or (more likely in this case) a folder named torch/ with an __init__.py inside, then import torch tries to import that directly instead of the installed/symlinked version in your Python's site-packages.
Something might be getting installed incorrectly, the import my_module resolution rules can be found here.
馃悰 Bug
While running the command,
pytest test/test_cpp_api_parity.py -k Loss -v
, I am getting the following error:I have build PyTorch in develop mode. I have to push some changes to C++ Frontend. Since, I am new to PyTorch, I am not sure if it's because of my environment or if it is a bug.
conda
,pip
, source): pipThe text was updated successfully, but these errors were encountered: