# TinyFaceDetector | @vladmandic/face-api - v1.7.6
Documentation for @vladmandic/face-api - v1.7.6

# Class TinyFaceDetector

#### Hierarchy

- TinyYolov2Base
  - TinyFaceDetector

- Defined in tinyFaceDetector/TinyFaceDetector.ts:11

#####
Index

### Constructors

constructor

### Properties

_name
DEFAULT_FILTER_SIZES

### Accessors

anchors
boxEncodingSize
config
isLoaded
paramMappings
params
withClassScores

### Methods

detect
dispose
extractWeights
forward
forwardInput
freeze
getFrozenParams
getParamFromPath
getParamList
getTrainableParams
load
loadFromDisk
loadFromUri
loadFromWeightMap
locateFaces
reassignParamFromPath
runMobilenet
runTinyYolov2
serializeParams
variable

## Constructors

### constructor

- new TinyFaceDetector(): TinyFaceDetector

- #### Returns TinyFaceDetector

  Overrides TinyYolov2Base.constructor

  - Defined in tinyFaceDetector/TinyFaceDetector.ts:12

## Properties

### _name

_name: any

Inherited from TinyYolov2Base._name

- Defined in NeuralNetwork.ts:17

### `Static` DEFAULT_FILTER_SIZES

DEFAULT_FILTER_SIZES: number[] = ...

Inherited from TinyYolov2Base.DEFAULT_FILTER_SIZES

- Defined in tinyYolov2/TinyYolov2Base.ts:25

## Accessors

### anchors

- get anchors(): Point []

- #### Returns Point []

  - Defined in tinyFaceDetector/TinyFaceDetector.ts:26

### boxEncodingSize

- get boxEncodingSize(): number

- #### Returns number

  Inherited from TinyYolov2Base.boxEncodingSize

  - Defined in tinyYolov2/TinyYolov2Base.ts:43

### config

- get config(): TinyYolov2Config

- #### Returns TinyYolov2Config

  Inherited from TinyYolov2Base.config

  - Defined in tinyYolov2/TinyYolov2Base.ts:35

### isLoaded

- get isLoaded(): boolean

- #### Returns boolean

  Inherited from TinyYolov2Base.isLoaded

  - Defined in NeuralNetwork.ts:23

### paramMappings

- get paramMappings(): ParamMapping[]

- #### Returns ParamMapping[]

  Inherited from TinyYolov2Base.paramMappings

  - Defined in NeuralNetwork.ts:21

### params

- get params(): undefined | TNetParams

- #### Returns undefined | TNetParams

  Inherited from TinyYolov2Base.params

  - Defined in NeuralNetwork.ts:19

### withClassScores

- get withClassScores(): boolean

- #### Returns boolean

  Inherited from TinyYolov2Base.withClassScores

  - Defined in tinyYolov2/TinyYolov2Base.ts:39

## Methods

### detect

- detect(input: any, forwardParams?: ITinyYolov2Options ): Promise< ObjectDetection []>

- #### Parameters

  - ##### input: any

  - ##### forwardParams: ITinyYolov2Options = {}

  #### Returns Promise< ObjectDetection []>

  Inherited from TinyYolov2Base.detect

  - Defined in tinyYolov2/TinyYolov2Base.ts:108

### dispose

- dispose(throwOnRedispose?: boolean): void

- #### Parameters

  - ##### throwOnRedispose: boolean = true

  #### Returns void

  Inherited from TinyYolov2Base.dispose

  - Defined in NeuralNetwork.ts:65

### extractWeights

- extractWeights(weights: Float32Array): void

- #### Parameters

  - ##### weights: Float32Array

  #### Returns void

  Inherited from TinyYolov2Base.extractWeights

  - Defined in NeuralNetwork.ts:118

### forward

- forward(input: any, inputSize: number): Promise<Tensor4D>

- #### Parameters

  - ##### input: any

  - ##### inputSize: number

  #### Returns Promise<Tensor4D>

  Inherited from TinyYolov2Base.forward

  - Defined in tinyYolov2/TinyYolov2Base.ts:104

### forwardInput

- forwardInput(input: NetInput, inputSize: number): Tensor4D

- #### Parameters

  - ##### input: NetInput

  - ##### inputSize: number

  #### Returns Tensor4D

  Inherited from TinyYolov2Base.forwardInput

  - Defined in tinyYolov2/TinyYolov2Base.ts:85

