-
Notifications
You must be signed in to change notification settings - Fork 171
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ALPR issues #268
Comments
08:55:39:ALPR_adapter.py: An exception occurred initialising the module: (PreconditionNotMet) The third-party dynamic library (cudnn64_8.dll) that Paddle depends on is not configured correctly. (error code is 126) cudnn-10.0-windows10-x64-v7.6.5.32.zip does not contain cudnn64_8.dll |
I installed the cudnn-10.2-windows10-x64-v8.2.0.53.zip and added it to the path and now it gets further but crashes with 09:13:43:ALPR_adapter.py: Could not locate zlibwapi.dll. Please make sure it is in your library path! I found zlib.dll, renamed it to zlibwapi.dll and copied it to C:\Program Files\NVIDIA\CUDNN\v8.8\bin .. and now ALPR has started working |
When i pass in an image containing a license plate (latest version on windows 64, v2.9.5) I get
11:36:30:Response rec'd from Object Detection (YOLOv5 .NET) command 'custom' (...f7fb8b) ['Found DayPlate'] took 92ms
11:36:30:Response rec'd from License Plate Reader command 'alpr' (...575de9)
11:36:30:License Plate Reader: [error] : Traceback (most recent call last):
File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py", line 53, in process
result = await detect_platenumber(self, self.opts, image)
File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR.py", line 242, in detect_platenumber
numpy_plate = cv2.resize(numpy_plate, None, fx = resize_width_factor,
cv2.error: OpenCV(4.11.0) D:\a\opencv-python\opencv-python\opencv\modules\imgproc\src\resize.cpp:4211: error: (-215:Assertion failed) inv_scale_x > 0 in function 'cv::resize'
This is the image i am uploading to /v1/image/alpr
I did a full uninstall/ reinstall and i get this in the setup logs
12:38:57:System: Windows
12:38:57:Operating System: Windows (Windows 11 23H2)
12:38:57:CPUs: AMD Ryzen 9 5950X 16-Core Processor (AMD)
12:38:57: 1 CPU x 16 cores. 32 logical processors (x64)
12:38:57:GPU (Primary): NVIDIA GeForce RTX 3080 (10 GiB) (NVIDIA)
12:38:57: Driver: 566.03, CUDA: 12.7 (up to: 12.7), Compute: 8.6, cuDNN:
12:38:57:System RAM: 32 GiB
12:38:57:Platform: Windows
12:38:57:BuildConfig: Release
12:38:57:Execution Env: Native
12:38:57:Runtime Env: Production
12:38:57:Runtimes installed:
12:38:57: .NET runtime: 9.0.0
12:38:57: .NET SDK: 0.24575.35
12:38:57: Default Python: Not found
12:38:57: Go: Not found
12:38:57: NodeJS: Not found
12:38:57: Rust: Not found
12:38:57:App DataDir: C:\ProgramData\CodeProject\AI
12:38:57:Video adapter info:
12:38:57: Virtual Desktop Monitor:
12:38:57: Driver Version 13.50.53.699
12:38:57: Video Processor
12:38:57: Meta Virtual Monitor:
12:38:57: Driver Version 17.12.55.198
12:38:57: Video Processor
12:38:57: NVIDIA GeForce RTX 3080:
12:38:57: Driver Version 32.0.15.6603
12:38:57: Video Processor NVIDIA GeForce RTX 3080
12:38:57:STARTING CODEPROJECT.AI SERVER
12:38:57:RUNTIMES_PATH = C:\Program Files\CodeProject\AI\runtimes
12:38:57:PREINSTALLED_MODULES_PATH = C:\Program Files\CodeProject\AI\preinstalled-modules
12:38:57:DEMO_MODULES_PATH = C:\Program Files\CodeProject\AI\src\demos\modules
12:38:57:EXTERNAL_MODULES_PATH = C:\Program Files\CodeProject\CodeProject.AI-Modules
12:38:57:MODULES_PATH = C:\Program Files\CodeProject\AI\modules
12:38:57:PYTHON_PATH = \bin\windows%PYTHON_NAME%\venv\Scripts\python
12:38:57:Data Dir = C:\ProgramData\CodeProject\AI
12:38:57:Server version: 2.9.5
12:38:57:ModuleRunner Start
12:38:57:Found a list of (initial) modules to install
12:38:57:No record of a previous module installation found. Running install
12:38:58:Starting Background AI Modules
12:39:01:Setting up initial modules. Please be patient...
12:39:01:Installing initial module ALPR.
12:39:01:Preparing to install module 'ALPR'
12:39:01:Downloading module 'ALPR'
12:39:01:Installing module 'ALPR'
12:39:01:Installer script at 'C:\Program Files\CodeProject\AI\setup.bat'
12:39:01:ALPR: Installing CodeProject.AI Analysis Module
12:39:01:ALPR: ======================================================================
12:39:01:ALPR: CodeProject.AI Installer
12:39:01:ALPR: ======================================================================
12:39:02:ALPR: 1141.8Gb of 1906Gb available on (No label) (Windows 11 x86_64 - windows)
12:39:02:ALPR: General CodeProject.AI setup
12:39:03:Server: This is the latest version
12:39:03:Current Version is 2.9.5
12:39:03:ALPR: Checking for VC++ Redist...v14 Present.
12:39:03:ALPR: Creating Directories...done
12:39:03:ALPR: GPU support
12:39:04:ALPR: CUDA Present...Yes (CUDA 12.7, No cuDNN found, CUDA Toolkit: false)
12:39:04:ALPR: ROCm Present...No
12:39:04:ALPR: Checking for .NET 9.0...Checking runtimes...All good. Found .NET aspnetcore 9
12:39:06:ALPR: Reading ALPR settings.......done
12:39:06:ALPR: Installing module License Plate Reader 3.3.4 (Internal)
12:39:06:ALPR: Installing Python 3.9
12:39:09:ALPR: Start-BitsTransfer : The connection with the server was terminated abnormally
12:39:09:ALPR: At line:1 char:1
12:39:09:ALPR: + Start-BitsTransfer -Source 'https://codeproject-ai-bunny.b-cdn.net/se ...
12:39:09:ALPR: + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
12:39:09:ALPR: + CategoryInfo : InvalidOperation: (:) [Start-BitsTransfer], Exception
12:39:09:ALPR: + FullyQualifiedErrorId : StartBitsTransferCOMException,Microsoft.BackgroundIntelligentTransfer.Management.NewBits
12:39:09:ALPR: TransferCommand
12:39:11:ALPR: Start-BitsTransfer : The connection with the server was terminated abnormally
12:39:11:ALPR: At line:1 char:1
12:39:11:ALPR: + Start-BitsTransfer -Source 'https://codeproject-ai-bunny.b-cdn.net/se ...
12:39:11:ALPR: + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
12:39:11:ALPR: + CategoryInfo : InvalidOperation: (:) [Start-BitsTransfer], Exception
12:39:11:ALPR: + FullyQualifiedErrorId : StartBitsTransferCOMException,Microsoft.BackgroundIntelligentTransfer.Management.NewBits
12:39:11:ALPR: TransferCommand
12:39:11:ALPR: Downloading Python 3.9 interpreter...BITS transfer failed. Trying Powershell....
12:39:45:ALPR: Expanding...done.
12:39:59:ALPR: Creating Virtual Environment (Local)...done
12:39:59:ALPR: Confirming we have Python 3.9 in our virtual environment...present
12:40:00:ALPR: Downloading ALPR models...Expanding...done.
12:40:01:ALPR: Copying contents of ocr-en-pp_ocrv4-paddle.zip to paddleocr...done
12:40:02:ALPR: Checking CPU compatibility...All good
12:40:02:ALPR: Installing Python packages for License Plate Reader
12:40:02:ALPR: �[0;Installing GPU-enabled libraries: If available
12:40:03:ALPR: Ensuring Python package manager (pip) is installed...done
12:40:15:ALPR: Ensuring Python package manager (pip) is up to date...done
12:40:15:ALPR: Python packages specified by requirements.windows.cuda12.txt
12:40:24:ALPR: - Installing NumPy, a package for scientific computing...(✅ checked) done
12:41:13:ALPR: - Installing PaddlePaddle, Parallel Distributed Deep Learning...(✅ checked) done
12:42:39:ALPR: - Installing PaddleOCR, the OCR toolkit based on PaddlePaddle...(✅ checked) done
12:42:41:ALPR: - Installing imutils, the image utilities library...(✅ checked) done
12:42:54:ALPR: - Installing the CodeProject.AI SDK...(✅ checked) done
12:42:54:ALPR: Scanning modulesettings for downloadable models...No models specified
12:42:54:ALPR: Executing post-install script for License Plate Reader
12:43:09:ALPR: W0117 12:43:09.765803 5764 dynamic_loader.cc:285] Note: [Recommend] copy cudnn into CUDA installation directory.
12:43:09:ALPR: For instance, download cudnn-10.0-windows10-x64-v7.6.5.32.zip from NVIDIA's official website,
12:43:09:ALPR: then, unzip it and copy it into C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0
12:43:09:ALPR: You should do this according to your CUDA installation directory and CUDNN version.
12:43:09:ALPR: Traceback (most recent call last):
12:43:09:ALPR: File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py", line 105, in
12:43:09:ALPR: ALPR_adapter().start_loop()
12:43:09:ALPR: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python39\venv\lib\site-packages\codeproject_ai_sdk\module_runner.py", line 278, in start_loop
12:43:09:ALPR: self.initialise()
12:43:09:ALPR: File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py", line 33, in initialise
12:43:09:ALPR: if paddle.device.get_cudnn_version() / 100.0 < self.opts.min_cuDNN_version:
12:43:09:ALPR: File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python39\venv\lib\site-packages\paddle\device_init_.py", line 179, in get_cudnn_version
12:43:09:ALPR: cudnn_version = int(core.cudnn_version())
12:43:09:ALPR: RuntimeError: (PreconditionNotMet) The third-party dynamic library (cudnn64_8.dll) that Paddle depends on is not configured correctly. (error code is 126)
12:43:09:ALPR: Suggestions:
12:43:09:ALPR: 1. Check if the third-party dynamic library (e.g. CUDA, CUDNN) is installed correctly and its version is matched with paddlepaddle you installed.
12:43:09:ALPR: 2. Configure third-party dynamic library environment variables as follows:
12:43:09:ALPR: - Linux: set LD_LIBRARY_PATH by
export LD_LIBRARY_PATH=...
12:43:09:ALPR: - Windows: set PATH by
set PATH=XXX; (at ..\paddle\phi\backends\dynload\dynamic_loader.cc:312) 12:43:10:ALPR: Self test: Self-test failed 12:43:10:ALPR: Module setup time 00:04:05.30 12:43:10:ALPR: Setup complete 12:43:10:ALPR: Total setup time 00:04:08.47 12:43:10:ALPR: SETUP FAILED: 12:43:10:ALPR: - [ALPR] Self test failed 12:43:10:Module ALPR installed successfully. 12:43:10:Running module using: C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python39\venv\Scripts\python 12:43:10: 12:43:10:Attempting to start ALPR with C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python39\venv\Scripts\python "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py" 12:43:10:Starting C:\Program Files...ws\python39\venv\Scripts\python "C:\Program Files...\modules\ALPR\ALPR_adapter.py" 12:43:10: 12:43:10:Module 'License Plate Reader' 3.3.4 (ID: ALPR) 12:43:10:Valid: True 12:43:10:Module Path: <root>\modules\ALPR 12:43:10:Module Location: Internal 12:43:10:AutoStart: True 12:43:10:Queue: alpr_queue 12:43:10:Runtime: python3.9 12:43:10:Runtime Location: Local 12:43:10:FilePath: ALPR_adapter.py 12:43:10:Start pause: 3 sec 12:43:10:Parallelism: 0 12:43:10:LogVerbosity: 12:43:10:Platforms: all,!windows-arm64 12:43:10:GPU Libraries: installed if available 12:43:10:GPU: use if supported 12:43:10:Accelerator: 12:43:10:Half Precision: enable 12:43:10:Environment Variables 12:43:10:AUTO_PLATE_ROTATE = True 12:43:10:CROPPED_PLATE_DIR = <root>\Server\wwwroot 12:43:10:MIN_COMPUTE_CAPABILITY = 6 12:43:10:MIN_CUDNN_VERSION = 7 12:43:10:OCR_OPTIMAL_CHARACTER_HEIGHT = 60 12:43:10:OCR_OPTIMAL_CHARACTER_WIDTH = 30 12:43:10:OCR_OPTIMIZATION = True 12:43:10:PLATE_CONFIDENCE = 0.7 12:43:10:PLATE_RESCALE_FACTOR = 2 12:43:10:PLATE_ROTATE_DEG = 0 12:43:10:REMOVE_SPACES = False 12:43:10:ROOT_PATH = <root> 12:43:10:SAVE_CROPPED_PLATE = False 12:43:10: 12:43:10:Started License Plate Reader module 12:43:10:Installer exited with code 1 12:43:10:Installing initial module ObjectDetectionYOLOv5Net. 12:43:10:Preparing to install module 'ObjectDetectionYOLOv5Net' 12:43:10:Downloading module 'ObjectDetectionYOLOv5Net' 12:43:10:Installing module 'ObjectDetectionYOLOv5Net' 12:43:10:Installer script at 'C:\Program Files\CodeProject\AI\setup.bat' 12:43:11: Installing CodeProject.AI Analysis Module 12:43:11:====================================================================== 12:43:11: CodeProject.AI Installer 12:43:11:====================================================================== 12:43:11:1138.0Gb of 1906Gb available on (No label) (Windows 11 x86_64 - windows) 12:43:11:General CodeProject.AI setup 12:43:11:Checking for VC++ Redist...v14 Present. 12:43:12:Creating Directories...done 12:43:12:GPU support 12:43:12:CUDA Present...Yes (CUDA 12.7, No cuDNN found, CUDA Toolkit: false) 12:43:12:ROCm Present...No 12:43:13:Module ALPR started successfully. 12:43:13:Checking for .NET 9.0...Checking runtimes...All good. Found .NET aspnetcore 9 12:43:15:ALPR_adapter.py: Running init for License Plate Reader 12:43:15:ALPR_adapter.py: W0117 12:43:15.111876 45528 dynamic_loader.cc:285] Note: [Recommend] copy cudnn into CUDA installation directory. 12:43:15:ALPR_adapter.py: For instance, download cudnn-10.0-windows10-x64-v7.6.5.32.zip from NVIDIA's official website, 12:43:15:ALPR_adapter.py: then, unzip it and copy it into C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v10.0 12:43:15:ALPR_adapter.py: You should do this according to your CUDA installation directory and CUDNN version. 12:43:15:ALPR_adapter.py: An exception occurred initialising the module: (PreconditionNotMet) The third-party dynamic library (cudnn64_8.dll) that Paddle depends on is not configured correctly. (error code is 126) 12:43:15:ALPR_adapter.py: Suggestions: 12:43:15:ALPR_adapter.py: 1. Check if the third-party dynamic library (e.g. CUDA, CUDNN) is installed correctly and its version is matched with paddlepaddle you installed. 12:43:15:ALPR_adapter.py: 2. Configure third-party dynamic library environment variables as follows: 12:43:15:ALPR_adapter.py: - Linux: set LD_LIBRARY_PATH by
export LD_LIBRARY_PATH=...12:43:15:ALPR_adapter.py: - Windows: set PATH by
set PATH=XXX; (at ..\paddle\phi\backends\dynload\dynamic_loader.cc:312)12:43:15:Reading ObjectDetectionYOLOv5Net settings.......done
12:43:15:Installing module Object Detection (YOLOv5 .NET) 1.14.0 (Internal)
12:43:21:Start-BitsTransfer : The connection with the server was terminated abnormally
12:43:21:At line:1 char:1
12:43:21:+ Start-BitsTransfer -Source 'https://codeproject-ai-bunny.b-cdn.net/se ...
12:43:21:+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
12:43:21: + CategoryInfo : InvalidOperation: (:) [Start-BitsTransfer], Exception
12:43:21: + FullyQualifiedErrorId : StartBitsTransferCOMException,Microsoft.BackgroundIntelligentTransfer.Management.NewBits
12:43:21: TransferCommand
12:43:23:Start-BitsTransfer : The connection with the server was terminated abnormally
12:43:23:At line:1 char:1
12:43:23:+ Start-BitsTransfer -Source 'https://codeproject-ai-bunny.b-cdn.net/se ...
12:43:23:+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
12:43:23: + CategoryInfo : InvalidOperation: (:) [Start-BitsTransfer], Exception
12:43:23: + FullyQualifiedErrorId : StartBitsTransferCOMException,Microsoft.BackgroundIntelligentTransfer.Management.NewBits
12:43:23: TransferCommand
12:43:23:Downloading ObjectDetectionYOLOv5Net-DirectML-1.14.0.zip...BITS transfer failed. Trying Powershell....
12:44:44:Expanding...done.
12:44:45:Copying contents of ObjectDetectionYOLOv5Net-DirectML-1.14.0.zip to bin...done
12:45:02:Downloading YOLO ONNX models...Expanding...done.
12:45:03:Copying contents of yolonet-models.zip to assets...done
12:45:04:Start-BitsTransfer : The connection with the server was terminated abnormally
12:45:04:At line:1 char:1
12:45:04:+ Start-BitsTransfer -Source 'https://codeproject-ai-bunny.b-cdn.net/se ...
12:45:04:+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
12:45:04: + CategoryInfo : InvalidOperation: (:) [Start-BitsTransfer], Exception
12:45:04: + FullyQualifiedErrorId : StartBitsTransferCOMException,Microsoft.BackgroundIntelligentTransfer.Management.NewBits
12:45:04: TransferCommand
12:45:05:Start-BitsTransfer : The connection with the server was terminated abnormally
12:45:05:At line:1 char:1
12:45:05:+ Start-BitsTransfer -Source 'https://codeproject-ai-bunny.b-cdn.net/se ...
12:45:05:+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
12:45:05: + CategoryInfo : InvalidOperation: (:) [Start-BitsTransfer], Exception
12:45:05: + FullyQualifiedErrorId : StartBitsTransferCOMException,Microsoft.BackgroundIntelligentTransfer.Management.NewBits
12:45:05: TransferCommand
12:45:05:Downloading Custom YOLO ONNX models...BITS transfer failed. Trying Powershell....
12:47:20:Expanding...done.
12:47:20:Copying contents of yolonet-custom-models.zip to custom-models...done
12:47:21:Scanning modulesettings for downloadable models...No models specified
12:47:24:ObjectDetectionYOLOv5Net: ObjectDetectionYOLOv5Net module started.
12:47:25:Self test: Self-test passed
12:47:25:Module setup time 00:04:12.07
12:47:25:Setup complete
12:47:25:Total setup time 00:04:14.60
12:47:25:Installer exited with code 0
12:47:25:Module install complete, but can't find the installed module
So it says it's installed YOLOv5 but then it's sat there for half an hour with
Installing Object Detection (YOLOv5 .NET)...
but nothing else showing up in the logs.
edit - restarted the service and yolov5 has started working - still get the same error
9:19:42:Response rec'd from Object Detection (YOLOv5 .NET) command 'custom' (...28e838) ['Found DayPlate'] took 70ms
09:19:42:Response rec'd from License Plate Reader command 'alpr' (...bfa50e)
09:19:42:License Plate Reader: [error] : Traceback (most recent call last):
File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py", line 53, in process
result = await detect_platenumber(self, self.opts, image)
File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR.py", line 242, in detect_platenumber
numpy_plate = cv2.resize(numpy_plate, None, fx = resize_width_factor,
cv2.error: OpenCV(4.11.0) D:\a\opencv-python\opencv-python\opencv\modules\imgproc\src\resize.cpp:4211: error: (-215:Assertion failed) inv_scale_x > 0 in function 'cv::resize'
The text was updated successfully, but these errors were encountered: