Skip to content
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

Set the environment variable HYDRA_FULL_ERROR=1 for a complete stack trace. #6

Open
suki1504 opened this issue Sep 9, 2023 · 1 comment

Comments

@suki1504
Copy link

suki1504 commented Sep 9, 2023

I am getting the below error, kindly help us to resovle the error.
$ python predict.py model='best.pt' source='demo.mp4'
################$$$$$$$$$$$$$$$$$$
/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/ultralytics
/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/ultralytics/assets
WARNING ⚠️ 'ultralytics.yolo.v8' is deprecated since '8.0.136' and will be removed in '8.1.0'. Please use 'ultralytics.models.yolo' instead.
WARNING ⚠️ 'ultralytics.yolo.engine' is deprecated since '8.0.136' and will be removed in '8.1.0'. Please use 'ultralytics.engine' instead.
WARNING ⚠️ 'ultralytics.yolo.utils' is deprecated since '8.0.136' and will be removed in '8.1.0'. Please use 'ultralytics.utils' instead.
Note this warning may be related to loading older models. You can update your model to current structure with:
import torch
ckpt = torch.load("model.pt") # applies to both official and custom models
torch.save(ckpt, "updated-model.pt")

Neither CUDA nor MPS are available - defaulting to CPU. Note: This module is much faster with a GPU.
Primary config directory not found.
Check that the config directory '/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/ultralytics/yolo/configs' exists and readable

Set the environment variable HYDRA_FULL_ERROR=1 for a complete stack trace.

@suki1504
Copy link
Author

suki1504 commented Sep 9, 2023

After setting HYDRA_FULL_ERROR=1

$ python predict.py model='best.pt' source='demo.mp4'
################$$$$$$$$$$$$$$$$$$
/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/ultralytics
/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/ultralytics/assets
WARNING ⚠️ 'ultralytics.yolo.v8' is deprecated since '8.0.136' and will be removed in '8.1.0'. Please use 'ultralytics.models.yolo' instead.
WARNING ⚠️ 'ultralytics.yolo.engine' is deprecated since '8.0.136' and will be removed in '8.1.0'. Please use 'ultralytics.engine' instead.
WARNING ⚠️ 'ultralytics.yolo.utils' is deprecated since '8.0.136' and will be removed in '8.1.0'. Please use 'ultralytics.utils' instead.
Note this warning may be related to loading older models. You can update your model to current structure with:
import torch
ckpt = torch.load("model.pt") # applies to both official and custom models
torch.save(ckpt, "updated-model.pt")

Neither CUDA nor MPS are available - defaulting to CPU. Note: This module is much faster with a GPU.
Traceback (most recent call last):
File "/home/harry/Documents/Automatic_Number_Plate_Detection_Recognition_YOLOv8/ultralytics/yolo/v8/detect/predict.py", line 118, in
predict()
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/main.py", line 94, in decorated_main
_run_hydra(
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/utils.py", line 394, in _run_hydra
_run_app(
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/utils.py", line 457, in _run_app
run_and_report(
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/utils.py", line 223, in run_and_report
raise ex
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/utils.py", line 220, in run_and_report
return func()
^^^^^^
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/utils.py", line 458, in
lambda: hydra.run(
^^^^^^^^^^
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/hydra.py", line 105, in run
cfg = self.compose_config(
^^^^^^^^^^^^^^^^^^^^
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/hydra.py", line 594, in compose_config
cfg = self.config_loader.load_configuration(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/config_loader_impl.py", line 142, in load_configuration
return self._load_configuration_impl(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/config_loader_impl.py", line 243, in _load_configuration_impl
self.ensure_main_config_source_available()
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/config_loader_impl.py", line 129, in ensure_main_config_source_available
self._missing_config_error(
File "/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/hydra/_internal/config_loader_impl.py", line 102, in _missing_config_error
raise MissingConfigException(
hydra.errors.MissingConfigException: Primary config directory not found.
Check that the config directory '/home/harry/anaconda3/envs/sahara/lib/python3.11/site-packages/ultralytics/yolo/configs' exists and readable

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant