Nneji123 / Automatic-License-Plate-Detection-Recognition-API

Automatic Vehicle Number Plate Detection and Recognition API
http://avnprapp.herokuapp.com
MIT License
14 stars 3 forks source link

Error run src/app.py #2

Open gersonmagan opened 1 year ago

gersonmagan commented 1 year ago

NFO: Will watch for changes in these directories: ['/home/gerson/www/python/reconocedorPlaca/src'] INFO: Uvicorn running on http://127.0.0.1:8000 (Press CTRL+C to quit) INFO: Started reloader process [15359] using WatchFiles INFO 2023-03-04 16:22:51,737 torch_utils.py:85] YOLOR 🚀 44a5886 torch 1.13.1+cu117 CPU

Process SpawnProcess-1: Traceback (most recent call last): File "./utils/google_utils.py", line 26, in attempt_download assets = [x['name'] for x in response['assets']] # release assets KeyError: 'assets'

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/usr/lib/python3.9/multiprocessing/process.py", line 315, in _bootstrap self.run() File "/usr/lib/python3.9/multiprocessing/process.py", line 108, in run self._target(*self._args, **self._kwargs) File "/home/gerson/.local/lib/python3.9/site-packages/uvicorn/_subprocess.py", line 76, in subprocess_started target(sockets=sockets) File "/home/gerson/.local/lib/python3.9/site-packages/uvicorn/server.py", line 60, in run return asyncio.run(self.serve(sockets=sockets)) File "/usr/lib/python3.9/asyncio/runners.py", line 44, in run return loop.run_until_complete(main) File "uvloop/loop.pyx", line 1517, in uvloop.loop.Loop.run_until_complete File "/home/gerson/.local/lib/python3.9/site-packages/uvicorn/server.py", line 67, in serve config.load() File "/home/gerson/.local/lib/python3.9/site-packages/uvicorn/config.py", line 477, in load self.loaded_app = import_from_string(self.app) File "/home/gerson/.local/lib/python3.9/site-packages/uvicorn/importer.py", line 21, in import_from_string module = importlib.import_module(module_str) File "/usr/lib/python3.9/importlib/init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1030, in _gcd_import File "", line 1007, in _find_and_load File "", line 986, in _find_and_load_unlocked File "", line 680, in _load_unlocked File "", line 790, in exec_module File "", line 228, in _call_with_frames_removed File "./app.py", line 12, in from detections import get_plates_from_image, get_text_from_image File "./detections.py", line 44, in model = attempt_load(weights, map_location=device) # load FP32 model File "./models/experimental.py", line 243, in attempt_load attempt_download(w) File "./utils/google_utils.py", line 31, in attempt_download tag = subprocess.check_output('git tag', shell=True).decode().split()[-1] IndexError: list index out of range ^CINFO: Stopping reloader process [15359]

Nneji123 commented 1 year ago

Did you download the model before running app.py?