If I'm not mistaken, this is a gray area because no court or judge has ever contemplated this question before.
The general broad understanding is "No, it's not a strict requirement, but there are reasons to do so": https://softwareengineering.stackexchange.com/questions/125836/do-you-have-to-include-a-license-notice-with-every-source-file
That's OK. It's a bit like the Ur-Quan Masters project -- The code is open-source, but not everyone can play it with the non-open-source 3DO assets unless they already own a copy: https://wiki.uqm.stack.nl/The_Ur-Quan_Masters_Technical_FAQ#How_do_I_use_the_3DO_intro_and_victory_movies_in_the_game.3F
Anyway, by making your part open-source, you already make it much easier for others to achieve the object detection stuff!
Here's an even shorter and blunter license: http://www.wtfpl.net/about/ (altough you might be less likely to receive a pint when someone becomes rich from your work)
Note: "Public domain" has a specific meaning in copyright law, and it doesn't just mean "viewable by the public". If a work is said to be in the "public domain", that means either copyright has expired, or its authors have formally renounced their claim to copyright.
As @jacobson said, a piece of code can be publicly viewable but the viewers might not have permission to incorporate the code into their own work.
If you want to disclaim copyright (as opposed to using a license that says "I own this code, but you can do whatever you want with it"), see https://unlicense.org/
You can do it all in LabVIEW itself: