parrt / tensor-sensor

The goal of this library is to generate more helpful exception messages for matrix algebra expressions for numpy, pytorch, jax, tensorflow, keras, fastai.
https://github.com/parrt/tensor-sensor
MIT License
794 stars 40 forks source link

Not available to install #5

Closed rafariva closed 4 years ago

rafariva commented 4 years ago

Hi, i am getting an error when trying to install. I am using windows and tensorflow 2.3.0

C:\WINDOWS\system32>pip install tensor-sensor
Processing c:\users\rafar\appdata\local\pip\cache\wheels\77\93\25\cda0532b890faccb41674971ad0ce0d93618c51c0a86effcd1\tensor_sensor-0.1b1-py3-none-any.whl
Collecting torch
  Using cached torch-0.1.2.post2.tar.gz (128 kB)
Requirement already satisfied: IPython in c:\program files\python37\lib\site-packages (from tensor-sensor) (7.8.0)
Collecting tensorflow
  Using cached tensorflow-2.3.1-cp37-cp37m-win_amd64.whl (342.5 MB)
Requirement already satisfied: graphviz>=0.14.1 in c:\program files\python37\lib\site-packages (from tensor-sensor) (0.14.2)
Requirement already satisfied: matplotlib in c:\program files\python37\lib\site-packages (from tensor-sensor) (3.1.1)
Requirement already satisfied: numpy in c:\program files\python37\lib\site-packages (from tensor-sensor) (1.17.0)
Requirement already satisfied: pyyaml in c:\program files\python37\lib\site-packages\pyyaml-5.1.2-py3.7-win-amd64.egg (from torch->tensor-sensor) (5.1.2)
Requirement already satisfied: pickleshare in c:\program files\python37\lib\site-packages (from IPython->tensor-sensor) (0.7.5)
Requirement already satisfied: backcall in c:\program files\python37\lib\site-packages (from IPython->tensor-sensor) (0.1.0)
Requirement already satisfied: colorama; sys_platform == "win32" in c:\program files\python37\lib\site-packages (from IPython->tensor-sensor) (0.4.1)
Requirement already satisfied: prompt-toolkit<2.1.0,>=2.0.0 in c:\program files\python37\lib\site-packages (from IPython->tensor-sensor) (2.0.9)
Requirement already satisfied: decorator in c:\program files\python37\lib\site-packages (from IPython->tensor-sensor) (4.4.0)
Requirement already satisfied: setuptools>=18.5 in c:\program files\python37\lib\site-packages (from IPython->tensor-sensor) (41.2.0)
Requirement already satisfied: traitlets>=4.2 in c:\program files\python37\lib\site-packages (from IPython->tensor-sensor) (4.3.2)
Requirement already satisfied: jedi>=0.10 in c:\program files\python37\lib\site-packages (from IPython->tensor-sensor) (0.15.1)
Requirement already satisfied: pygments in c:\program files\python37\lib\site-packages (from IPython->tensor-sensor) (2.4.2)
Requirement already satisfied: absl-py>=0.7.0 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (0.7.1)
Requirement already satisfied: gast==0.3.3 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (0.3.3)
Requirement already satisfied: termcolor>=1.1.0 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (1.1.0)
Requirement already satisfied: astunparse==1.6.3 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (1.6.3)
Requirement already satisfied: google-pasta>=0.1.8 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (0.2.0)
Requirement already satisfied: six>=1.12.0 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (1.12.0)
Requirement already satisfied: protobuf>=3.9.2 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (3.13.0)
Requirement already satisfied: wheel>=0.26 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (0.33.6)
Requirement already satisfied: wrapt>=1.11.1 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (1.11.2)
Requirement already satisfied: grpcio>=1.8.6 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (1.23.0)
Collecting tensorflow-estimator<2.4.0,>=2.3.0
  Using cached tensorflow_estimator-2.3.0-py2.py3-none-any.whl (459 kB)
