Skip to content

Commit

Permalink
NNEF - Use V1.0.0 Branch (#1370)
Browse files Browse the repository at this point in the history
* NNEF - Use V1.0.0 Branch

* Numpy - Version update

* Setup - Fix

* NN Test - Fix

* Setup - Fix Numpy for RPM

* Numpy - for RPM

* Test - Fix NN for RPM
  • Loading branch information
kiritigowda authored Jun 3, 2024
1 parent acb2ac7 commit 1c8c6de
Show file tree
Hide file tree
Showing 7 changed files with 141 additions and 100 deletions.
8 changes: 4 additions & 4 deletions MIVisionX-setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ def ERROR_CHECK(call):
pip3InferencePackagesUbuntu = [
'future==0.18.2',
'pytz==2022.1',
'numpy==1.21',
'numpy==1.22',
'google==3.0.0',
'protobuf==3.12.4',
'onnx==1.12.0'
Expand All @@ -264,7 +264,7 @@ def ERROR_CHECK(call):
pip3InferencePackagesSLES = [
'future==0.18.2',
'pytz==2022.1',
'numpy==1.19',
'numpy==1.23.0',
'google==3.0.0',
'protobuf==3.12.4',
'onnx==1.11.0'
Expand Down Expand Up @@ -422,9 +422,9 @@ def ERROR_CHECK(call):
# Install NNEF Deps
ERROR_CHECK(os.system('mkdir -p '+modelCompilerDeps+'/nnef-deps'))
ERROR_CHECK(os.system(
'(cd '+modelCompilerDeps+'/nnef-deps; git clone https://github.com/KhronosGroup/NNEF-Tools.git)'))
'(cd '+modelCompilerDeps+'/nnef-deps; git clone -b nnef-v1.0.0 https://github.com/KhronosGroup/NNEF-Tools.git)'))
ERROR_CHECK(os.system(
'(cd '+modelCompilerDeps+'/nnef-deps/NNEF-Tools/parser/cpp; mkdir -p build && cd build; '+linuxCMake+' ..; make -j$(nproc))'))
'(cd '+modelCompilerDeps+'/nnef-deps/NNEF-Tools/parser/cpp; mkdir -p build && cd build; '+linuxCMake+' ..; make -j$(nproc); sudo make install)'))
ERROR_CHECK(os.system(
'(cd '+modelCompilerDeps+'/nnef-deps/NNEF-Tools/parser/python; sudo python3 setup.py install)'))
else:
Expand Down
2 changes: 1 addition & 1 deletion docker/mivisionx-on-ubuntu20.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ ENV CUPY_INSTALL_USE_HIP=1
ENV ROCM_HOME=/opt/rocm
RUN DEBIAN_FRONTEND=noninteractive apt-get -y install git g++ hipblas hipsparse rocrand hipfft rocfft rocthrust-dev hipcub-dev python3 python3-pip python3-dev && \
git clone -b v12.2.0 https://github.com/ROCmSoftwarePlatform/cupy.git && \
git submodule update --init && pip install -e . --no-cache-dir -vvvv && pip install numpy==1.21 && cd
git submodule update --init && pip install -e . --no-cache-dir -vvvv && pip install numpy==1.22 && cd

ENV MIVISIONX_WORKSPACE=/workspace
WORKDIR $MIVISIONX_WORKSPACE
Expand Down
2 changes: 1 addition & 1 deletion docker/ubuntu20/level-5.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ ENV CUPY_INSTALL_USE_HIP=1
ENV ROCM_HOME=/opt/rocm
RUN DEBIAN_FRONTEND=noninteractive apt-get -y install git g++ hipblas hipsparse rocrand hipfft rocfft rocthrust-dev hipcub-dev python3 python3-pip python3-dev && \
git clone -b v12.2.0 https://github.com/ROCmSoftwarePlatform/cupy.git && \
git submodule update --init && pip install -e . --no-cache-dir -vvvv && pip install numpy==1.21 && cd
git submodule update --init && pip install -e . --no-cache-dir -vvvv && pip install numpy==1.22 && cd

ENV MIVISIONX_WORKSPACE=/workspace
WORKDIR $MIVISIONX_WORKSPACE
Expand Down
2 changes: 1 addition & 1 deletion docker/ubuntu22/level-5.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ RUN DEBIAN_FRONTEND=noninteractive apt-get -y install git g++ hipblas hipsparse
pip install pytest==3.1 && git clone -b v2.10.4 https://github.com/pybind/pybind11 && cd pybind11 && mkdir build && cd build && \
cmake -DDOWNLOAD_CATCH=ON -DDOWNLOAD_EIGEN=ON ../ && make -j4 && sudo make install && cd ../../ && \
git clone -b v12.2.0 https://github.com/ROCmSoftwarePlatform/cupy.git && cd cupy && git submodule update --init && \
pip install -e . --no-cache-dir -vvvv && pip install numpy==1.21
pip install -e . --no-cache-dir -vvvv && pip install numpy==1.22

ENV MIVISIONX_WORKSPACE=/workspace
WORKDIR $MIVISIONX_WORKSPACE
Expand Down
5 changes: 3 additions & 2 deletions docs/install/model-compiler-install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Prerequisites

.. code-block:: shell
sudo pip3 install future==0.18.2 pytz==2022.1 numpy==1.21
sudo pip3 install future==0.18.2 pytz==2022.1 numpy==1.22
.. note::
Expand Down Expand Up @@ -85,11 +85,12 @@ NNEF

.. code-block:: shell
git clone https://github.com/KhronosGroup/NNEF-Tools.git
git clone -b nnef-v1.0.0 https://github.com/KhronosGroup/NNEF-Tools.git
cd NNEF-Tools/parser/cpp
mkdir -p build && cd build
cmake ../
make
sudo make install
cd ../../../python
sudo python3 setup.py install
Expand Down
5 changes: 3 additions & 2 deletions model_compiler/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ MIVisionX allows hundreds of different [OpenVX](https://www.khronos.org/registry
```
* PIP3 Packages
```
sudo pip3 install future==0.18.2 pytz==2022.1 numpy==1.21
sudo pip3 install future==0.18.2 pytz==2022.1 numpy==1.22
```

**Note:** MIVisionX installs model compiler scripts at `/opt/rocm/libexec/mivisionx/model_compiler/python/`
Expand All @@ -81,11 +81,12 @@ sudo pip3 install protobuf==3.12.4 onnx==1.12.0

* [nnef-parser](https://github.com/KhronosGroup/NNEF-Tools) - Build the nnef python module
```
git clone https://github.com/KhronosGroup/NNEF-Tools.git
git clone -b nnef-v1.0.0 https://github.com/KhronosGroup/NNEF-Tools.git
cd NNEF-Tools/parser/cpp
mkdir -p build && cd build
cmake ../
make
sudo make install
cd ../../../python
sudo python3 setup.py install
```
Expand Down
Loading

0 comments on commit 1c8c6de

Please sign in to comment.