AzureVision (version 1.0.2)

add_tags: Add, retrieve and remove tags for a project

Description

Add, retrieve and remove tags for a project

Usage

add_tags(project, tags)

add_negative_tag(project, negative_name = "_negative_")

list_tags(project, as = c("names", "ids", "dataframe", "list"), iteration = NULL)

get_tag(project, name = NULL, id = NULL, iteration = NULL)

remove_tags(project, tags, confirm = TRUE)

Arguments

project

A Custom Vision project.

tags

For add_tags, a vector of strings to treat as tags.

negative_name

For add_negative_tag, the label to provide a negative tag. See 'Negative tags' below.

as

For list_tags, the format in which to return results: a vector of tag names, a vector of tag IDs, a data frame of metadata, or a list of metadata.

iteration

For list_tags and get_tag, the iteration ID (roughly, which model generation to use). Defaults to the latest iteration.

name, id

For get_tag, the name (text string) for a tag, and its ID. Provide one or the other, but not both.

confirm

For remove_tags, whether to ask for confirmation first.

Value

add_tags and add_negative_tag return a data frame containing the names and IDs of the tags added.

Negative tags

A negative tag is a special tag that represents the absence of any other tag. For example, if a project is classifying images into cats and dogs, an image that doesn't contain either a cat or dog should be given a negative tag. This can be distinguished from an untagged image, where there is no information at all on what it contains.

You can add a negative tag to a project with the add_negative_tag method. Once defined, a negative tag is treated like any other tag. A project can only have one negative tag defined.

Details

Tags are the labels attached to images for use in classification projects. An image can have one or multiple tags associated with it; however, the latter only makes sense if the project is setup for multi-label classification.

Tags form part of the metadata for a Custom Vision project, and have to be explicitly defined prior to use. Each tag has a corresponding ID which is used to manage it. In general, you can let AzureVision handle the details of managing tags and tag IDs.

See Also

add_image_tags, remove_image_tags

Examples

Run this code
# NOT RUN {
add_tags(myproj, "newtag")
add_negative_tag(myproj)
remove_tags(myproj, "_negative_")
add_negative_tag(myproj, "nothing")

# }

Run the code above in your browser using DataCamp Workspace