ambianic / fall-detection

Python ML library for people fall detection
Apache License 2.0
83 stars 16 forks source link

[BUG] Fall detection saves debugging images at INFO level #3

Closed ivelin closed 3 years ago

ivelin commented 3 years ago

Describe the bug Currently the fall detection code saves debug images even if the log level is not DEBUG.

According to the python log level table, if the log level is equal or lower to DEBUG, the following if statement shall be true.

However it appears that the log level specified in the ambianic config.yaml file does not trickle down to the package level logger.

To Reproduce Run a fall detection test case that initializes the config at INFO. You will see that temporary images are written down to the file system.

Expected behavior Debug images should be only written to the file system if the log level is DEBUG or finer grained. Not when the log level is INFO, WARNING or above.

This bug needs to be fixed and covered with test cases for the CI.

ivelin commented 3 years ago

fixed