### freeze

- freeze(): void

- #### Returns void

  Inherited from TinyYolov2Base.freeze

  - Defined in NeuralNetwork.ts:57

### getFrozenParams

- getFrozenParams(): {
  path: string;
  tensor: Tensor;
  }[]

- #### Returns {
  path: string;
  tensor: Tensor;
  }[]

  Inherited from TinyYolov2Base.getFrozenParams

  - Defined in NeuralNetwork.ts:47

### getParamFromPath

- getParamFromPath(paramPath: string): Tensor

- #### Parameters

  - ##### paramPath: string

  #### Returns Tensor

  Inherited from TinyYolov2Base.getParamFromPath

  - Defined in NeuralNetwork.ts:25

### getParamList

- getParamList(): {
  path: string;
  tensor: Tensor;
  }[]

- #### Returns {
  path: string;
  tensor: Tensor;
  }[]

  Inherited from TinyYolov2Base.getParamList

  - Defined in NeuralNetwork.ts:36

### getTrainableParams

- getTrainableParams(): {
  path: string;
  tensor: Tensor;
  }[]

- #### Returns {
  path: string;
  tensor: Tensor;
  }[]

  Inherited from TinyYolov2Base.getTrainableParams

  - Defined in NeuralNetwork.ts:43

### load

- load(weightsOrUrl: undefined | string | Float32Array): Promise<void>

- #### Parameters

  - ##### weightsOrUrl: undefined | string | Float32Array

  #### Returns Promise<void>

  Inherited from TinyYolov2Base.load

  - Defined in NeuralNetwork.ts:83

### loadFromDisk

- loadFromDisk(filePath: undefined | string): Promise<void>

- #### Parameters

  - ##### filePath: undefined | string

  #### Returns Promise<void>

  Inherited from TinyYolov2Base.loadFromDisk

  - Defined in NeuralNetwork.ts:99

### loadFromUri

- loadFromUri(uri: undefined | string): Promise<void>

- #### Parameters

  - ##### uri: undefined | string

  #### Returns Promise<void>

  Inherited from TinyYolov2Base.loadFromUri

  - Defined in NeuralNetwork.ts:91

### loadFromWeightMap

- loadFromWeightMap(weightMap: NamedTensorMap): void

- #### Parameters

  - ##### weightMap: NamedTensorMap

  #### Returns void

  Inherited from TinyYolov2Base.loadFromWeightMap

  - Defined in NeuralNetwork.ts:112

### locateFaces

- locateFaces(input: any, forwardParams: ITinyYolov2Options ): Promise< FaceDetection []>

- #### Parameters

  - ##### input: any

  - ##### forwardParams: ITinyYolov2Options

  #### Returns Promise< FaceDetection []>

  - Defined in tinyFaceDetector/TinyFaceDetector.ts:30

### reassignParamFromPath

- reassignParamFromPath(paramPath: string, tensor: Tensor): void

- #### Parameters

  - ##### paramPath: string

  - ##### tensor: Tensor

  #### Returns void

  Inherited from TinyYolov2Base.reassignParamFromPath

  - Defined in NeuralNetwork.ts:30

### runMobilenet

- runMobilenet(x: Tensor4D, params: MobilenetParams ): Tensor4D

- #### Parameters

  - ##### x: Tensor4D

  - ##### params: MobilenetParams

  #### Returns Tensor4D

  Inherited from TinyYolov2Base.runMobilenet

  - Defined in tinyYolov2/TinyYolov2Base.ts:65

### runTinyYolov2

- runTinyYolov2(x: Tensor4D, params: DefaultTinyYolov2NetParams ): Tensor4D

- #### Parameters

  - ##### x: Tensor4D

  - ##### params: DefaultTinyYolov2NetParams

  #### Returns Tensor4D

  Inherited from TinyYolov2Base.runTinyYolov2

  - Defined in tinyYolov2/TinyYolov2Base.ts:47

### serializeParams

- serializeParams(): Float32Array

- #### Returns Float32Array

  Inherited from TinyYolov2Base.serializeParams

  - Defined in NeuralNetwork.ts:75

### variable

- variable(): void

- #### Returns void

  Inherited from TinyYolov2Base.variable

  - Defined in NeuralNetwork.ts:51