def _setup_transformer(self, params: dict) -> None:
        """Sets up/Initializes an optional transformer from `add_encoder` parameter used at model creation.

        Parameters
        ----------
        params
            Dict from parameter `add_encoders` (kwargs) used at model creation. Relevant parameters are:
            * params={..., 'transformer': Scaler()}
        """
        (
            transformer,
            transform_past_mask,
            transform_future_mask,
        ) = self._process_input_transformer(params)
        if transform_past_mask:
            self._past_transformer = SequentialEncoderTransformer(
                copy.deepcopy(transformer), transform_past_mask
            )
        if transform_future_mask:
            self._future_transformer = SequentialEncoderTransformer(
                copy.deepcopy(transformer), transform_future_mask
            )
Sets up/Initializes an optional transformer from `add_encoder` parameter used at model creation.

        Parameters
        ----------
        params
            Dict from parameter `add_encoders` (kwargs) used at model creation. Relevant parameters are:
            * params={..., 'transformer': Scaler()}
        
darts/dataprocessing/encoders/encoders.py