I’m wanting to use an I.P. camera but can’t seem to get the library to work. I initially tried the urllib camera install (from the “More” menu) on a copy of my test setup with several hardwired and MQTT enabled sensors, etc., already working (32 bit desktop v.11 bullseye, and found, though the camera setup area appeared and allowed me to setup a camera, it didn’t work and ALSO I was no longer able to get any readings on the “live Measurements” page (all showed 0).
Logs showed this several times:
“ImportError: Error importing numpy: you should not try to import numpy from
its source directory; please exit the numpy source tree, and relaunch
your python interpreter from there.”
(I have other old log info available, but I’m hopeful solving the new issue below will also resolve the this one.)
Rather than bother troubleshooting that right now, I pulled the SD card for now and started from scratch.
To try to get something which can be duplicated, I did a new barebones install, using Debian Bookworm OS 32 bit desktop, Mycodo Version: 8.15.12, and only setup an input for the RPi CPU/GPU so I could see some live measurements. Now the cv2 dependency won’t install while trying to install urllib camera library (doesn’t complete installation), so the camera setup properties don’t appear as it did in my earlier attempt. ALSO, the “Live Measurements” page does still show valid measurements instead of “0”s.
BTW, I’m an old guy who’s not too familiar with posting on forums, so please forgive (or teach) me if I don’t give the needed information, or in the wrong format.
Thanks, Bill J
Mycodo Version: 8.15.12
Python Version: 3.11.2 (main, Mar 13 2023, 12:18:29) [GCC 12.2.0]
Database Version: 16b28ef31b5b
Debian Bookworm OS 32 bit desktop
The Dependency log follows:
[2023-12-09 13:43:53] Dependency installation beginning. Installing: cv2
[2023-12-09 13:43:53]
[2023-12-09 13:43:53] #### Installing/updating opencv-python==4.6.0.66 (pip-pypi)
[2023-12-09 13:43:57] Looking in indexes: Simple index, piwheels - Simple index
[2023-12-09 13:43:58] Collecting opencv-python==4.6.0.66
[2023-12-09 13:43:58] Using cached opencv-python-4.6.0.66.tar.gz (90.3 MB)
[2023-12-09 13:44:28] Installing build dependencies: started
[2023-12-09 13:44:47] Installing build dependencies: finished with status ‘error’
[2023-12-09 13:44:47] error: subprocess-exited-with-error
[2023-12-09 13:44:47]
[2023-12-09 13:44:47] Ã pip subprocess to install build dependencies did not run successfully.
[2023-12-09 13:44:47] â exit code: 1
[2023-12-09 13:44:47] â°â> [20 lines of output]
[2023-12-09 13:44:47] Looking in indexes: Simple index, piwheels - Simple index, piwheels - Simple index
[2023-12-09 13:44:47] Ignoring numpy: markers ‘python_version == “3.6” and platform_machine != “aarch64” and platform_machine != “arm64”’ don’t match your environment
[2023-12-09 13:44:47] Ignoring numpy: markers ‘python_version == “3.7” and platform_machine != “aarch64” and platform_machine != “arm64”’ don’t match your environment
[2023-12-09 13:44:47] Ignoring numpy: markers ‘python_version == “3.8” and platform_machine != “aarch64” and platform_machine != “arm64”’ don’t match your environment
[2023-12-09 13:44:47] Ignoring numpy: markers ‘python_version <= “3.9” and sys_platform == “linux” and platform_machine == “aarch64”’ don’t match your environment
[2023-12-09 13:44:47] Ignoring numpy: markers ‘python_version <= “3.9” and sys_platform == “darwin” and platform_machine == “arm64”’ don’t match your environment
[2023-12-09 13:44:47] Ignoring numpy: markers ‘python_version == “3.9” and platform_machine != “aarch64” and platform_machine != “arm64”’ don’t match your environment
[2023-12-09 13:44:47] Collecting setuptools==59.2.0
[2023-12-09 13:44:47] Using cached https://www.piwheels.org/simple/setuptools/setuptools-59.2.0-py3-none-any.whl (952 kB)
[2023-12-09 13:44:47] Collecting wheel==0.37.0
[2023-12-09 13:44:47] Using cached https://www.piwheels.org/simple/wheel/wheel-0.37.0-py2.py3-none-any.whl (35 kB)
[2023-12-09 13:44:47] Collecting cmake>=3.1
[2023-12-09 13:44:47] Using cached https://www.piwheels.org/simple/cmake/cmake-3.27.9-cp311-cp311-linux_armv7l.whl (19.3 MB)
[2023-12-09 13:44:47] Collecting pip
[2023-12-09 13:44:47] Using cached https://www.piwheels.org/simple/pip/pip-23.3.1-py3-none-any.whl (2.1 MB)
[2023-12-09 13:44:47] Collecting scikit-build>=0.13.2
[2023-12-09 13:44:47] Using cached https://www.piwheels.org/simple/scikit-build/scikit_build-0.17.6-py3-none-any.whl (84 kB)
[2023-12-09 13:44:47] ERROR: Ignored the following versions that require a different python version: 1.21.2 Requires-Python >=3.7,<3.11; 1.21.3 Requires-Python >=3.7,<3.11; 1.21.4 Requires-Python >=3.7,<3.11; 1.21.5 Requires-Python >=3.7,<3.11; 1.21.6 Requires-Python >=3.7,<3.11
[2023-12-09 13:44:47] ERROR: Could not find a version that satisfies the requirement numpy==1.21.2 (from versions: 1.3.0, 1.4.1, 1.5.0, 1.5.1, 1.6.0, 1.6.1, 1.6.2, 1.7.0, 1.7.1, 1.7.2, 1.8.0, 1.8.1, 1.8.2, 1.9.0, 1.9.1, 1.9.2, 1.9.3, 1.10.0.post2, 1.10.1, 1.10.2, 1.10.4, 1.11.0, 1.11.1, 1.11.2, 1.11.3, 1.12.0, 1.12.1, 1.13.0, 1.13.1, 1.13.3, 1.14.0, 1.14.1, 1.14.2, 1.14.3, 1.14.4, 1.14.5, 1.14.6, 1.15.0, 1.15.1, 1.15.2, 1.15.3, 1.15.4, 1.16.0, 1.16.1, 1.16.2, 1.16.3, 1.16.4, 1.16.5, 1.16.6, 1.17.0, 1.17.1, 1.17.2, 1.17.3, 1.17.4, 1.17.5, 1.18.0, 1.18.1, 1.18.2, 1.18.3, 1.18.4, 1.18.5, 1.19.0, 1.19.1, 1.19.2, 1.19.3, 1.19.4, 1.19.5, 1.20.0, 1.20.1, 1.20.2, 1.20.3, 1.21.0, 1.21.1, 1.22.0, 1.22.1, 1.22.2, 1.22.3, 1.22.4, 1.23.0rc1, 1.23.0rc2, 1.23.0rc3, 1.23.0, 1.23.1, 1.23.2, 1.23.3, 1.23.4, 1.23.5, 1.24.0rc1, 1.24.0rc2, 1.24.0, 1.24.1, 1.24.2, 1.24.3, 1.24.4, 1.25.0rc1, 1.25.0, 1.25.1, 1.25.2, 1.26.0b1, 1.26.0rc1, 1.26.0, 1.26.1, 1.26.2)
[2023-12-09 13:44:47] ERROR: No matching distribution found for numpy==1.21.2
[2023-12-09 13:44:47] [end of output]
[2023-12-09 13:44:47]
[2023-12-09 13:44:47] note: This error originates from a subprocess, and is likely not a problem with pip.
[2023-12-09 13:44:47] error: subprocess-exited-with-error
[2023-12-09 13:44:47]
[2023-12-09 13:44:47] Ã pip subprocess to install build dependencies did not run successfully.
[2023-12-09 13:44:47] â exit code: 1
[2023-12-09 13:44:47] â°â> See above for output.
[2023-12-09 13:44:47]
[2023-12-09 13:44:47] note: This error originates from a subprocess, and is likely not a problem with pip.
[2023-12-09 13:44:48] End install of cv2
[2023-12-09 13:44:49]
[2023-12-09 13:44:49] #### Setting permissions
[2023-12-09 13:44:51] #### Dependencies installed. Restarting frontend and backend…
[2023-12-09 13:44:58] #### Dependency install complete.