Closed l4es closed 11 months ago
Hi @l4es , Thanks for the report. As Ubuntu-18.04 is quite old (https://github.com/rerun-io/rerun/issues/1320 relevant issue from rerun), your best bet is to try installing depthai-viewer from source.
git clone git@github.com:luxonis/depthai-viewer.git && cd depthai-viewer
./scripts/setup_dev.sh
.cargo --version
prints 1.70 once you are donepython3.8 -m pip install rerun_py/
Please report back if installing from source worked for you, thanks!
Hi @zrezke,
It looks like that the binaryen package is required but it is not available in Ubuntu-18.04 :
$ ./scripts/setup_dev.sh
+ ./scripts/setup.sh
++ command -v apt-get
+ '[' -x /usr/bin/apt-get ']'
+ sudo apt-get -y install libatk-bridge2.0 libfontconfig1-dev libfreetype6-dev libglib2.0-dev libgtk-3-dev libssl-dev libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libxkbcommon-dev patchelf
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libatk-bridge2.0-0' for regex 'libatk-bridge2.0'
Note, selecting 'libatk-bridge2.0-dev' for regex 'libatk-bridge2.0'
libatk-bridge2.0-0 is already the newest version (2.26.2-1).
libatk-bridge2.0-dev is already the newest version (2.26.2-1).
libfontconfig1-dev is already the newest version (2.12.6-0ubuntu2).
patchelf is already the newest version (0.9-1).
libfreetype6-dev is already the newest version (2.8.1-2ubuntu2.2).
libglib2.0-dev is already the newest version (2.56.4-0ubuntu0.18.04.9).
libgtk-3-dev is already the newest version (3.22.30-1ubuntu4).
libssl-dev is already the newest version (1.1.1-1ubuntu2.1~18.04.23).
libxcb-render0-dev is already the newest version (1.13-2~ubuntu18.04).
libxcb-shape0-dev is already the newest version (1.13-2~ubuntu18.04).
libxcb-xfixes0-dev is already the newest version (1.13-2~ubuntu18.04).
libxkbcommon-dev is already the newest version (0.8.2-1~ubuntu18.04.1).
0 upgraded, 0 newly installed, 0 to remove and 53 not upgraded.
+ rustup install 1.67.1
info: syncing channel updates for '1.67.1-x86_64-unknown-linux-gnu'
1.67.1-x86_64-unknown-linux-gnu unchanged - rustc 1.67.1 (d5a82bbd2 2023-02-07)
info: checking for self-update
+ ./scripts/setup_web.sh
+ rustup target add wasm32-unknown-unknown
info: component 'rust-std' for target 'wasm32-unknown-unknown' is up to date
+ cargo install wasm-bindgen-cli --git https://github.com/rerun-io/wasm-bindgen.git --rev 13283975ddf48c2d90758095e235b28d381c5762
Updating git repository `https://github.com/rerun-io/wasm-bindgen.git`
Ignored package `wasm-bindgen-cli v0.2.84 (https://github.com/rerun-io/wasm-bindgen.git?rev=13283975ddf48c2d90758095e235b28d381c5762#13283975)` is already installed, use --force to override
+ packagesNeeded=binaryen
++ command -v brew
+ '[' -x '' ']'
++ command -v apt-get
+ '[' -x /usr/bin/apt-get ']'
+ sudo apt-get -y install binaryen
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package binaryen
What is you advise, please ?
Best Regards, Khang
Hi again, I manually built and installed binaryen version_91 :
$ sudo make install
[ 33%] Built target llvm_dwarf
[ 36%] Built target ir
[ 37%] Built target asmjs
[ 38%] Built target cfg
[ 39%] Built target emscripten-optimizer
[ 77%] Built target passes
[ 82%] Built target support
[ 88%] Built target wasm
[ 89%] Built target binaryen
[ 90%] Built target wasm-metadce
[ 91%] Built target asm2wasm
[ 92%] Built target wasm-shell
[ 93%] Built target wasm-opt
[ 94%] Built target wasm-ctor-eval
[ 95%] Built target wasm-reduce
[ 96%] Built target wasm-emscripten-finalize
[ 97%] Built target wasm-as
[ 98%] Built target wasm-dis
[100%] Built target wasm2js
Install the project...
-- Install configuration: "Release"
-- Installing: /usr/local/lib/libbinaryen.so
-- Installing: /usr/local/include/binaryen-c.h
-- Installing: /usr/local/bin/wasm-shell
-- Installing: /usr/local/bin/wasm-opt
-- Installing: /usr/local/bin/wasm-metadce
-- Installing: /usr/local/bin/asm2wasm
-- Installing: /usr/local/bin/wasm2js
-- Installing: /usr/local/bin/wasm-emscripten-finalize
-- Installing: /usr/local/bin/wasm-as
-- Installing: /usr/local/bin/wasm-dis
-- Installing: /usr/local/bin/wasm-ctor-eval
-- Installing: /usr/local/bin/wasm-reduce
khang at GL72-6QF in ~/Workspace2/Sys/binaryen/build on (no branch)△
Then bypassed it from depthai-viewer's _scripts/setupweb.sh :
$ git diff scripts/setup_web.sh
diff --git a/scripts/setup_web.sh b/scripts/setup_web.sh
index a711cd09..17abdbcb 100755
--- a/scripts/setup_web.sh
+++ b/scripts/setup_web.sh
@@ -23,7 +23,6 @@ cargo install wasm-bindgen-cli --git https://github.com/rerun-io/wasm-bindgen.gi
# binaryen gives us wasm-opt, for optimizing the an .wasm file for speed and size
packagesNeeded='binaryen'
if [ -x "$(command -v brew)" ]; then brew install $packagesNeeded
-elif [ -x "$(command -v apt-get)" ]; then sudo apt-get -y install $packagesNeeded
elif [ -x "$(command -v dnf)" ]; then sudo dnf install $packagesNeeded
elif [ -x "$(command -v zypper)" ]; then sudo zypper install $packagesNeeded
elif [ -x "$(command -v apk)" ]; then sudo apk add --no-cache $packagesNeeded
@@ -31,5 +30,4 @@ elif [ -x "$(command -v winget)" ]; then sudo winget add --no-cache $packagesNe
elif [ -x "$(command -v pacman)" ]; then sudo pacman -S $packagesNeeded
else
echo "FAILED TO INSTALL PACKAGE: Package manager not found. You must manually install: $packagesNeeded">&2;
- exit 1
fi
I was able to run ./scripts/setup_dev.sh sucessfully :
...
Compiling typed-arena v2.0.2
Compiling proc-exit v2.0.1
Compiling typos-cli v1.16.1
Finished release [optimized] target(s) in 2m 48s
Installing /home/khang/.cargo/bin/typos
Installed package `typos-cli v1.16.1` (executable `typos`)
+ echo 'setup_dev.sh completed!'
setup_dev.sh completed!
However, running the last command gave following error :
$ python3.8 -m pip install ./rerun_py/
Directory './rerun_py/' is not installable. File 'setup.py' not found.
I would like to know why setup.py is not available, please ? Best Regards, Khang
Update : Using python3.9 manually on my machine helped to proceed the installation :
$ python3.9 -m pip install ./rerun_py/
Defaulting to user installation because normal site-packages is not writeable
Processing ./rerun_py
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Collecting deprecated (from depthai-viewer==0.1.3)
Obtaining dependency information for deprecated from https://files.pythonhosted.org/packages/20/8d/778b7d51b981a96554f29136cd59ca7880bf58094338085bcf2a979a0e6a/Deprecated-1.2.14-py2.py3-none-any.whl.metadata
Downloading Deprecated-1.2.14-py2.py3-none-any.whl.metadata (5.4 kB)
Collecting numpy>=1.23 (from depthai-viewer==0.1.3)
Obtaining dependency information for numpy>=1.23 from https://files.pythonhosted.org/packages/21/9c/1a7d658112aed97be36dfd93cc7362ca6c33598615988e6d836fa0a80f89/numpy-1.25.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata
Downloading numpy-1.25.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (5.6 kB)
Collecting pyarrow==10.0.1 (from depthai-viewer==0.1.3)
Downloading pyarrow-10.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (35.9 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 35.9/35.9 MB 3.3 MB/s eta 0:00:00
Requirement already satisfied: setuptools in /usr/local/lib/python3.9/site-packages (from depthai-viewer==0.1.3) (49.2.1)
Collecting wrapt<2,>=1.10 (from deprecated->depthai-viewer==0.1.3)
Downloading wrapt-1.15.0-cp39-cp39-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl (78 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 78.3/78.3 kB 121.3 kB/s eta 0:00:00
Downloading numpy-1.25.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (17.7 MB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 17.7/17.7 MB 4.2 MB/s eta 0:00:00
Downloading Deprecated-1.2.14-py2.py3-none-any.whl (9.6 kB)
Building wheels for collected packages: depthai-viewer
Building wheel for depthai-viewer (pyproject.toml) ... done
Created wheel for depthai-viewer: filename=depthai_viewer-0.1.3-cp38-abi3-linux_x86_64.whl size=15458504 sha256=415a1a91c57d26ee1f19a9d3d30bf36c34fe478e324ae02ec554e0380cc96242
Stored in directory: /tmp/pip-ephem-wheel-cache-bx7imvru/wheels/e1/a6/79/cd40ed9f6308c51d4b7d932b40788339cde4802ae8a99d8a06
Successfully built depthai-viewer
Installing collected packages: wrapt, numpy, pyarrow, deprecated, depthai-viewer
Successfully installed deprecated-1.2.14 depthai-viewer-0.1.3 numpy-1.25.1 pyarrow-10.0.1 wrapt-1.15.0
And I was able to launch the GUI and stream the OAK-1 camera:
but with with some (minor) error in console :
$ depthai-viewer
Creating virtual environment...
...
Installing collected packages: wrapt, websockets, typing-extensions, pyarrow, depthai, ahrs, pydantic, deprecated
Attempting uninstall: depthai
Found existing installation: depthai 2.21.2.0
Uninstalling depthai-2.21.2.0:
Successfully uninstalled depthai-2.21.2.0
**ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
depthai-sdk 1.11.0 requires depthai==2.21.2, but you have depthai 2.22.0.0 which is incompatible.**
Successfully installed ahrs-0.3.1 deprecated-1.2.14 depthai-2.22.0.0 pyarrow-10.0.1 pydantic-1.9.0 typing-extensions-4.7.1 websockets-11.0.3 wrapt-1.15.0
[2023-07-27T03:43:35Z INFO winit::platform_impl::platform::x11::window] Guessed window scale factor: 1
Welcome to Rerun!
This open source library collects anonymous usage data to
help the Rerun team improve the library.
Summary:
- We only collect high level events about the features used within the Depthai Viewer.
- The actual data you log to Rerun, such as point clouds, images, or text logs,
will never be collected.
- We don't log IP addresses.
- We don't log your user name, file paths, or any personal identifiable data.
- Usage data we do collect will be sent to and stored on servers within the EU.
For more details and instructions on how to opt out, run the command:
rerun analytics details
As this is this your first session, _no_ usage data has been sent yet,
giving you an opportunity to opt-out first if you wish.
Happy Rerunning!
Backend started successfully.
Best Regards, Khang
Hi @l4es ,
Nice, I'm glad it works now and thanks for documenting the steps you had to take to install, it will be very useful for others having the same problem. I'm just a tad confused on the large black areas arround the video stream - does it actually look like that for you? You should be seeing extra UI...
Hi @zrezke,
I'm just a tad confused on the large black areas arround the video stream - does it actually look like that for you? You should be seeing extra UI...
It was actually like below :
Best Regards, Khang
Ah ok, looks good then :)
Describe the bug
I am trying to install depthai-viewer on an Ubuntu-18.04 machine. As the default python3 version of Ubuntu-18.04 is 3.6.x, I manually installed python 3.8 then python3.9 but I am still struggling with the failture.
To Reproduce Steps to reproduce the behavior:
Checkouted the depthai-viewer release-0.1.3 and went inside the folder
First, I expected to isntalled python3.9 directly with following method : https://tecadmin.net/how-to-install-python-3-9-on-ubuntu-18-04/ But it ended up with maximum version was python3.8 :
Python 3.8.0
$ python3.8 -m pip install depthai-viewer
Collecting depthai-viewer
Cache entry deserialization failed, entry ignored
Could not find a version that satisfies the requirement depthai-viewer (from versions: )
No matching distribution found for depthai-viewer
$ python3.9 -V
Python 3.9.2
$ python3.9 -m pip install depthai-viewer
Defaulting to user installation because normal site-packages is not writeable
ERROR: Could not find a version that satisfies the requirement depthai-viewer (from versions: none)
ERROR: No matching distribution found for depthai-viewer
WARNING: You are using pip version 20.2.3; however, version 23.2.1 is available.
You should consider upgrading via the '/usr/local/bin/python3.9 -m pip install --upgrade pip' command.
$ /usr/local/bin/python3.9 -m pip install --upgrade pip
Defaulting to user installation because normal site-packages is not writeable
Collecting pip
Downloading pip-23.2.1-py3-none-any.whl (2.1 MB)
|████████████████████████████████| 2.1 MB 1.7 MB/s
Installing collected packages: pip
Successfully installed pip-23.2.1
WARNING: You are using pip version 20.2.3; however, version 23.2.1 is available.
You should consider upgrading via the '/usr/local/bin/python3.9 -m pip install --upgrade pip' command.
$ python3.9 -m pip install depthai-viewer
Defaulting to user installation because normal site-packages is not writeable
ERROR: Could not find a version that satisfies the requirement depthai-viewer (from versions: none)
ERROR: No matching distribution found for depthai-viewer