|
Are you using custom models or the standard models?
cheers
Chris Maunder
|
|
|
|
|
Hello, I have not enabled custom models.
|
|
|
|
|
Thanks very much for the report. Can you please share your BI settings? Like the AI main settings and the Artificial Intelligence settings under Triggers.
Thanks,
Sean Ewington
CodeProject
|
|
|
|
|
Hello. I installed the Windows version and no more errors I had been running on a VM on VirtualBox on the Windows PC. Should be good now. Thanks.
|
|
|
|
|
Download the latest version, install, and launch the shortcut to the server's dashboard on your desktop.
On the dashboard, top and centre, is a link to the CodeProject.AI Explorer. Open that and play!
|
|
|
|
|
Fresh install of 2.1.8 on Windows and having trouble installing the ALPR module. Here are the logs showing the issue. It's funny that the dashboard still shows it as "started" in the status tab but I don't think it really is according to the logs. Windows is running in a VM on a Proxmox host for this installation. I see there is an AVX requirement for paddlepaddle which seems to be causing the exception.
<pre>2023-05-14 08:58:59: Preparing to install module 'ALPR'
2023-05-14 08:58:59: Downloading module 'ALPR'
2023-05-14 08:58:59: Installing module 'ALPR'
2023-05-14 08:59:00: ALPR: [0;33m[49m Installing CodeProject.AI Analysis Module [0m
2023-05-14 08:59:00: ALPR: [0;32m[49m========================================================================[0m
2023-05-14 08:59:00: ALPR: [0;32m[49m CodeProject.AI Installer [0m
2023-05-14 08:59:00: ALPR: [0;32m[49m========================================================================[0m
2023-05-14 08:59:00: ALPR: [0;39m[49mCUDA Present...[0m[0;33m[49mFalse[0m
2023-05-14 08:59:00: ALPR: [0;39m[49mAllowing GPU Support: [0m[0;92m[49mYes[0m
2023-05-14 08:59:00: ALPR: [0;39m[49mAllowing CUDA Support: [0m[0;33m[49mNo[0m
2023-05-14 08:59:00: ALPR: [0;97m[104mGeneral CodeProject.AI setup [0m
2023-05-14 08:59:00: ALPR: [0;39m[49mCreating Directories...[0m[0;92m[49mDone[0m
2023-05-14 08:59:00: ALPR: [0;97m[104mInstalling module ALPR [0m
2023-05-14 08:59:00: ALPR: [0;93m[49mInstalling python37 in C:\Program Files\CodeProject\AI\runtimes\bin\windows\python37[0m
2023-05-14 08:59:00: ALPR: [0;90m[49mChecking for python37 download...[0m[0;92m[49mPresent[0m
2023-05-14 08:59:13: ALPR: [0;39m[49mCreating Virtual Environment...[0m[0;92m[49mDone[0m
2023-05-14 08:59:13: ALPR: [0;39m[49mEnabling our Virtual Environment...[0m[0;92m[49mDone[0m
2023-05-14 08:59:13: ALPR: [0;39m[49mConfirming we have Python 3.7...[0m[0;92m[49mpresent[0m
2023-05-14 08:59:15: ALPR: [0;39m[49mEnsuring Python package manager (pip) is installed...[0m[0;92m[49mDone[0m
2023-05-14 08:59:27: ALPR: [0;39m[49mEnsuring Python package manager (pip) is up to date...[0m[0;92m[49mDone[0m
2023-05-14 08:59:27: ALPR: [0;93m[49mChoosing Python packages from requirements.txt[0m
2023-05-14 09:04:23: ALPR: [0;39m[49mInstalling Packages into Virtual Environment...[0m[0;92m[49mSuccess[0m
2023-05-14 09:04:29: ALPR: [0;39m[49mEnsuring Python package manager (pip) is installed...[0m[0;92m[49mDone[0m
2023-05-14 09:04:32: ALPR: [0;39m[49mEnsuring Python package manager (pip) is up to date...[0m[0;92m[49mDone[0m
2023-05-14 09:04:32: ALPR: [0;93m[49mChoosing Python packages from requirements.txt[0m
2023-05-14 09:04:45: ALPR: [0;39m[49mInstalling Packages into Virtual Environment...[0m[0;92m[49mSuccess[0m
2023-05-14 09:04:45: ALPR: [0;93m[49mApplying patch for PaddlePaddle[0m
2023-05-14 09:04:45: ALPR: 1 file(s) copied.
2023-05-14 09:04:45: ALPR: [0;97m[49mDownloading ALPR models...[0m[0;93m[49malready exists...[0m[0;93m[49mExpanding...[0m[0;92m[49mDone.[0m
2023-05-14 09:04:46: ALPR: [0;97m[42mModule setup complete [0m
2023-05-14 09:04:46: Module ALPR installed successfully.
2023-05-14 09:04:46: GetCommandByRuntime: Runtime=python37, Location=Local
2023-05-14 09:04:46: Command: C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\scripts\Python
2023-05-14 09:04:46:
2023-05-14 09:04:46: Attempting to start ALPR with C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\scripts\Python "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py"
2023-05-14 09:04:46: Starting C:\Program Files...ws\python37\venv\scripts\Python "C:\Program Files...\modules\ALPR\ALPR_adapter.py"
2023-05-14 09:04:46:
2023-05-14 09:04:46: ** Module 'License Plate Reader' (ID: ALPR)
2023-05-14 09:04:46: ** Module Path: C:\Program Files\CodeProject\AI\modules\ALPR
2023-05-14 09:04:46: ** AutoStart: True
2023-05-14 09:04:46: ** Queue: alpr_queue
2023-05-14 09:04:46: ** Platforms: windows,linux,macos,macos-arm64
2023-05-14 09:04:46: ** GPU: Support enabled
2023-05-14 09:04:46: ** Parallelism: 0
2023-05-14 09:04:46: ** Accelerator:
2023-05-14 09:04:46: ** Half Precis.: enable
2023-05-14 09:04:46: ** Runtime: python37
2023-05-14 09:04:46: ** Runtime Loc: Local
2023-05-14 09:04:46: ** FilePath: ALPR_adapter.py
2023-05-14 09:04:46: ** Pre installed: False
2023-05-14 09:04:46: ** Start pause: 1 sec
2023-05-14 09:04:46: ** LogVerbosity:
2023-05-14 09:04:46: ** Valid: True
2023-05-14 09:04:46: ** Environment Variables
2023-05-14 09:04:46: ** AUTO_PLATE_ROTATE = True
2023-05-14 09:04:46: ** PLATE_CONFIDENCE = 0.7
2023-05-14 09:04:46: ** PLATE_RESCALE_FACTOR = 2
2023-05-14 09:04:46: ** PLATE_ROTATE_DEG = 0
2023-05-14 09:04:46:
2023-05-14 09:04:46: Started License Plate Reader module
2023-05-14 09:04:46: Installer exited with code 1
2023-05-14 09:04:47: Module ALPR started successfully.
2023-05-14 09:04:48: ALPR_adapter.py: Error: Your machine doesn't support AVX, but the installed PaddlePaddle is avx core, you should reinstall paddlepaddle with no-avx core.
2023-05-14 09:04:48: ALPR_adapter.py: Traceback (most recent call last):
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py", line 16, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: from ALPR import init_detect_platenumber, detect_platenumber
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR.py", line 20, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: from paddleocr import PaddleOCR
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddleocr\__init__.py", line 14, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: from .paddleocr import *
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddleocr\paddleocr.py", line 21, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: import paddle
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\__init__.py", line 25, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: from .framework import monkey_patch_variable
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\framework\__init__.py", line 17, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: from . import random # noqa: F401
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\framework\random.py", line 16, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: import paddle.fluid as fluid
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\__init__.py", line 36, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: from . import framework
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\framework.py", line 37, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: from . import core
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\core.py", line 365, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: raise e
2023-05-14 09:04:48: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\core.py", line 313, in <module>
2023-05-14 09:04:48: ALPR_adapter.py: from . import core_noavx
2023-05-14 09:04:48: ALPR_adapter.py: ImportError: cannot import name 'core_noavx' from 'paddle.fluid' (C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\__init__.py)
2023-05-14 09:04:48: ** Module ALPR has shutdown
2023-05-14 09:04:48: ALPR_adapter.py: has exited
2023-05-14 09:06:22: GetCommandByRuntime: Runtime=python37, Location=Local
2023-05-14 09:06:22: Command: C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\scripts\Python
2023-05-14 09:06:22:
2023-05-14 09:06:22: Attempting to start ALPR with C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\scripts\Python "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py"
2023-05-14 09:06:22: Starting C:\Program Files...ws\python37\venv\scripts\Python "C:\Program Files...\modules\ALPR\ALPR_adapter.py"
2023-05-14 09:06:22:
2023-05-14 09:06:22: ** Module 'License Plate Reader' (ID: ALPR)
2023-05-14 09:06:22: ** Module Path: C:\Program Files\CodeProject\AI\modules\ALPR
2023-05-14 09:06:22: ** AutoStart: True
2023-05-14 09:06:22: ** Queue: alpr_queue
2023-05-14 09:06:22: ** Platforms: windows,linux,macos,macos-arm64
2023-05-14 09:06:22: ** GPU: Support enabled
2023-05-14 09:06:22: ** Parallelism: 0
2023-05-14 09:06:22: ** Accelerator:
2023-05-14 09:06:22: ** Half Precis.: enable
2023-05-14 09:06:22: ** Runtime: python37
2023-05-14 09:06:22: ** Runtime Loc: Local
2023-05-14 09:06:22: ** FilePath: ALPR_adapter.py
2023-05-14 09:06:22: ** Pre installed: False
2023-05-14 09:06:22: ** Start pause: 1 sec
2023-05-14 09:06:22: ** LogVerbosity:
2023-05-14 09:06:22: ** Valid: True
2023-05-14 09:06:22: ** Environment Variables
2023-05-14 09:06:22: ** AUTO_PLATE_ROTATE = True
2023-05-14 09:06:22: ** PLATE_CONFIDENCE = 0.7
2023-05-14 09:06:22: ** PLATE_RESCALE_FACTOR = 2
2023-05-14 09:06:22: ** PLATE_ROTATE_DEG = 0
2023-05-14 09:06:22:
2023-05-14 09:06:22: Started License Plate Reader module
2023-05-14 09:06:22: ALPR_adapter.py: Error: Your machine doesn't support AVX, but the installed PaddlePaddle is avx core, you should reinstall paddlepaddle with no-avx core.
2023-05-14 09:06:22: ALPR_adapter.py: Traceback (most recent call last):
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py", line 16, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: from ALPR import init_detect_platenumber, detect_platenumber
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR.py", line 20, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: from paddleocr import PaddleOCR
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddleocr\__init__.py", line 14, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: from .paddleocr import *
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddleocr\paddleocr.py", line 21, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: import paddle
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\__init__.py", line 25, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: from .framework import monkey_patch_variable
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\framework\__init__.py", line 17, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: from . import random # noqa: F401
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\framework\random.py", line 16, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: import paddle.fluid as fluid
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\__init__.py", line 36, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: from . import framework
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\framework.py", line 37, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: from . import core
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\core.py", line 365, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: raise e
2023-05-14 09:06:22: ALPR_adapter.py: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\core.py", line 313, in <module>
2023-05-14 09:06:22: ALPR_adapter.py: from . import core_noavx
2023-05-14 09:06:22: ALPR_adapter.py: ImportError: cannot import name 'core_noavx' from 'paddle.fluid' (C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python37\venv\lib\site-packages\paddle\fluid\__init__.py)
2023-05-14 09:06:22: ** Module ALPR has shutdown
2023-05-14 09:06:22: ALPR_adapter.py: has exited
|
|
|
|
|
Well I answer my own question. I changed my CPU type in Proxmox to "Host" which exposed the AVX instruction set. Now the AlPR model installs just fine. I could have also probably just added the appropriate flag to the original CPU model as well but changing it to "Host" works well enough for me.
I'll leave this here incase anyone else in the future needs this info.
|
|
|
|
|
Can you please write up how you did this and we'll add it to the FAQ.
cheers
Chris Maunder
|
|
|
|
|
Sure. It's a simple change on the Proxmox host. Click on the VM and shut it down. Then click Hardware - > Processors -> Edit - > Set type to Host.
It's the easiest solution but it would prevent live migration of the VM unless the host you are migrating to is running the exact same CPU as the host you are migrating from. But for a single host setup it's fine. The other option is to create specific CPU models and then add the appropriate flags you desire to those models as documented in the Proxmox manual here: Manual: cpu-models.conf - Proxmox VE[^]
|
|
|
|
|
I installed 2.1.8 and it's not working. It's like paths are not right, I'm guessing. I don't have time right now to do a deep dive troubleshooting and just want to fall back a version maybe 2.
Where do I find the installers for other versions?
|
|
|
|
|
The very first message on this forum has links
cheers
Chris Maunder
|
|
|
|
|
Incase anyone else is running into this issue, after uninstalling and installing 2.1.8 I let the default modules download and install. Unfortunately none of them would start or started with errors. After doing some digging in the errors, I found that each module was trying to find files that did not exists. For instance, Object Detection (YOLOv5 6.2) kept complaining that python was not installed. Found out that the module installed with the it in Program Files\CodeProject\AI\runtimes\bin\window\python37\python37. To fix this I had to copy the files from the lower python37 directory up 1 level. Following that I had to uninstall the module, restart the service, and then reinstall the module. Unfortunately that still produced PIL errors, so I moved on to troubleshooting why I could not get YOLOv5 .NET working. It too had problems with files in directories it could not find. In this instance I had to move files in the Program Files\CodeProject\QI\modules\ObejectDetectionNet\ObjectDetectionNet-DirectML-1.4 folder up 1 level and also the files from Program Files\CodeProject\QI\modules\ObejectDetectionNet\assets\ObjectDetectionNet-DirectML-1.4 up one level. Once this was completed I could restart the YOLOv5 .NET module and it is working just fine.
I decided to stick with YOLOv5 .NET since I am currently running in a VMWare VM and don't have a GPU. I will eventually be moving to a dedicated system once I add several more cameras.
|
|
|
|
|
Which version of Windows?
cheers
Chris Maunder
|
|
|
|
|
I am currently running on Windows Server 2016 standard.
Thanks,
Rick Moody
|
|
|
|
|
My install is failing as well, modules say they have installed but systemlog is throwing missing file errors during installation.
Windows 10.
|
|
|
|
|
Please try reinstalling that module. It would most likely be because of a timeout in the installation.
cheers
Chris Maunder
|
|
|
|
|
I have multiple times and have never had it work yet, but I'll give it another go, thanks.
|
|
|
|
|
22:02:29:ObjectDetectionYolo: 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.
22:02:29:ObjectDetectionYolo: botocore 1.29.133 requires urllib3<1.27,>=1.25.4, but you have urllib3 2.0.2 which is incompatible.
22:02:29:ObjectDetectionYolo: google-auth 2.18.0 requires urllib3<2.0, but you have urllib3 2.0.2 which is incompatible.
22:02:30:ObjectDetectionYolo: Installing Packages into Virtual Environment...Success
|
|
|
|
|
We don't support this version of Windows, but we have a fix in an upcoming version that should address this. It comes down to us using `tar` to unpack things, and falling back to powershell. The powershell extract is wrong, which we've fixed, so the 'non-windows-10' fall back should work again.
I'll see if we can get an update out in the next day or so
cheers
Chris Maunder
|
|
|
|
|
Thanks Chris, much appreciated. It worked in pre 2.x versions. I think I was running 1.6 on the same system without issues getting the modules installed. Only problem I was running into on the old version was the old python YOLO would chew up tons of memory and cause the server to crash. I should have been using the .Net version whole time since I did not have a graphics card to do the analytics.
|
|
|
|
|
If you're not sure where the package is installed, you can open a command prompt and type pip show 'package-name'. This will show you the installation location of the package.
|
|
|
|
|
We've fixed this in a new release due out today.
cheers
Chris Maunder
|
|
|
|
|
I was able to get the Docker image running on my Raspberry Pi 4 with TFLite and a Coral USB device. I am running version 2.1.8-Beta. I prefer to manage my containers via Docker Compose. I created my compose file (below) during the first run of the container, everything works perfectly.
However if the container is restarted for any reason, the TFLite module no longer starts correctly. I am seeing the following errors logged:
22:47:27:objectdetection_tflite_adapter.py: Exception ignored in:
22:47:27:objectdetection_tflite_adapter.py: Traceback (most recent call last):
22:47:27:objectdetection_tflite_adapter.py: File "/app/modules/ObjectDetectionTFLite/bin/linux/python39/venv/lib/python3.9/site-packages/tflite_runtime/interpreter.py", line 124, in __del__
22:47:27:objectdetection_tflite_adapter.py: if self._library is not None:
22:47:27:objectdetection_tflite_adapter.py: AttributeError: 'Delegate' object has no attribute '_library'
22:47:27:objectdetection_tflite_adapter.py: Exception ignored in:
22:47:27:objectdetection_tflite_adapter.py: Traceback (most recent call last):
22:47:27:objectdetection_tflite_adapter.py: File "/app/modules/ObjectDetectionTFLite/bin/linux/python39/venv/lib/python3.9/site-packages/tflite_runtime/interpreter.py", line 124, in __del__
22:47:27:objectdetection_tflite_adapter.py: if self._library is not None:
22:47:27:objectdetection_tflite_adapter.py: AttributeError: 'Delegate' object has no attribute '_library'
** Docker Compose File **
version: '3.9'
services:
code-project-ai:
container_name: code-project-ai
privileged: true
restart: unless-stopped
image: codeproject/ai-server:arm64
devices:
- /dev/bus/usb:/dev/bus/usb
volumes:
- ./ai:/etc/codeproject/ai
- ./modules:/app/modules
ports:
- '32168:32168'
Just a guess, but it seems like some required data is not being persisted? Can anyone please point me in the right direction?
|
|
|
|
|
That all looks good (my previous post said use privileged and don't forget /dev/bus/usb:/dev/bus/us but you already do that).
No idea unfortunately
cheers
Chris Maunder
|
|
|
|
|
Any suggestions to pull more logging or test anything else? I already had the logging slider to the debug setting.
|
|
|
|
|