Requirement already satisfied: tensorboard<3,>=2.3.0 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (2.3.0)
Requirement already satisfied: keras-preprocessing<1.2,>=1.1.1 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (1.1.2)
Requirement already satisfied: opt-einsum>=2.3.2 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (3.0.1)
Requirement already satisfied: h5py<2.11.0,>=2.10.0 in c:\program files\python37\lib\site-packages (from tensorflow->tensor-sensor) (2.10.0)
Requirement already satisfied: kiwisolver>=1.0.1 in c:\program files\python37\lib\site-packages (from matplotlib->tensor-sensor) (1.1.0)
Requirement already satisfied: pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 in c:\program files\python37\lib\site-packages (from matplotlib->tensor-sensor) (2.4.2)
Requirement already satisfied: python-dateutil>=2.1 in c:\program files\python37\lib\site-packages (from matplotlib->tensor-sensor) (2.8.0)
Requirement already satisfied: cycler>=0.10 in c:\program files\python37\lib\site-packages (from matplotlib->tensor-sensor) (0.10.0)
Requirement already satisfied: wcwidth in c:\program files\python37\lib\site-packages (from prompt-toolkit<2.1.0,>=2.0.0->IPython->tensor-sensor) (0.1.7)
Requirement already satisfied: ipython-genutils in c:\program files\python37\lib\site-packages (from traitlets>=4.2->IPython->tensor-sensor) (0.2.0)
Requirement already satisfied: parso>=0.5.0 in c:\program files\python37\lib\site-packages (from jedi>=0.10->IPython->tensor-sensor) (0.5.1)
Requirement already satisfied: requests<3,>=2.21.0 in c:\program files\python37\lib\site-packages (from tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (2.22.0)
Requirement already satisfied: google-auth<2,>=1.6.3 in c:\program files\python37\lib\site-packages (from tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (1.21.3)
Requirement already satisfied: markdown>=2.6.8 in c:\program files\python37\lib\site-packages (from tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (3.1.1)
Requirement already satisfied: tensorboard-plugin-wit>=1.6.0 in c:\program files\python37\lib\site-packages (from tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (1.7.0)
Requirement already satisfied: google-auth-oauthlib<0.5,>=0.4.1 in c:\program files\python37\lib\site-packages (from tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (0.4.1)
Requirement already satisfied: werkzeug>=0.11.15 in c:\program files\python37\lib\site-packages (from tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (0.15.5)
Requirement already satisfied: chardet<3.1.0,>=3.0.2 in c:\program files\python37\lib\site-packages (from requests<3,>=2.21.0->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (3.0.4)
Requirement already satisfied: certifi>=2017.4.17 in c:\program files\python37\lib\site-packages (from requests<3,>=2.21.0->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (2019.9.11)
Requirement already satisfied: idna<2.9,>=2.5 in c:\program files\python37\lib\site-packages (from requests<3,>=2.21.0->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (2.8)
Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in c:\program files\python37\lib\site-packages (from requests<3,>=2.21.0->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (1.25.3)
Requirement already satisfied: pyasn1-modules>=0.2.1 in c:\program files\python37\lib\site-packages (from google-auth<2,>=1.6.3->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (0.2.8)
Requirement already satisfied: cachetools<5.0,>=2.0.0 in c:\program files\python37\lib\site-packages (from google-auth<2,>=1.6.3->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (4.1.1)
Requirement already satisfied: rsa<5,>=3.1.4; python_version >= "3.5" in c:\program files\python37\lib\site-packages (from google-auth<2,>=1.6.3->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (4.6)
Requirement already satisfied: requests-oauthlib>=0.7.0 in c:\program files\python37\lib\site-packages (from google-auth-oauthlib<0.5,>=0.4.1->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (1.3.0)
Requirement already satisfied: pyasn1<0.5.0,>=0.4.6 in c:\program files\python37\lib\site-packages (from pyasn1-modules>=0.2.1->google-auth<2,>=1.6.3->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (0.4.8)
Requirement already satisfied: oauthlib>=3.0.0 in c:\program files\python37\lib\site-packages (from requests-oauthlib>=0.7.0->google-auth-oauthlib<0.5,>=0.4.1->tensorboard<3,>=2.3.0->tensorflow->tensor-sensor) (3.1.0)
**Building wheels for collected packages: torch
  Building wheel for torch (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: 'C:\Program Files\Python37\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\rafar\\AppData\\Local\\Temp\\pip-install-xzyrqv53\\torch\\setup.py'"'"'; __file__='"'"'C:\\Users\\rafar\\AppData\\Local\\Temp\\pip-install-xzyrqv53\\torch\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d 'C:\Users\rafar\AppData\Local\Temp\pip-wheel-u8ylwmm7'
       cwd: C:\Users\rafar\AppData\Local\Temp\pip-install-xzyrqv53\torch\
  Complete output (30 lines):
  running bdist_wheel
  running build
  running build_deps
  Traceback (most recent call last):
    File "<string>", line 1, in <module>
    File "C:\Users\rafar\AppData\Local\Temp\pip-install-xzyrqv53\torch\setup.py", line 265, in <module>
      description="Tensors and Dynamic neural networks in Python with strong GPU acceleration",
    File "C:\Program Files\Python37\lib\site-packages\setuptools\__init__.py", line 145, in setup
      return distutils.core.setup(**attrs)
    File "C:\Program Files\Python37\lib\distutils\core.py", line 148, in setup
      dist.run_commands()
    File "C:\Program Files\Python37\lib\distutils\dist.py", line 966, in run_commands
      self.run_command(cmd)
    File "C:\Program Files\Python37\lib\distutils\dist.py", line 985, in run_command
      cmd_obj.run()
    File "C:\Program Files\Python37\lib\site-packages\wheel\bdist_wheel.py", line 192, in run
      self.run_command('build')
    File "C:\Program Files\Python37\lib\distutils\cmd.py", line 313, in run_command
      self.distribution.run_command(command)
    File "C:\Program Files\Python37\lib\distutils\dist.py", line 985, in run_command
      cmd_obj.run()
    File "C:\Program Files\Python37\lib\distutils\command\build.py", line 135, in run
      self.run_command(cmd_name)
    File "C:\Program Files\Python37\lib\distutils\cmd.py", line 313, in run_command
      self.distribution.run_command(command)
    File "C:\Program Files\Python37\lib\distutils\dist.py", line 985, in run_command
      cmd_obj.run()
    File "C:\Users\rafar\AppData\Local\Temp\pip-install-xzyrqv53\torch\setup.py", line 51, in run
      from tools.nnwrap import generate_wrappers as generate_nn_wrappers
  ModuleNotFoundError: No module named 'tools.nnwrap'
  ----------------------------------------
  ERROR: Failed building wheel for torch
  Running setup.py clean for torch
  ERROR: Command errored out with exit status 1:
   command: 'C:\Program Files\Python37\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\rafar\\AppData\\Local\\Temp\\pip-install-xzyrqv53\\torch\\setup.py'"'"'; __file__='"'"'C:\\Users\\rafar\\AppData\\Local\\Temp\\pip-install-xzyrqv53\\torch\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' clean --all
       cwd: C:\Users\rafar\AppData\Local\Temp\pip-install-xzyrqv53\torch
  Complete output (2 lines):
  running clean
  error: [Errno 2] No such file or directory: '.gitignore'
  ----------------------------------------
  ERROR: Failed cleaning build dir for torch
Failed to build torch
Installing collected packages: torch, tensorflow-estimator, tensorflow, tensor-sensor
    Running setup.py install for torch ... error
    ERROR: Command errored out with exit status 1:
     command: 'C:\Program Files\Python37\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\rafar\\AppData\\Local\\Temp\\pip-install-xzyrqv53\\torch\\setup.py'"'"'; __file__='"'"'C:\\Users\\rafar\\AppData\\Local\\Temp\\pip-install-xzyrqv53\\torch\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\rafar\AppData\Local\Temp\pip-record-upwgi7o7\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\Program Files\Python37\Include\torch'
         cwd: C:\Users\rafar\AppData\Local\Temp\pip-install-xzyrqv53\torch\
    Complete output (23 lines):
    running install
    running build_deps
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Users\rafar\AppData\Local\Temp\pip-install-xzyrqv53\torch\setup.py", line 265, in <module>
        description="Tensors and Dynamic neural networks in Python with strong GPU acceleration",
      File "C:\Program Files\Python37\lib\site-packages\setuptools\__init__.py", line 145, in setup
        return distutils.core.setup(**attrs)
      File "C:\Program Files\Python37\lib\distutils\core.py", line 148, in setup
        dist.run_commands()
      File "C:\Program Files\Python37\lib\distutils\dist.py", line 966, in run_commands
        self.run_command(cmd)
      File "C:\Program Files\Python37\lib\distutils\dist.py", line 985, in run_command
        cmd_obj.run()
      File "C:\Users\rafar\AppData\Local\Temp\pip-install-xzyrqv53\torch\setup.py", line 99, in run
        self.run_command('build_deps')
      File "C:\Program Files\Python37\lib\distutils\cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "C:\Program Files\Python37\lib\distutils\dist.py", line 985, in run_command
        cmd_obj.run()
      File "C:\Users\rafar\AppData\Local\Temp\pip-install-xzyrqv53\torch\setup.py", line 51, in run
        from tools.nnwrap import generate_wrappers as generate_nn_wrappers
    ModuleNotFoundError: No module named 'tools.nnwrap'
    ----------------------------------------
ERROR: Command errored out with exit status 1: 'C:\Program Files\Python37\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\rafar\\AppData\\Local\\Temp\\pip-install-xzyrqv53\\torch\\setup.py'"'"'; __file__='"'"'C:\\Users\\rafar\\AppData\\Local\\Temp\\pip-install-xzyrqv53\\torch\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record 'C:\Users\rafar\AppData\Local\Temp\pip-record-upwgi7o7\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\Program Files\Python37\Include\torch' Check the logs for full command output.**
parrt commented 4 years ago

Hi @rafariva can you try this solution from https://stackoverflow.com/questions/56859803/modulenotfounderror-no-module-named-tools-nnwrap ?

pip install torch===1.4.0 torchvision===0.5.0 -f https://download.pytorch.org/whl/torch_stable.html
rafariva commented 4 years ago

Thanks a lot @parrt. it work. :)