          list
              List of :class:`numpy.ndarray` faces with the opaque mask layer applied
          """
          orig_masks = 1 - np.rint(masks)
          masks3: Union[List[np.ndarray], np.ndarray] = []
  
          if faces[-1].shape[-1] == 4:  # Mask contained in alpha channel of predictions
              pred_masks = [1 - np.rint(face[..., -1])[..., None] for face in faces[-2:]]
              faces[-2:] = [face[..., :-1] for face in faces[-2:]]
              masks3 = [orig_masks, *pred_masks]
 
</s> remove         retval: List[np.ndarray] = []
 </s> add         retval: T.List[np.ndarray] = [] </s> remove         preds: Dict[str, np.ndarray] = {}
 </s> add         preds: T.Dict[str, np.ndarray] = {} </s> remove         retval: Dict[str, List[int]] = {}
 </s> add         retval: T.Dict[str, T.List[int]] = {} </s> remove         model_inputs: List[List[np.ndarray]] = []
        model_targets: List[List[np.ndarray]] = []
 </s> add         model_inputs: T.List[T.List[np.ndarray]] = []
        model_targets: T.List[T.List[np.ndarray]] = [] </s> remove         policy = dict(class_name="Policy", config=dict(name=dtype))
 </s> add         policy = {"class_name": "Policy", "config": {"name": dtype}}
        masks3: T.Union[T.List[np.ndarray], np.ndarray] = []
          list
              List of :class:`numpy.ndarray` faces with the opaque mask layer applied
          """
          orig_masks = 1 - np.rint(masks)
        masks3: T.Union[T.List[np.ndarray], np.ndarray] = []
  
          if faces[-1].shape[-1] == 4:  # Mask contained in alpha channel of predictions
              pred_masks = [1 - np.rint(face[..., -1])[..., None] for face in faces[-2:]]
              faces[-2:] = [face[..., :-1] for face in faces[-2:]]
              masks3 = [orig_masks, *pred_masks]
keep keep keep keep replace keep keep keep keep keep
 Remove plaidML support (#1325)

* Remove PlaidML reference from readme files

* Remove AMD option from installers

* remove amd requirements and update setup.py

* remove plaidml test from CI workflow

* gpustats: remove plaidml backend

* plaid removals:
  - faceswap.py - python version check
  - setup.cfg - plaidml typing ignore
  - lib.keras_utils - All plaid code
  - lib.launcher.py - All plaidml checks and configuration

* remove tf2.2 specific code from GUI event reader

* lib.model - remove all plaidml implementations

* plugins.extract - remove plaidml code

* plugins.train remove plaidml code

* lib.convert - remove plaidml code

* tools.model: remove plaidml code

* Remove plaidML tests from unit tests

* remove plaidml_utils and docsting cleanups

* Remove plaidML refs from configs

* fix keras imports 
plugins/train/trainer/_base.py