DetectedCandidate

A food candidate detected from visual scanning

AttributeDescription

passioID

The ID of the detected item.

confidence

Confidence of the classification candidate, ranging from 0.0 to 1.0.

boundingBox

A box describing a detected object's location in the camera view.

amountEstimate

Scanned AmountEstimate (supported only in iOS) (optional).

foodName

The nutritional data for this item in the database (optional).

alternatives

Related items above this item in the food hierarchy (more generic) as an array of DetectedCandidate objects, or null (optional).

croppedImage

Cropped images related to the detected item as an array of ImagesInfo objects, or null (optional).


export interface DetectedCandidate {
  /**
   * The ID of the detected item
   */
  passioID: PassioID

  /**
   * Confidence of the classification candidate, ranging from 0.0 to 1.0
   */
  confidence: number

  /**
   * A box describing a detected object's location in the camera view
   */
  boundingBox: BoundingBox

  /**
   * Supported only in IOS
   * Scanned AmountEstimate
   */
  amountEstimate?: AmountEstimate

  /**
   * The nutritional data for this item in the database
   */
  foodName?: string

  /**
   * Related items above this item in the food heirarchy (more generic)
   */
  alternatives?: DetectedCandidate[] | null

  croppedImage?: ImagesInfo[] | null
}

Last updated