nextcloud / recognize

šŸ‘ šŸ‘‚ Smart media tagging for Nextcloud: recognizes faces, objects, landscapes, music genres
https://apps.nextcloud.com/apps/recognize
GNU Affero General Public License v3.0
553 stars 46 forks source link

Logging filled with "Warning recognize Exception Movinet does not support WASM mode" eventhough it is not enabled #1209

Closed phil-lipp closed 1 week ago

phil-lipp commented 2 weeks ago

Which version of recognize are you using?

8.1.1

Enabled Modes

Object recognition, Face recognition, Music recognition

TensorFlow mode

WASM mode

Downstream App

Memories App

Which Nextcloud version do you have installed?

30.0.0

Which Operating system do you have installed?

Debian 12 (Linux 6.1.0-26-amd64 x86_64)

Which database are you running Nextcloud on?

MariaDB 11.4.3

Which Docker container are you using to run Nextcloud? (if applicable)

v30.0.0

How much RAM does your server have?

8GB

What processor Architecture does your CPU have?

x86_64

Describe the Bug

I recently set up Nextcloud from scratch (using https://github.com/crazy-max/docker-nextcloud) and set up Recognize after fixing all setup errors. I enabled everything except for Video Recognition, but my log is still flooded with warnings about Movinet not being supported in WASM mode. I can't even enable or disable it in the administration settings for recognize so I'm assuming this is a bug.

Expected Behavior

When I don't enable Video Recognition, I shouldn't get a warning in the logs about it not being supported.

To Reproduce

Run Recognize in WASM mode, I guess.

Debug log

No response

github-actions[bot] commented 2 weeks ago

Hello :wave:

Thank you for taking the time to open this issue with recognize. I know it's frustrating when software causes problems. You have made the right choice to come here and open an issue to make sure your problem gets looked at and if possible solved. I try to answer all issues and if possible fix all bugs here, but it sometimes takes a while until I get to it. Until then, please be patient. Note also that GitHub is a place where people meet to make software better together. Nobody here is under any obligation to help you, solve your problems or deliver on any expectations or demands you may have, but if enough people come together we can collaborate to make this software better. For everyone. Thus, if you can, you could also look at other issues to see whether you can help other people with your knowledge and experience. If you have coding experience it would also be awesome if you could step up to dive into the code and try to fix the odd bug yourself. Everyone will be thankful for extra helping hands! One last word: If you feel, at any point, like you need to vent, this is not the place for it; you can go to the forum, to twitter or somewhere else. But this is a technical issue tracker, so please make sure to focus on the tech and keep your opinions to yourself. (Also see our Code of Conduct. Really.)

I look forward to working with you on this issue Cheers :blue_heart:

devnoname120 commented 2 weeks ago

Same problem here with Nextcloud All-in-One.

{
  "reqId": "M77KbARyLafsexL0GNyp",
  "level": 3,
  "time": "2024-10-18T17:12:06+00:00",
  "remoteAddr": "",
  "user": "--",
  "app": "core",
  "method": "",
  "url": "--",
  "message": "Error while running background job OCA\\Recognize\\BackgroundJobs\\ClassifyMovinetJob (id: 783951, arguments: {\"storageId\":8,\"rootId\":4221846})",
  "userAgent": "--",
  "version": "29.0.8.1",
  "exception": {
    "Exception": "OCA\\Recognize\\Exception\\Exception",
    "Message": "Movinet does not support WASM mode",
    "Code": 0,
    "Trace": [
      {
        "file": "/var/www/html/custom_apps/recognize/lib/BackgroundJobs/ClassifyMovinetJob.php",
        "line": 42,
        "function": "classify",
        "class": "OCA\\Recognize\\Classifiers\\Video\\MovinetClassifier",
        "type": "->",
        "args": [
          [
            [
              "OCA\\Recognize\\Db\\QueueFile",
              2839
            ],
            [
              "OCA\\Recognize\\Db\\QueueFile",
              2840
            ],
            [
              "OCA\\Recognize\\Db\\QueueFile",
              2841
            ]
          ]
        ]
      },
      {
        "file": "/var/www/html/custom_apps/recognize/lib/BackgroundJobs/ClassifierJob.php",
        "line": 73,
        "function": "classify",
        "class": "OCA\\Recognize\\BackgroundJobs\\ClassifyMovinetJob",
        "type": "->",
        "args": [
          [
            [
              "OCA\\Recognize\\Db\\QueueFile",
              2839
            ],
            [
              "OCA\\Recognize\\Db\\QueueFile",
              2840
            ],
            [
              "OCA\\Recognize\\Db\\QueueFile",
              2841
            ]
          ]
        ]
      },
      {
        "file": "/var/www/html/custom_apps/recognize/lib/BackgroundJobs/ClassifyMovinetJob.php",
        "line": 33,
        "function": "runClassifier",
        "class": "OCA\\Recognize\\BackgroundJobs\\ClassifierJob",
        "type": "->",
        "args": [
          "movinet",
          [
            8,
            4221846
          ]
        ]
      },
      {
        "file": "/var/www/html/lib/public/BackgroundJob/Job.php",
        "line": 80,
        "function": "run",
        "class": "OCA\\Recognize\\BackgroundJobs\\ClassifyMovinetJob",
        "type": "->",
        "args": [
          [
            8,
            4221846
          ]
        ]
      },
      {
        "file": "/var/www/html/lib/public/BackgroundJob/TimedJob.php",
        "line": 102,
        "function": "start",
        "class": "OCP\\BackgroundJob\\Job",
        "type": "->",
        "args": [
          [
            "OC\\BackgroundJob\\JobList"
          ]
        ]
      },
      {
        "file": "/var/www/html/lib/public/BackgroundJob/TimedJob.php",
        "line": 92,
        "function": "start",
        "class": "OCP\\BackgroundJob\\TimedJob",
        "type": "->",
        "args": [
          [
            "OC\\BackgroundJob\\JobList"
          ]
        ]
      },
      {
        "file": "/var/www/html/cron.php",
        "line": 177,
        "function": "execute",
        "class": "OCP\\BackgroundJob\\TimedJob",
        "type": "->",
        "args": [
          [
            "OC\\BackgroundJob\\JobList"
          ]
        ]
      }
    ],
    "File": "/var/www/html/custom_apps/recognize/lib/Classifiers/Video/MovinetClassifier.php",
    "Line": 37,
    "message": "Error while running background job OCA\\Recognize\\BackgroundJobs\\ClassifyMovinetJob (id: 783951, arguments: {\"storageId\":8,\"rootId\":4221846})",
    "exception": [],
    "CustomMessage": "Error while running background job OCA\\Recognize\\BackgroundJobs\\ClassifyMovinetJob (id: 783951, arguments: {\"storageId\":8,\"rootId\":4221846})"
  },
  "id": "67129720c7102"
}

My configuration:

My settings:

Image

devnoname120 commented 2 weeks ago

And it cannot be manually disabled because the checkbox is grayed out when using WASM mode (settings['tensorflow.purejs']):

https://github.com/nextcloud/recognize/blob/3db9784d6e020ff8966f77c1a85aeadfcffcfdc0/src/components/ViewAdmin.vue#L181-L183

Image

The solution is to either temporarily disable WASM mode, disable video recognition, re-enable WASM mode, or just run the following occ command:

occ config:app:set --value false recognize movinet.enabled
marcelklehr commented 1 week ago

Ah, that makes sense, I'll change this to allow disabling even when movinet cannot be enabled.