Description Usage Arguments Value Examples
Recognize faces in an image and return the most likely matches from a gallery.
| 1 2 | 
| image | An image of file type JPG, PNG, or BMP.
Can either be an url string or a local image processed with  | 
| gallery | A string containing the name of the gallery in which the image will be enrolled. | 
| min_head_scale | Set the ratio of the smallest face to look for in the input image. Accepts a value between .015 (1:64 scale) and .5 (1:2 scale). | 
| threshold | Likelihood (between 0 and 1) used to determine a valid facial match. Defaults to 0.6. | 
| max_num_results | The maximum number of potential matches that are returned. Defaults to 10. | 
| show_candidate_images | Whether to return temporary URLs for each potential match. Defaults to TRUE. | 
A dataframe with the potential matches for the input image. The likelihood of matches is given in column confidence.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 |  
facerec_init()
# enroll
finn_image <- 'https://upload.wikimedia.org/wikipedia/en/2/2a/Finn-Force_Awakens_%282015%29.png'
padme_image <- 'https://upload.wikimedia.org/wikipedia/en/e/ee/Amidala.png'
finn_face <- enroll(image = finn_image, subject_id = 'finn', gallery = 'starwars')
padme_face <- enroll(image = padme_image, subject_id = 'padme', gallery = 'starwars')
# recognize
finn_2 <- 'https://upload.wikimedia.org/wikipedia/commons/b/b6/John_Boyega_by_Gage_Skidmore.jpg'
finn_rec <- recognize(image = finn_2, gallery = 'starwars')
 | 
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.