FilterLoader
- class lib.infer.identity.FilterLoader(threshold: float, filter_files: list[str] | None, nfilter_files: list[str] | None)
Bases:
objectObtains face embeddings from images and loads the IdentityFilter as part of the extraction pipeline
- Parameters:
threshold (float) – The threshold value for filtering out items. Default: 0.4
filter_files (list[str] | None) – The list of full paths to the files to use for filtering. Default:
None(don’t use filter)nfilter_files (list[str] | None) – The list of full paths to the files to use to nfilter. Default:
None(don’t use nfilter)
Methods Summary
add_identity_plugin(runner)Add the identity plugin for updating with embedding information
get_embeddings(pipeline)Obtain the embeddings that are to be used for face filtering and add to the identity plugin
Methods Documentation
- add_identity_plugin(runner: ExtractRunner) None
Add the identity plugin for updating with embedding information
- Parameters:
runner (ExtractRunner) – The identity runner for the pipeline
- Return type:
None
- get_embeddings(pipeline: ExtractRunner) None
Obtain the embeddings that are to be used for face filtering and add to the identity plugin
- Parameters:
pipeline (ExtractRunner) – The extraction pipelines for obtaining embeddings from non-faceswap images
- Return type:
None
- add_identity_plugin(runner: ExtractRunner) None
Add the identity plugin for updating with embedding information
- Parameters:
runner (ExtractRunner) – The identity runner for the pipeline
- Return type:
None
- enabled
Trueif identity face filtering is enabled
- get_embeddings(pipeline: ExtractRunner) None
Obtain the embeddings that are to be used for face filtering and add to the identity plugin
- Parameters:
pipeline (ExtractRunner) – The extraction pipelines for obtaining embeddings from non-faceswap images
- Return type:
None
- threshold
The threshold value for filtering out items