0

I am trying to run a pretrained model for which i need to install tensorflow 1.1. I made a conda environment successfully and also installed tensorflow 1.1 using the command

pip install tensorflow_gpu==1.1

But it raises an exception

Exception:

Traceback (most recent call last):
  File "/usr/local/anaconda3/lib/python3.6/site-packages/pip/basecommand.py", line 215, in main
    status = self.run(options, args)
  File "/usr/local/anaconda3/lib/python3.6/site-packages/pip/commands/install.py", line 342, in run
    prefix=options.prefix_path,
  File "/usr/local/anaconda3/lib/python3.6/site-packages/pip/req/req_set.py", line 784, in install
    **kwargs
  File "/usr/local/anaconda3/lib/python3.6/site-packages/pip/req/req_install.py", line 851, in install
    self.move_wheel_files(self.source_dir, root=root, prefix=prefix)
  File "/usr/local/anaconda3/lib/python3.6/site-packages/pip/req/req_install.py", line 1064, in move_wheel_files
    isolated=self.isolated,
  File "/usr/local/anaconda3/lib/python3.6/site-packages/pip/wheel.py", line 345, in move_wheel_files
    clobber(source, lib_dir, True)
  File "/usr/local/anaconda3/lib/python3.6/site-packages/pip/wheel.py", line 323, in clobber
    shutil.copyfile(srcfile, destfile)
  File "/usr/local/anaconda3/lib/python3.6/shutil.py", line 115, in copyfile
    with open(dst, 'wb') as fdst:
PermissionError: [Errno 13] Permission denied: '/usr/local/anaconda3/lib/python3.6/site-packages/protobuf-3.4.0-py3.6-nspkg.pth'

When i try to test the tensorflow it gives the following error

import tensorflow as tf 
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'tensorflow'

I also tried to set the path thinking it might be getting installed in the default conda instead of the desired environment my path is as follows /home/awahid/.conda/envs/mask-rcnn but no avail.

Maurice Meyer
  • 17,279
  • 4
  • 30
  • 47
  • As you're trying to install into /usr/local/ you probably should install it as root: sudo pip install tensorflow_gpu==1.1 – Plenka Nov 16 '17 at 07:39
  • I tried to install as root also but it gives me an error: awahid is not in the sudoers file. This incident will be reported. – Abdul Wahid Nov 16 '17 at 08:01
  • did you try `conda install tensorflow`? https://stackoverflow.com/questions/20994716/what-is-the-difference-between-pip-and-conda – Jack Homan Nov 16 '17 at 08:20

0 Answers0