From 1a59f0a217261a643c2b654ccf9db59f8bd9b831 Mon Sep 17 00:00:00 2001 From: Sebastian Schmidt Date: Thu, 10 Nov 2022 15:54:50 -0800 Subject: [PATCH] Prevent renaming of properties used in API PiperOrigin-RevId: 487661625 --- mediapipe/tasks/web/components/containers/category.d.ts | 2 +- .../web/components/containers/classification_result.d.ts | 2 +- mediapipe/tasks/web/components/containers/landmark.d.ts | 2 +- mediapipe/tasks/web/core/base_options.d.ts | 2 +- mediapipe/tasks/web/core/classifier_options.d.ts | 2 +- mediapipe/tasks/web/core/wasm_loader_options.d.ts | 2 +- .../vision/gesture_recognizer/gesture_recognizer_options.ts | 2 +- .../vision/gesture_recognizer/gesture_recognizer_result.ts | 2 +- .../web/vision/object_detector/object_detector_result.ts | 4 ++-- 9 files changed, 10 insertions(+), 10 deletions(-) diff --git a/mediapipe/tasks/web/components/containers/category.d.ts b/mediapipe/tasks/web/components/containers/category.d.ts index 0da8a061..8ab8e6b8 100644 --- a/mediapipe/tasks/web/components/containers/category.d.ts +++ b/mediapipe/tasks/web/components/containers/category.d.ts @@ -15,7 +15,7 @@ */ /** A classification category. */ -export interface Category { +export declare interface Category { /** The probability score of this label category. */ score: number; diff --git a/mediapipe/tasks/web/components/containers/classification_result.d.ts b/mediapipe/tasks/web/components/containers/classification_result.d.ts index 33632f92..30590ab4 100644 --- a/mediapipe/tasks/web/components/containers/classification_result.d.ts +++ b/mediapipe/tasks/web/components/containers/classification_result.d.ts @@ -17,7 +17,7 @@ import {Category} from '../../../../tasks/web/components/containers/category'; /** Classification results for a given classifier head. */ -export interface Classifications { +export declare interface Classifications { /** * The array of predicted categories, usually sorted by descending scores, * e.g., from high to low probability. diff --git a/mediapipe/tasks/web/components/containers/landmark.d.ts b/mediapipe/tasks/web/components/containers/landmark.d.ts index 9a1badbb..f790d8a0 100644 --- a/mediapipe/tasks/web/components/containers/landmark.d.ts +++ b/mediapipe/tasks/web/components/containers/landmark.d.ts @@ -20,7 +20,7 @@ * dimension of image, and the coordinates values are in the range of [0,1]. * Otherwise, it represenet a point in world coordinates. */ -export class Landmark { +export declare class Landmark { /** The x coordinates of the landmark. */ x: number; diff --git a/mediapipe/tasks/web/core/base_options.d.ts b/mediapipe/tasks/web/core/base_options.d.ts index 54a59a21..86635b8c 100644 --- a/mediapipe/tasks/web/core/base_options.d.ts +++ b/mediapipe/tasks/web/core/base_options.d.ts @@ -17,7 +17,7 @@ // Placeholder for internal dependency on trusted resource url /** Options to configure MediaPipe Tasks in general. */ -export interface BaseOptions { +export declare interface BaseOptions { /** * The model path to the model asset file. Only one of `modelAssetPath` or * `modelAssetBuffer` can be set. diff --git a/mediapipe/tasks/web/core/classifier_options.d.ts b/mediapipe/tasks/web/core/classifier_options.d.ts index 356643c5..3dec8d27 100644 --- a/mediapipe/tasks/web/core/classifier_options.d.ts +++ b/mediapipe/tasks/web/core/classifier_options.d.ts @@ -17,7 +17,7 @@ import {BaseOptions} from '../../../tasks/web/core/base_options'; /** Options to configure the Mediapipe Classifier Task. */ -export interface ClassifierOptions { +export declare interface ClassifierOptions { /** Options to configure the loading of the model assets. */ baseOptions?: BaseOptions; diff --git a/mediapipe/tasks/web/core/wasm_loader_options.d.ts b/mediapipe/tasks/web/core/wasm_loader_options.d.ts index 1925aaf0..74436583 100644 --- a/mediapipe/tasks/web/core/wasm_loader_options.d.ts +++ b/mediapipe/tasks/web/core/wasm_loader_options.d.ts @@ -17,7 +17,7 @@ // Placeholder for internal dependency on trusted resource url /** An object containing the locations of all Wasm assets */ -export interface WasmLoaderOptions { +export declare interface WasmLoaderOptions { /** The path to the Wasm loader script. */ wasmLoaderPath: string; /** The path to the Wasm binary. */ diff --git a/mediapipe/tasks/web/vision/gesture_recognizer/gesture_recognizer_options.ts b/mediapipe/tasks/web/vision/gesture_recognizer/gesture_recognizer_options.ts index 16169a93..45601a74 100644 --- a/mediapipe/tasks/web/vision/gesture_recognizer/gesture_recognizer_options.ts +++ b/mediapipe/tasks/web/vision/gesture_recognizer/gesture_recognizer_options.ts @@ -18,7 +18,7 @@ import {BaseOptions} from '../../../../tasks/web/core/base_options'; import {ClassifierOptions} from '../../../../tasks/web/core/classifier_options'; /** Options to configure the MediaPipe Gesture Recognizer Task */ -export interface GestureRecognizerOptions { +export declare interface GestureRecognizerOptions { /** Options to configure the loading of the model assets. */ baseOptions?: BaseOptions; diff --git a/mediapipe/tasks/web/vision/gesture_recognizer/gesture_recognizer_result.ts b/mediapipe/tasks/web/vision/gesture_recognizer/gesture_recognizer_result.ts index cccdfaf6..08c8c293 100644 --- a/mediapipe/tasks/web/vision/gesture_recognizer/gesture_recognizer_result.ts +++ b/mediapipe/tasks/web/vision/gesture_recognizer/gesture_recognizer_result.ts @@ -20,7 +20,7 @@ import {Landmark} from '../../../../tasks/web/components/containers/landmark'; /** * Represents the gesture recognition results generated by `GestureRecognizer`. */ -export interface GestureRecognitionResult { +export declare interface GestureRecognitionResult { /** Hand landmarks of detected hands. */ landmarks: Landmark[][]; diff --git a/mediapipe/tasks/web/vision/object_detector/object_detector_result.ts b/mediapipe/tasks/web/vision/object_detector/object_detector_result.ts index 7b262113..e9e3843b 100644 --- a/mediapipe/tasks/web/vision/object_detector/object_detector_result.ts +++ b/mediapipe/tasks/web/vision/object_detector/object_detector_result.ts @@ -17,7 +17,7 @@ import {Category} from '../../../../tasks/web/components/containers/category'; /** An integer bounding box, axis aligned. */ -export interface BoundingBox { +export declare interface BoundingBox { /** The X coordinate of the top-left corner, in pixels. */ originX: number; /** The Y coordinate of the top-left corner, in pixels. */ @@ -29,7 +29,7 @@ export interface BoundingBox { } /** Represents one object detected by the `ObjectDetector`. */ -export interface Detection { +export declare interface Detection { /** A list of `Category` objects. */ categories: Category[];