2.6.5 - can't get the License Plate Reader module to install

Tygunn

Getting comfortable
Dec 24, 2016
409
320
So, I've tried completely uninstalling CPAI 2.6.5 a few times now and I can't seem to get the ALPR module to install.

Here's the install logs for the module:
Code:
Reading ALPR settings.......done
Installing module License Plate Reader 3.2.2

Installing Python 3.9
Python 3.9 is already installed
Creating Virtual Environment (Local)...Virtual Environment already present
Confirming we have Python 3.9 in our virtual environment...present
Downloading ALPR models...already exists...Expanding...done.
Copying contents of ocr-en-pp_ocrv4-paddle.zip to paddleocr...done
Installing Python packages for License Plate Reader
Installing GPU-enabled libraries: If available
Ensuring Python package manager (pip) is installed...done
Ensuring Python package manager (pip) is up to date...done
Python packages specified by requirements.windows.cuda11_8.txt
  - Installing NumPy, a package for scientific computing...Already installed
  - Installing PaddlePaddle, Parallel Distributed Deep Learning...(❌ failed check) done
  - Installing PaddleOCR, the OCR toolkit based on PaddlePaddle...Already installed
  - Installing imutils, the image utilities library...Already installed
  - Installing Pillow, a Python Image Library...Already installed
  - Installing OpenCV, the Computer Vision library for Python...Already installed
  - Installing the CodeProject.AI SDK...Already installed
Installing Python packages for the CodeProject.AI Server SDK
Ensuring Python package manager (pip) is installed...done
Ensuring Python package manager (pip) is up to date...done
Python packages specified by requirements.txt
  - Installing Pillow, a Python Image Library...Already installed
  - Installing Charset normalizer...Already installed
  - Installing aiohttp, the Async IO HTTP library...Already installed
  - Installing aiofiles, the Async IO Files library...Already installed
  - Installing py-cpuinfo to allow us to query CPU info...Already installed
  - Installing Requests, the HTTP library...Already installed
Scanning modulesettings for downloadable models...No models specified
Executing post-install script for License Plate Reader
Applying PaddleOCR patch
        1 file(s) copied.
Self test: Traceback (most recent call last):
  File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py", line 11, in <module>
    from ALPR import init_detect_platenumber, detect_platenumber
  File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR.py", line 17, in <module>
    from paddleocr import PaddleOCR
  File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python39\venv\lib\site-packages\paddleocr\__init__.py", line 14, in <module>
    from .paddleocr import *
  File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python39\venv\lib\site-packages\paddleocr\paddleocr.py", line 21, in <module>
    import paddle
ModuleNotFoundError: No module named 'paddle'

