TensorFlow image_processing component#7083
Conversation
8acd9cb to
cafb1ed
Compare
frenck
left a comment
There was a problem hiding this comment.
@hunterjm I've reviewed your PR and left some initial comments.
I'm also kinda against the installation instructions for TensorFlow.
e.g.:
- Some people use
venv? - Some people Hass.io?
- How about none 64 bits installations? ARM64?
- What if versions need upgrading? (e.g., on
protobuf)? Who maintains the docs?
I think in general, we should avoid being an instruction manual for third-party software.
If you could take a look? 👍
|
@frenck - Thank you for the feedback. The detailed instructions are for those using hassbian or venv. @arsaboo is running a venv and they were initially put together to help him set it up. If approved, I would eventually plan to have it pre-configured in the Hass.io image as well. Currently I am running Hass.io on a NUC8 and have just replaced the home-assistant image with one that was built from my modifications to the Dockerfile. Google does not release a TensorFlow wheel for alpine linux, so that installation becomes more complicated, but I believe it can be tackled as a separate PR. They do have ARM images compatible with the Raspberry Pi. The install script is specific to x86_64. Maybe instead of providing a script I can outline the dependencies? I felt that leaving it out entirely would create too much confusion, and it really isn't that difficult to setup, but you would need to sort through multiple documents in the tensorflow/models repo to figure it out yourself. As far as upgrades/versioning, protobuf is just used to build the python models from the protos since TensorFlow is a multi-language library. We could pin the commit to download, the Detection Model Zoo version, and the TensorFlow wheel version in the documentation to have a working version as long as those resources are still available, even if some get updated. Thoughts? |
|
I think for this PR, we can include brief instructions. We only need instructions for Tensorflow installation (based on the system) and then list the files/dependencies that are required. The detailed instructions (e.g., |
|
What about simply linking to this? Then providing basic instructions on what to do after? The problem is only half of that is relevant for this use case. |
|
I agree that HA specific instructions are preferable to linking to an external site with extraneous info which will cause confusion. However these instructions could be hosted on a gist as @arsaboo suggested. For opencv I usually |
…. Update to have tensorflow in root config directory
…tion, add warning at top for Hass.io
|
Comments addressed. I also added a warning to let Hass.io users know that this component will not work out of the box with their setup, and linked to the system requirements of TensorFlow. |
|
Finished testing on Hassbian - updated warning to reflect additional package requirements. |
|
@hunterjm I added a couple of minor comments. I wouldn't worry too much about getting these docs perfect, as we will get a lot of useful feedback when the component is released to the community. One final comment, we are here using |
|
Looks good to me. |
|
Looks good to me. @frenck comments are addressed as well (as most of those are install related). I will merge this tomorrow, unless there are some residual concerns. |
* initial documentation for image_processing.tensorflow * add raw tag to fix template errors * changes per review * update documentation to reflect latest component changes and pull script out to gist * do not use deps folder as default, as it should only be managed by HA. Update to have tensorflow in root config directory * make gist a link, remove additional deps references * add additional cameras to example config, shorten model selection section, add warning at top for Hass.io * Update warning adding further Hassbian instructions * changes per PR review * fix init location in docs * fix spelling of raspberry * Update image_processing.tensorflow.markdown * Minor changes * Add class * add link to tensorflow install site for additional installation options
Description:
Adding a TensorFlow Object Detection image_processing component to run either pre-trained or custom built machine learning object detection models through TensorFlow and expose the results to Home Assistant.
Pull request in home-assistant (if applicable): home-assistant/core#17795
Checklist:
nextis for changes and new documentation that will go public with the next home-assistant release. Fixes, changes and adjustments for the current release should be created againstcurrent.