ZoneMinder / zmeventnotification

Machine Learning powered Secure Websocket & MQTT based ZoneMinder event notification server
408 stars 128 forks source link

Python Future problem #410

Open PhilippeRaven opened 2 years ago

PhilippeRaven commented 2 years ago

Event Server version

6.1.28

Hooks version (if you are using Object Detection)

Can't get it because of python future problem.

Are you using MLAPI? (Y/N) Nope.

The version of ZoneMinder you are using:

1.34.26

What is the nature of your issue

Pretty straight, after installing hooks, I'm trying to use the detection I've got a python future error. Future 0.18.2 (last version) on Ubuntu 20.04 installed from repository (and tried from pip3).

Debug Logs (if applicable)

root@zm# sudo -u www-data /var/lib/zmeventnotification/bin/zm_event_start.sh 18723 1
Traceback (most recent call last):
  File "/var/lib/zmeventnotification/bin/zm_detect.py", line 27, in <module>
    import zmes_hook_helpers.utils as utils
  File "/usr/local/lib/python3.8/dist-packages/zmes_hook_helpers/utils.py", line 22, in <module>
    standard_library.install_aliases()
AttributeError: module 'future.standard_library' has no attribute 'install_aliases'

Thanks for help :)

PhilippeRaven commented 2 years ago

Bump :)

baudneo commented 2 years ago

Try removing line 22 of /usr/local/lib/python3.8/dist-packages/zmes_hook_helpers/utils.py That may take care of the issue for now.

PhilippeRaven commented 2 years ago

Hi @baudneo thanks, but now I got this error instead : Traceback (most recent call last): File "/var/lib/zmeventnotification/bin/zm_detect.py", line 30, in <module> from pyzm import __version__ as pyzm_version ImportError: cannot import name '__version__' from 'pyzm' (/usr/local/lib/python3.8/dist-packages/pyzm/__init__.py)

Can somebody confirm that an Intel Movidius MyriadX 2 can work with hooks ? Maybe I'm trying things that can't even work. Thanks !

baudneo commented 2 years ago

I am not certain about the Intel stick, but I doubt it. CPU will work it's just slower.

There seems to be something misconfigured with your system. I would recommend backing up your configs and reinstalling ZMES. You shouldn't be seeing either of those errors, especially the pyzm_version one.

connortechnology commented 2 years ago

I don't think anyone has tried to make the movidius work. I have one, but never got around to testing it with ES. Should be trivial though.

baudneo commented 2 years ago

Depends on the hardware version I think. I did some reading up on it and it seems you can run yolov3 on it with some work. When I get a moment I will research it some more and see what it would take.

PhilippeRaven commented 2 years ago

Thanks for answers. I restored my backup of my regular ZM setup at the moment, don't have time right now to retry the setup with the Movidius.

For information, I took a Movidius because it's IMPOSSIBLE to get my hands on a Google Coral TPU. So if somebody can try to run ZMES with the Movidius (et heavenly document how to make it work) that'd be great :)

stale[bot] commented 2 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

PhilippeRaven commented 2 years ago

So I guess there'll be no support of Movidius in ZMES in the future ?

connortechnology commented 2 years ago

Some day. No one is paying for it and unfortunately, being broke, I need to spend my time generating incoming instead of playing with my movidius.

PhilippeRaven commented 2 years ago

Well I understand you @connortechnology . As it's totally impossible to get a Coral TPU, I guess I'll wait to upgrade my machine to get more powerful CPUs.