def encode(self, sentences: Union[str, List[str]], normalize: bool = True, **kwargs) -> FloatTensor:
        """performs the vectorizxation of a sentence or list of sentences

        Args:
            sentences (Union[str, List[str]]): _description_
            normalize (bool, optional): _description_. Defaults to Normalization.normalize.

        Returns:
            FloatTensor: _description_
        """
        if isinstance(sentences, str) or not hasattr(sentences, '__len__'):
            sentences = [sentences]

        # maybbe change to np and remove the .cpu().numpy calss?
        inputs = self.tokenizer(
            sentences,
            padding=True,
            truncation=True,
            max_length=self.max_seq_length,
            return_tensors="pt"
        )
        ort_inputs = {k: v.cpu().numpy() for k, v in inputs.items()}

        ort_outputs = self.session.run(None, ort_inputs)
        result = self.mean_pooling(token_embeddings=torch.FloatTensor(ort_outputs[0]),
                                                        attention_mask=inputs.get('attention_mask'))
        if normalize:
            return self.normalize(result)

        return result
performs the vectorizxation of a sentence or list of sentences

        Args:
            sentences (Union[str, List[str]]): _description_
            normalize (bool, optional): _description_. Defaults to Normalization.normalize.

        Returns:
            FloatTensor: _description_
        
src/marqo/s2_inference/sbert_onnx_utils.py