Filter predictions by class(es)
You can set a class filter before or after you run
Segment. By default, no classes are filtered.
To reset the class filter, use
FilterByClass FilterByClass[class] FilterByClass[class1, class2, ...]
class: The class(es) to filter by. Can be a single class or a list of classes.
The following example finds cats in an image called
Detect finds all the objects in the image. Then, a filter is applied so that only cats are used in future cells. Then, the cat predictions are displayed on the
house.jpg image that was loaded at the beginning of the example.
Load["./house.jpg"] Detect["cat"] SetConfidence Show