And here's the startup:
Code:
2024-09-03 22:20:01: 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"
2024-09-03 22:20:01: Starting C:\Program Files...ws\python39\venv\Scripts\python "C:\Program Files...\modules\ALPR\ALPR_adapter.py"
2024-09-03 22:20:01: 
2024-09-03 22:20:01: ** Module 'License Plate Reader' 3.2.2 (ID: ALPR)
2024-09-03 22:20:01: ** Valid:            True
2024-09-03 22:20:01: ** Module Path:      &lt;root&gt;\modules\ALPR
2024-09-03 22:20:01: ** Module Location:  Internal
2024-09-03 22:20:01: ** AutoStart:        True
2024-09-03 22:20:01: ** Queue:            alpr_queue
2024-09-03 22:20:01: ** Runtime:          python3.9
2024-09-03 22:20:01: ** Runtime Location: Local
2024-09-03 22:20:01: ** FilePath:         ALPR_adapter.py
2024-09-03 22:20:01: ** Start pause:      3 sec
2024-09-03 22:20:01: ** Parallelism:      0
2024-09-03 22:20:01: ** LogVerbosity:
2024-09-03 22:20:01: ** Platforms:        all,!windows-arm64
2024-09-03 22:20:01: ** GPU Libraries:    installed if available
2024-09-03 22:20:01: ** GPU:              use if supported
2024-09-03 22:20:01: ** Accelerator:
2024-09-03 22:20:01: ** Half Precision:   enable
2024-09-03 22:20:01: ** Environment Variables
2024-09-03 22:20:01: ** AUTO_PLATE_ROTATE            = True
2024-09-03 22:20:01: ** CROPPED_PLATE_DIR            = &lt;root&gt;\Server\wwwroot
2024-09-03 22:20:01: ** MIN_COMPUTE_CAPABILITY       = 6
2024-09-03 22:20:01: ** MIN_CUDNN_VERSION            = 7
2024-09-03 22:20:01: ** OCR_OPTIMAL_CHARACTER_HEIGHT = 60
2024-09-03 22:20:01: ** OCR_OPTIMAL_CHARACTER_WIDTH  = 30
2024-09-03 22:20:01: ** OCR_OPTIMIZATION             = True
2024-09-03 22:20:01: ** PLATE_CONFIDENCE             = 0.7
2024-09-03 22:20:01: ** PLATE_RESCALE_FACTOR         = 2
2024-09-03 22:20:01: ** PLATE_ROTATE_DEG             = 0
2024-09-03 22:20:01: ** REMOVE_SPACES                = False
2024-09-03 22:20:01: ** ROOT_PATH                    = &lt;root&gt;
2024-09-03 22:20:01: ** SAVE_CROPPED_PLATE           = False
2024-09-03 22:20:01: 
2024-09-03 22:20:01: Started License Plate Reader module
2024-09-03 22:20:01: Installer exited with code 0
2024-09-03 22:20:02: ALPR_adapter.py: Traceback (most recent call last):
2024-09-03 22:20:02: ALPR_adapter.py:   File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR_adapter.py", line 11, in <module>
2024-09-03 22:20:02: ALPR_adapter.py:     from ALPR import init_detect_platenumber, detect_platenumber
2024-09-03 22:20:02: ALPR_adapter.py:   File "C:\Program Files\CodeProject\AI\modules\ALPR\ALPR.py", line 17, in <module>
2024-09-03 22:20:02: ALPR_adapter.py:     from paddleocr import PaddleOCR
2024-09-03 22:20:02: ALPR_adapter.py:   File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python39\venv\lib\site-packages\paddleocr\__init__.py", line 14, in <module>
2024-09-03 22:20:02: ALPR_adapter.py:     from .paddleocr import *
2024-09-03 22:20:02: ALPR_adapter.py:   File "C:\Program Files\CodeProject\AI\modules\ALPR\bin\windows\python39\venv\lib\site-packages\paddleocr\paddleocr.py", line 21, in <module>
2024-09-03 22:20:02: ALPR_adapter.py:     import paddle
2024-09-03 22:20:02: ALPR_adapter.py: ModuleNotFoundError: No module named 'paddle'
2024-09-03 22:20:02: ** Module ALPR has shutdown
2024-09-03 22:20:02: ALPR_adapter.py: has exited
2024-09-03 22:20:04: Module ALPR started successfully.

AFAIK I do have the required computer power for this:
Code:
CPUs:             Intel(R) Core(TM) i7-6700K CPU @ 4.00GHz (Intel)
                  1 CPU x 4 cores. 8 logical processors (x64)
GPU (Primary):    NVIDIA GeForce GTX 1080 (8 GiB) (NVIDIA) 
                  Driver: 522.06, CUDA: 11.8.89 (up to: 11.8), Compute: 6.1, cuDNN: 8.5

This worked in 2.6.2, but not so much in 2.6.5. Not clear what's up. Any hints appreciated.
 
To follow up on this. I installed the latest CUDA drivers and installed Cp.ai 2.8. I can now install the license plate module no issue. However as before I can't use the GPU for the license plate module. . I'll take it. At least it works.