aimet icon indicating copy to clipboard operation
aimet copied to clipboard

Installation guide not updated for release 1.16.0

Open bwery opened this issue 3 years ago • 7 comments

I have tried to install the release 1.16.0 (on ubuntu 18.04), because it is the released documentation is referencing.

I have not been able to install this release:

  • Documentation provided at [https://github.com/quic/aimet/blob/develop/packaging/install.md] is not in accordance with the files present in the release directory, so I have tried to install the packages considering my "feeling".
  • When I try to install the packages for gpu in the release directory, there is a dependency corresponding to a package "torchvision==0.8.2+cu110" that is not available in usual repositories. I have installed the package using the --no-deps option, and then used the requirement list after modifications, using "torchvision==0.8.2" instead, but I don't know if this can actually work.
  • At the end, when I try to import Aimet as presented in the examples, I get the message "ModuleNotFoundError: No module named 'libpymo". Some issue discussions indicate it could be a problem with environment variables, but I have not been able to find this file on my system, nor to identify the origin of this file.

So I have not found any solution for proper installation of release 1.16.0.

Note: In the meanwhile, I am going to try to use release 1.13.0 that seems easier to install. But I don't know if documentation is still valid for it.

EDIT: It seems the problem about 'libpymo' is related to the fact that I work inside a Jupyter notebook, the environment variables not being transferred to it.

I hope someone can bring some help. This software looks great and would be very useful to me and I think a lot of others.

Environment:

OS: Ubuntu 18.04 LTS, running in a LXD container. Python 3.6.9 Execution in a Jupyter notebook.

EDIT2: sorry for the multiple edits, but I change my message following my findings.

bwery avatar Apr 26 '21 14:04 bwery

@bwery Thank you for reporting your observations. @quic-bharathr could you please take a look at this.

quic-ssiddego avatar Apr 26 '21 18:04 quic-ssiddego

@quic-ssiddego : Thank you for your attention !

Now, I have succeeded to install release 1.13.0 (let say imports are working. I have not tested further as I am discovering the software).

One problem during this installation: the python dependencies have not been installed when installing the aimet packages. I had to run an "pip3 install -r" using file "/usr/local/lib/python3.6/dist-packages/aimet_common/bin/requirements.txt".

Note that in this file there is a requirement for tensorflow==1.15.0 which would have caused a downgrade of the release I have installed which is 1.15.5. I have removed this requirement before proceeding but do not know if this can have an impact.

Regarding the Jupyter notebook, It is required to proceed as you have indicated for the colab environment, that is to say, update the path en environment inside the notebook itself. I had to modify the statement for the LD_LIBRARY_PATH, because no such environment variable was visible from the notebook. So I have added following statements:

import os import sys sys.path.append('/usr/local/lib/python3.6/dist-packages/aimet_common/x86_64-linux-gnu') sys.path.append('/usr/local/lib/python3.6/dist-packages/aimet_common/x86_64-linux-gnu/aimet_tensor_quantizer-0.0.0-py3.6-linux-x86_64.egg/') os.environ['LD_LIBRARY_PATH'] = '/usr/local/lib/python3.6/dist-packages/aimet_common/x86_64-linux-gnu:/usr/local/lib/python3.6/dist-packages/aimet_common::/usr/local/cuda-10.0/lib64'

bwery avatar Apr 27 '21 09:04 bwery

@bwery Thank you for the feedback.

  1. Yes, you're correct that the 1.16.0 release is not usable as documented and the requirements.txt is not up to date. We are working on fixing these issues and will provide an updated release and documentation shortly. Please continue to use the 1.14.0 or earlier versions until then: https://github.com/quic/aimet/releases/tag/1.14.0
  2. It is fine to switch to the latest tensorflow 1.15.x that you have, though we only tested with version 1.15.0
  3. If you'd like to contribute the above Jupyter notebook and/or instructions, please do so using the instructions in our document https://github.com/quic/aimet/blob/develop/CONTRIBUTING.md

Also related to #573

quic-bharathr avatar Apr 29 '21 01:04 quic-bharathr

@bwery We have a new release and instructions which should fix the dependency issues. Could you please try it out and let us know if any issues?

  • Release: https://github.com/quic/aimet/releases/tag/1.16.1
  • Instructions: https://github.com/quic/aimet/blob/1.16.1/packaging/install.md

quic-bharathr avatar May 19 '21 21:05 quic-bharathr

The problem persists for AIMET 1.17.0

PaulZhangIsing avatar Dec 01 '21 05:12 PaulZhangIsing

  • @quic-fmayer @quic-bharathr

quic-ssiddego avatar Jan 22 '22 05:01 quic-ssiddego

@PaulZhangIsing Which problem still persists in the latest release? We now have a newer 1.18 release: https://github.com/quic/aimet/releases. And here is a working Jupyter notebook example in case you want to try it out: https://github.com/quic/aimet/blob/develop/Examples/torch/quantization/cle_bc.ipynb

quic-bharathr avatar Jan 22 '22 08:01 quic-bharathr

Mark this as resolved. If you have further questions please re-open or create a new issue.

quic-hitameht avatar Jan 30 '23 13:01 quic-hitameht