recognize
recognize copied to clipboard
Check for Tensorflow requirements failing wrongly?
Which version of recognize are you using?
5.0.3
Enabled Modes
Face recognition
TensorFlow mode
Normal mode
Downstream App
Memories App
Which Nextcloud version do you have installed?
27.1.6
Which Operating system do you have installed?
Ubuntu 22.04
Which database are you running Nextcloud on?
MariaDB 10.11
Which Docker container are you using to run Nextcloud? (if applicable)
No response
How much RAM does your server have?
16GiB
What processor Architecture does your CPU have?
x86_64
Describe the Bug
Tensorflow admin settings doesn't recognize system support. But:
- CPU supports AVX an is x86
- GlibC is installed
- Not using containers
So i've runned the test on CLI:
# ./apps/recognize/bin/node /apps/recognize/src/test_libtensorflow.js
It outputs:
I tensorflow/core/platform/cpu_feature_guard.cc:193] This TensorFlow binary is optimized with one API Deep Neural Network Library (oneDNN) to use the following CPU instructions in performance-critical operations: AVX2 FMA To enable them in other operations, rebuild TensorFlow with the appropriate compiler flags.
This is not an error, but could the app wrongly detect it as so?
https://github.com/nextcloud/recognize/blob/4a18d64fe1117db26077cdfc389c5198fe42fff1/lib/Controller/AdminController.php#L231-L243
Maybe \Throwable will catch it?
https://stackoverflow.com/questions/35911252/disable-tensorflow-debugging-information/42121886#42121886
Expected Behavior
Detect Tensorflow settings.
Also (hint), having an occ recognize:system-checks command would be a great addition to performa and debug all checks manually.
To Reproduce
See steps above.
Debug log
No response
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:
When i execute the functions manually, all conditions are met:
avx => true,
platform => 'x86_64',
musl => false
So this should be met:
https://github.com/nextcloud/recognize/blob/4a18d64fe1117db26077cdfc389c5198fe42fff1/src/components/ViewAdmin.vue#L240-L242
AVX:
object(JSONResponse)#2 (1) {
["data":"JSONResponse":private]=>
array(1) {
["avx"]=>
bool(true)
}
}
Platform:
object(JSONResponse)#2 (1) {
["data":"JSONResponse":private]=>
array(1) {
["platform"]=>
string(6) "x86_64"
}
}
Musl:
object(JSONResponse)#2 (1) {
["data":"JSONResponse":private]=>
array(1) {
["musl"]=>
bool(false)
}
}
I have a very similar issue running under NC snap - could be related? #1120
It's expected that the test might not always work. Especially the AVX check will sometimes fail because the php process isn't allowed to access the unix path in question. So, if you are reasonably convinced that your machine supports native execution, you can simply disable WASM mode manually and check if it works.