NumpyToList

class lib.align.updater.NumpyToList(alignments: dict[str, Any], version: float)

Bases: _Updater

Landmarks stored as a numpy array instead of a list

Attributes Summary

is_updated

True if this updater has been run otherwise False

Methods Summary

test()

check for legacy landmarks and thumbnails stored as numpy.ndarray rather than list

update()

Update landmarks and thumbnails stored as numpy.ndarray to list.

Attributes Documentation

Parameters:
  • alignments (dict[str, T.Any])

  • version (float)

is_updated

True if this updater has been run otherwise False

Methods Documentation

test() bool

check for legacy landmarks and thumbnails stored as numpy.ndarray rather than list

Return type:

True if any landmarks or thumbnails are a numpy array otherwise False

update() int

Update landmarks and thumbnails stored as numpy.ndarray to list.

Return type:

The number of faces that were changed

test() bool

check for legacy landmarks and thumbnails stored as numpy.ndarray rather than list

Return type:

True if any landmarks or thumbnails are a numpy array otherwise False

update() int

Update landmarks and thumbnails stored as numpy.ndarray to list.

Return type:

The number of faces that were changed