<html> <head> <link rel="stylesheet" href="css/bootstrap.min.css" /> </head> <body> <h2>Remove Subject</h2> <i>This example removes all instances of a subject from a given gallery</i><br /> <?php //* * * * include the wrapper class include '../Kairos.php'; include 'assets/helper.php'; //* * * * sample api credentials (works for example) $app_id = 'e2a8eaa7'; $api_key = '4092e4a45070bca728644e9285f084b4'; //* * * * create a new instance and authenticate $Kairos = new Kairos($app_id, $api_key); /* In this example, we request a list of all galleries */ $gallery_id = 'people'; $subject_id = 'tyrion'; $response = $Kairos->removeSubjectFromGallery($subject_id, $gallery_id); echo '<br /><b>Response:</b><br />'; echo '<div class="text-left" style="padding:10px;border:1px solid rgba(51, 51, 51, 0.08);background-color: rgba(204, 204, 204, 0.26);"><br />'; echo format_json($response, true); echo '</div>'; ?> </body> </html>
<html> <head> <link rel="stylesheet" href="assets/css/bootstrap.min.css" /> </head> <body> <h2>List Subjects for Galleries</h2> <i>This example returns a list of subjects currently enrolled in a given gallery</i><br /> <?php //* * * * include the wrapper class include '../Kairos.php'; include 'assets/helper.php'; //* * * * sample api credentials (works for example) $app_id = 'e2a8eaa7'; $api_key = '4092e4a45070bca728644e9285f084b4'; //* * * * create a new instance and authenticate $Kairos = new Kairos($app_id, $api_key); /* In this example, we request a list of all galleries */ $gallery_id = "people"; $response = $Kairos->listSubjectsForGallery($gallery_id); echo '<br /><b>Response:</b><br />'; echo '<div class="text-left" style="padding:10px;border:1px solid rgba(51, 51, 51, 0.08);background-color: rgba(204, 204, 204, 0.26);"><br />'; echo format_json($response, true); echo '</div>'; ?> </body> </html>
<head> <link rel="stylesheet" href="css/bootstrap.min.css" /> </head> <body> <h2>Detecting Image Attributes Using Image Data</h2> <i>This example enrolls the following image</i><br /> <img src="assets/images/sample.jpg" /> <?php //* * * * include the wrapper class include '../Kairos.php'; include 'assets/helper.php'; //* * * * sample api credentials (works for example) $app_id = 'e2a8eaa7'; $api_key = '4092e4a45070bca728644e9285f084b4'; //* * * * create a new instance and authenticate $Kairos = new Kairos($app_id, $api_key); /* In this example, we enroll a subject into a gallery using a path to an image file. */ $image_path = 'assets/images/sample.jpg'; $image_data = imageDataFromFilePath($image_path); $options = array('selector' => 'FULL'); $response = $Kairos->detectImageWithData($image_data); echo '<br /><b>Response:</b><br />'; echo '<div class="text-left" style="padding:10px;border:1px solid rgba(51, 51, 51, 0.08);background-color: rgba(204, 204, 204, 0.26);"><br />'; echo format_json($response, true); echo '</div>'; ?> </body> </html>
<head> <link rel="stylesheet" href="css/bootstrap.min.css" /> </head> <body> <h2>Enrolling an Image Using Image Data</h2> <i>This example enrolls the following image</i><br /> <img src="assets/images/sample.jpg" /> <?php //* * * * include the wrapper class include '../Kairos.php'; include 'assets/helper.php'; //* * * * sample api credentials (works for example) $app_id = 'e2a8eaa7'; $api_key = '4092e4a45070bca728644e9285f084b4'; //* * * * create a new instance and authenticate $Kairos = new Kairos($app_id, $api_key); /* In this example, we enroll a subject into a gallery using base64 image data. */ $gallery_id = 'gallery1'; $subject_id = 'liz'; $image_path = 'assets/images/sample.jpg'; $image_data = imageDataFromFilePath($image_path); $response = $Kairos->enrollImageWithData($image_data, $gallery_id, $subject_id); echo '<br /><b>Response:</b><br />'; echo '<div class="text-left" style="padding:10px;border:1px solid rgba(51, 51, 51, 0.08);background-color: rgba(204, 204, 204, 0.26);"><br />'; echo format_json($response, true); echo '</div>'; ?> </body>
<head> <link rel="stylesheet" href="css/bootstrap.min.css" /> </head> <body> <h2>Enrolling an Image Using a File Path</h2> <i>This example enrolls the following image</i><br /> <img src="assets/images/sample.jpg" /> <?php //* * * * include the wrapper class include '../Kairos.php'; include 'assets/helper.php'; //* * * * sample api credentials (works for example) $app_id = 'e2a8eaa7'; $api_key = '4092e4a45070bca728644e9285f084b4'; //* * * * create a new instance and authenticate $Kairos = new Kairos($app_id, $api_key); /* In this example, we enroll a subject into a gallery using a path to an image file. */ $gallery_id = 'people'; $subject_id = 'liz2'; $image_path = 'assets/images/sample.jpg'; $response = $Kairos->enrollImageWithPath($image_path, $gallery_id, $subject_id); echo '<br /><b>Response:</b><br />'; echo '<div class="text-left" style="padding:10px;border:1px solid rgba(51, 51, 51, 0.08);background-color: rgba(204, 204, 204, 0.26);"><br />'; echo format_json($response, true); echo '</div>'; ?> </body> </html>
<html> <head> <link rel="stylesheet" href="css/bootstrap.min.css" /> </head> <body> <h2>Detecting Image Attributes Using a File Path</h2> <i>This example enrolls the following image</i><br /> <img src="assets/images/sample.jpg" /> <?php //* * * * include the wrapper class include '../Kairos.php'; include 'assets/helper.php'; //* * * * sample api credentials (works for example) $app_id = 'e2a8eaa7'; $api_key = '4092e4a45070bca728644e9285f084b4'; //* * * * create a new instance and authenticate $Kairos = new Kairos($app_id, $api_key); /* In this example, we enroll a subject into a gallery using a path to an image file. */ $image_path = 'assets/images/sample.jpg'; $response = $Kairos->detectImageWithPath($image_path); echo '<br /><b>Response:</b><br />'; echo '<div class="text-left" style="padding:10px;border:1px solid rgba(51, 51, 51, 0.08);background-color: rgba(204, 204, 204, 0.26);"><br />'; echo format_json($response, true); echo '</div>'; ?> </body> </html>
<html> <head> <link rel="stylesheet" href="assets/css/bootstrap.min.css" /> </head> <body> <h2>List Galleries</h2> <i>This example returns a list of galleries you created</i><br /> <?php //* * * * include the wrapper class include '../Kairos.php'; include 'assets/helper.php'; //* * * * sample api credentials (works for example) $app_id = 'e2a8eaa7'; $api_key = '4092e4a45070bca728644e9285f084b4'; //* * * * create a new instance and authenticate $Kairos = new Kairos($app_id, $api_key); /* In this example, we request a list of all galleries */ $response = $Kairos->listGalleries(); echo '<br /><b>Response:</b><br />'; echo '<div class="text-left" style="padding:10px;border:1px solid rgba(51, 51, 51, 0.08);background-color: rgba(204, 204, 204, 0.26);"><br />'; echo format_json($response, true); echo '</div>'; ?> </body> </html>