def _tokenize(self, text):
        """
        End-to-end tokenization for BERT models.

        Args:
            text (str): The text to be tokenized.

        Returns:
            list: A list of string representing converted tokens.
        """
        split_tokens = []
        for token in self.basic_tokenizer.tokenize(text):
            for sub_token in self.wordpiece_tokenizer.tokenize(token):
                split_tokens.append(sub_token)
        return split_tokens

        End-to-end tokenization for BERT models.

        Args:
            text (str): The text to be tokenized.

        Returns:
            list: A list of string representing converted tokens.
        
ptstructure/vqa/pytorchnlp/transformers/bert/tokenizer.py