


'''simple docstring'''





import argparse
import json

import gdown
import numpy as np
import torch
from huggingface_hub import hf_hub_download

from transformers import (
    VideoMAEConfig,
    VideoMAEForPreTraining,
    VideoMAEForVideoClassification,
    VideoMAEImageProcessor,
)






def 						UpperCAmelCase__(				_SCREAMING_SNAKE_CASE					: Any ):






			"""simple docstring"""




			__A=	VideoMAEConfig()

			set_architecture_configs(_SCREAMING_SNAKE_CASE,_SCREAMING_SNAKE_CASE )

			if "finetuned" not in model_name:
						__A=	False

			if "finetuned" in model_name:
						__A=	'huggingface/label-files'
						if "kinetics" in model_name:
									__A=	400
									__A=	'kinetics400-id2label.json'
						elif "ssv2" in model_name:
									__A=	174
									__A=	'something-something-v2-id2label.json'
						else:
									raise ValueError('Model name should either contain \'kinetics\' or \'ssv2\' in case it\'s fine-tuned.' )
						__A=	json.load(open(hf_hub_download(_SCREAMING_SNAKE_CASE,_SCREAMING_SNAKE_CASE,repo_type='dataset' ),'r' ) )
						__A=	{int(_SCREAMING_SNAKE_CASE ): v for k, v in idalabel.items()}
						__A=	idalabel
						__A=	{v: k for k, v in idalabel.items()}

			return config






def 						UpperCAmelCase__(				_SCREAMING_SNAKE_CASE					: Dict,_SCREAMING_SNAKE_CASE					: Union[str, Any] ):






			"""simple docstring"""




			if "small" in model_name:
						__A=	384
						__A=	1536
						__A=	12
						__A=	16
						__A=	12
						__A=	3
						__A=	192
						__A=	768
			elif "large" in model_name:
						__A=	1024
						__A=	4096
						__A=	24
						__A=	16
						__A=	12
						__A=	8
						__A=	512
						__A=	2048
			elif "huge" in model_name:
						__A=	1280
						__A=	5120
						__A=	32
						__A=	16
						__A=	12
						__A=	8
						__A=	640
						__A=	2560
			elif "base" not in model_name:
						raise ValueError('Model name should include either "small", "base", "large", or "huge"' )






def 						UpperCAmelCase__(				_SCREAMING_SNAKE_CASE					: Tuple ):






			"""simple docstring"""




			if "encoder." in name:
						__A=	name.replace('encoder.','' )
			if "cls_token" in name:
						__A=	name.replace('cls_token','videomae.embeddings.cls_token' )
			if "decoder_pos_embed" in name:
						__A=	name.replace('decoder_pos_embed','decoder.decoder_pos_embed' )
			if "pos_embed" in name and "decoder" not in name:
						__A=	name.replace('pos_embed','videomae.embeddings.position_embeddings' )
			if "patch_embed.proj" in name:
						__A=	name.replace('patch_embed.proj','videomae.embeddings.patch_embeddings.projection' )
			if "patch_embed.norm" in name:
						__A=	name.replace('patch_embed.norm','videomae.embeddings.norm' )
			if "decoder.blocks" in name:
						__A=	name.replace('decoder.blocks','decoder.decoder_layers' )
			if "blocks" in name:
						__A=	name.replace('blocks','videomae.encoder.layer' )
			if "attn.proj" in name:
						__A=	name.replace('attn.proj','attention.output.dense' )
			if "attn" in name and "bias" not in name:
						__A=	name.replace('attn','attention.self' )
			if "attn" in name:
						__A=	name.replace('attn','attention.attention' )
			if "norm1" in name:
						__A=	name.replace('norm1','layernorm_before' )
			if "norm2" in name:
						__A=	name.replace('norm2','layernorm_after' )
			if "mlp.fc1" in name:
						__A=	name.replace('mlp.fc1','intermediate.dense' )
			if "mlp.fc2" in name:
						__A=	name.replace('mlp.fc2','output.dense' )
			if "decoder_embed" in name:
						__A=	name.replace('decoder_embed','decoder.decoder_embed' )
			if "decoder_norm" in name:
						__A=	name.replace('decoder_norm','decoder.decoder_norm' )
			if "decoder_pred" in name:
						__A=	name.replace('decoder_pred','decoder.decoder_pred' )
			if "norm.weight" in name and "decoder" not in name and "fc" not in name:
						__A=	name.replace('norm.weight','videomae.layernorm.weight' )
			if "norm.bias" in name and "decoder" not in name and "fc" not in name:
						__A=	name.replace('norm.bias','videomae.layernorm.bias' )
			if "head" in name and "decoder" not in name:
						__A=	name.replace('head','classifier' )

			return name






def 						UpperCAmelCase__(				_SCREAMING_SNAKE_CASE					: int,_SCREAMING_SNAKE_CASE					: Optional[Any] ):






			"""simple docstring"""




			for key in orig_state_dict.copy().keys():
						__A=	orig_state_dict.pop(_SCREAMING_SNAKE_CASE )

						if key.startswith('encoder.' ):
									__A=	key.replace('encoder.','' )

						if "qkv" in key:
									__A=	key.split('.' )
									if key.startswith('decoder.blocks' ):
												__A=	config.decoder_hidden_size
												__A=	int(key_split[2] )
												__A=	'decoder.decoder_layers.'
												if "weight" in key:
															__A=	val[:dim, :]
															__A=	val[dim : dim * 2, :]
															__A=	val[-dim:, :]
									else:
												__A=	config.hidden_size
												__A=	int(key_split[1] )
												__A=	'videomae.encoder.layer.'
												if "weight" in key:
															__A=	val[:dim, :]
															__A=	val[dim : dim * 2, :]
															__A=	val[-dim:, :]
						else:
									__A=	val

			return orig_state_dict






def 						UpperCAmelCase__(				):






			"""simple docstring"""




			__A=	hf_hub_download(
			    repo_id='hf-internal-testing/spaghetti-video',filename='eating_spaghetti.npy',repo_type='dataset' )
			__A=	np.load(_SCREAMING_SNAKE_CASE )
			return list(_SCREAMING_SNAKE_CASE )






def 						UpperCAmelCase__(				_SCREAMING_SNAKE_CASE					: Dict,_SCREAMING_SNAKE_CASE					: List[str],_SCREAMING_SNAKE_CASE					: Optional[Any],_SCREAMING_SNAKE_CASE					: Union[str, Any] ):






			"""simple docstring"""




			__A=	get_videomae_config(_SCREAMING_SNAKE_CASE )

			if "finetuned" in model_name:
						__A=	VideoMAEForVideoClassification(_SCREAMING_SNAKE_CASE )
			else:
						__A=	VideoMAEForPreTraining(_SCREAMING_SNAKE_CASE )

			# download original checkpoint, hosted on Google Drive
			__A=	'pytorch_model.bin'
			gdown.cached_download(_SCREAMING_SNAKE_CASE,_SCREAMING_SNAKE_CASE,quiet=_SCREAMING_SNAKE_CASE )
			__A=	torch.load(_SCREAMING_SNAKE_CASE,map_location='cpu' )
			if "model" in files:
						__A=	files['model']
			else:
						__A=	files['module']
			__A=	convert_state_dict(_SCREAMING_SNAKE_CASE,_SCREAMING_SNAKE_CASE )

			model.load_state_dict(_SCREAMING_SNAKE_CASE )
			model.eval()

			# verify model on basic input
			__A=	VideoMAEImageProcessor(image_mean=[0.5, 0.5, 0.5],image_std=[0.5, 0.5, 0.5] )
			__A=	prepare_video()
			__A=	image_processor(_SCREAMING_SNAKE_CASE,return_tensors='pt' )

			if "finetuned" not in model_name:
						__A=	hf_hub_download(repo_id='hf-internal-testing/bool-masked-pos',filename='bool_masked_pos.pt' )
						__A=	torch.load(_SCREAMING_SNAKE_CASE )

			__A=	model(**_SCREAMING_SNAKE_CASE )
			__A=	outputs.logits

			__A=	[
			    'videomae-small-finetuned-kinetics',
			    'videomae-small-finetuned-ssv2',
			    # Kinetics-400 checkpoints (short = pretrained only for 800 epochs instead of 1600)
			    'videomae-base-short',
			    'videomae-base-short-finetuned-kinetics',
			    'videomae-base',
			    'videomae-base-finetuned-kinetics',
			    'videomae-large',
			    'videomae-large-finetuned-kinetics',
			    'videomae-huge-finetuned-kinetics',
			    # Something-Something-v2 checkpoints (short = pretrained only for 800 epochs instead of 2400)
			    'videomae-base-short-ssv2',
			    'videomae-base-short-finetuned-ssv2',
			    'videomae-base-ssv2',
			    'videomae-base-finetuned-ssv2',
			]

			# NOTE: logits were tested with image_mean and image_std equal to [0.5, 0.5, 0.5] and [0.5, 0.5, 0.5]
			if model_name == "videomae-small-finetuned-kinetics":
						__A=	torch.Size([1, 400] )
						__A=	torch.tensor([-0.92_91, -0.40_61, -0.93_07] )
			elif model_name == "videomae-small-finetuned-ssv2":
						__A=	torch.Size([1, 174] )
						__A=	torch.tensor([0.26_71, -0.46_89, -0.82_35] )
			elif model_name == "videomae-base":
						__A=	torch.Size([1, 1408, 1536] )
						__A=	torch.tensor([[0.77_39, 0.79_68, 0.70_89], [0.67_01, 0.74_87, 0.62_09], [0.42_87, 0.51_58, 0.47_73]] )
			elif model_name == "videomae-base-short":
						__A=	torch.Size([1, 1408, 1536] )
						__A=	torch.tensor([[0.79_94, 0.96_12, 0.85_08], [0.74_01, 0.89_58, 0.83_02], [0.58_62, 0.74_68, 0.73_25]] )
						# we verified the loss both for normalized and unnormalized targets for this one
						__A=	torch.tensor([0.51_42] ) if config.norm_pix_loss else torch.tensor([0.64_69] )
			elif model_name == "videomae-large":
						__A=	torch.Size([1, 1408, 1536] )
						__A=	torch.tensor([[0.71_49, 0.79_97, 0.69_66], [0.67_68, 0.78_69, 0.69_48], [0.51_39, 0.62_21, 0.56_05]] )
			elif model_name == "videomae-large-finetuned-kinetics":
						__A=	torch.Size([1, 400] )
						__A=	torch.tensor([0.07_71, 0.00_11, -0.36_25] )
			elif model_name == "videomae-huge-finetuned-kinetics":
						__A=	torch.Size([1, 400] )
						__A=	torch.tensor([0.24_33, 0.16_32, -0.48_94] )
			elif model_name == "videomae-base-short-finetuned-kinetics":
						__A=	torch.Size([1, 400] )
						__A=	torch.tensor([0.65_88, 0.09_90, -0.24_93] )
			elif model_name == "videomae-base-finetuned-kinetics":
						__A=	torch.Size([1, 400] )
						__A=	torch.tensor([0.36_69, -0.06_88, -0.24_21] )
			elif model_name == "videomae-base-short-ssv2":
						__A=	torch.Size([1, 1408, 1536] )
						__A=	torch.tensor([[0.47_12, 0.52_96, 0.57_86], [0.22_78, 0.27_29, 0.40_26], [0.03_52, 0.07_30, 0.25_06]] )
			elif model_name == "videomae-base-short-finetuned-ssv2":
						__A=	torch.Size([1, 174] )
						__A=	torch.tensor([-0.05_37, -0.15_39, -0.32_66] )
			elif model_name == "videomae-base-ssv2":
						__A=	torch.Size([1, 1408, 1536] )
						__A=	torch.tensor([[0.81_31, 0.87_27, 0.85_46], [0.73_66, 0.93_77, 0.88_70], [0.59_35, 0.88_74, 0.85_64]] )
			elif model_name == "videomae-base-finetuned-ssv2":
						__A=	torch.Size([1, 174] )
						__A=	torch.tensor([0.19_61, -0.83_37, -0.63_89] )
			else:
						raise ValueError(f"""Model name not supported. Should be one of {model_names}""" )

			# verify logits
			assert logits.shape == expected_shape
			if "finetuned" in model_name:
						assert torch.allclose(logits[0, :3],_SCREAMING_SNAKE_CASE,atol=1e-4 )
			else:
						print('Logits:',logits[0, :3, :3] )
						assert torch.allclose(logits[0, :3, :3],_SCREAMING_SNAKE_CASE,atol=1e-4 )
			print('Logits ok!' )

			# verify loss, if applicable
			if model_name == "videomae-base-short":
						__A=	outputs.loss
						assert torch.allclose(_SCREAMING_SNAKE_CASE,_SCREAMING_SNAKE_CASE,atol=1e-4 )
						print('Loss ok!' )

			if pytorch_dump_folder_path is not None:
						print(f"""Saving model and image processor to {pytorch_dump_folder_path}""" )
						image_processor.save_pretrained(_SCREAMING_SNAKE_CASE )
						model.save_pretrained(_SCREAMING_SNAKE_CASE )

			if push_to_hub:
						print('Pushing to the hub...' )
						model.push_to_hub(_SCREAMING_SNAKE_CASE,organization='nielsr' )


if __name__ == "__main__":
					UpperCAmelCase__  			=				argparse.ArgumentParser()
					# Required parameters
					parser.add_argument(
					    '''--checkpoint_url''',
					    default='''https://drive.google.com/u/1/uc?id=1tEhLyskjb755TJ65ptsrafUG2llSwQE1&amp;export=download&amp;confirm=t&amp;uuid=aa3276eb-fb7e-482a-adec-dc7171df14c4''',
					    type=str,
					    help=(
					        '''URL of the original PyTorch checkpoint (on Google Drive) you\'d like to convert. Should be a direct'''
					        ''' download link.'''
					    ),
					)
					parser.add_argument(
					    '''--pytorch_dump_folder_path''',
					    default='''/Users/nielsrogge/Documents/VideoMAE/Test''',
					    type=str,
					    help='''Path to the output PyTorch model directory.''',
					)
					parser.add_argument('''--model_name''', default='''videomae-base''', type=str, help='''Name of the model.''')
					parser.add_argument(
					    '''--push_to_hub''', action='''store_true''', help='''Whether or not to push the converted model to the 🤗 hub.'''
					)

					UpperCAmelCase__  			=				parser.parse_args()
					convert_videomae_checkpoint(args.checkpoint_url, args.pytorch_dump_folder_path, args.model_name, args.push_to_hub)







'''simple docstring'''





import os
import re
import unicodedata
from shutil import copyfile
from typing import TYPE_CHECKING, Any, Dict, List, Optional, Tuple, Union

import sentencepiece as spm

from ...tokenization_utils import PreTrainedTokenizer
from ...utils import is_torch_available, logging


if is_torch_available():
					import torch


if TYPE_CHECKING:
					from transformers.pipelines.conversational import Conversation


UpperCAmelCase__  			=				logging.get_logger(__name__)
UpperCAmelCase__  			=				{'''vocab_file''': '''spiece.model'''}

UpperCAmelCase__  			=				{
    '''vocab_file''': {
        '''AI-Sweden/gpt-sw3-126m''': '''https://huggingface.co/AI-Sweden/gpt-sw3-126m/resolve/main/spiece.model''',
        '''AI-Sweden/gpt-sw3-350m''': '''https://huggingface.co/AI-Sweden/gpt-sw3-350m/resolve/main/spiece.model''',
        '''AI-Sweden/gpt-sw3-1.6b''': '''https://huggingface.co/AI-Sweden/gpt-sw3-1.6b/resolve/main/spiece.model''',
        '''AI-Sweden/gpt-sw3-6.7b''': '''https://huggingface.co/AI-Sweden/gpt-sw3-6.7b/resolve/main/spiece.model''',
        '''AI-Sweden/gpt-sw3-20b''': '''https://huggingface.co/AI-Sweden/gpt-sw3-20b/resolve/main/spiece.model''',
    }
}

UpperCAmelCase__  			=				{
    '''AI-Sweden/gpt-sw3-126m''': 2_0_4_8,
    '''AI-Sweden/gpt-sw3-350m''': 2_0_4_8,
    '''AI-Sweden/gpt-sw3-1.6b''': 2_0_4_8,
    '''AI-Sweden/gpt-sw3-6.7b''': 2_0_4_8,
    '''AI-Sweden/gpt-sw3-20b''': 2_0_4_8,
}
class 						a__					(					a_   ):





			'''simple docstring'''

			A						:				int					      =			VOCAB_FILES_NAMES
			A						:				Optional[int]					      =			PRETRAINED_VOCAB_FILES_MAP
			A						:				Tuple					      =			PRETRAINED_POSITIONAL_EMBEDDINGS_SIZES
			A						:				int					      =			['''input_ids''', '''attention_mask''']
			def __init__(  self							:			int			,    lowerCAmelCase_							:			List[str]			,    lowerCAmelCase_							:			Union[str, Any]=False			,    lowerCAmelCase_							:			List[str]=False			,    lowerCAmelCase_							:			List[Any]=False			,    lowerCAmelCase_							:			Union[str, Any]=None			,    lowerCAmelCase_							:			Union[str, Any]=None			,    lowerCAmelCase_							:			Union[str, Any]=None			,    lowerCAmelCase_							:			List[Any]=None			,    lowerCAmelCase_							:			Optional[Dict[str, Any]] = None			,    **lowerCAmelCase_							:			Optional[Any]			,    )      ->		None:
						__A=	{} if sp_model_kwargs is None else sp_model_kwargs

						__A=	kwargs.get('name_or_path'	)
						if name_or_path is None:
									logger.warning(
									    'name_or_path not provided, will work for all GPTSw3 models except gpt-sw3-7b,'
									    ' you are testing the model, this can safely be ignored'	)
									__A=	'None'

						# Default definitions for our 2 tokenizer versions, with None-checks to enable proper testing
						__A=	'<|endoftext|>' if eos_token is None else eos_token
						__A=	'<unk>' if unk_token is None else unk_token
						if "gpt-sw3-7b" in name_or_path:
									__A=	unk_token if pad_token is None else pad_token
									__A=	eos_token if bos_token is None else bos_token
						else:
									__A=	'<pad>' if pad_token is None else pad_token
									__A=	'<s>' if bos_token is None else bos_token

						super().__init__(
						    do_lower_case=lowerCAmelCase_			,    remove_space=lowerCAmelCase_			,    keep_accents=lowerCAmelCase_			,    bos_token=lowerCAmelCase_			,    eos_token=lowerCAmelCase_			,    unk_token=lowerCAmelCase_			,    pad_token=lowerCAmelCase_			,    sp_model_kwargs=self.sp_model_kwargs			,    **lowerCAmelCase_			,    )

						__A=	do_lower_case
						__A=	remove_space
						__A=	keep_accents
						__A=	vocab_file

						__A=	spm.SentencePieceProcessor(**self.sp_model_kwargs	)
						self.sp_model.Load(lowerCAmelCase_	)

						# Used for whitespace normalization in input texts
						# fmt : off
						__A=	{' ', ' ', ' ', ' ', ' ', '　', ' ', ' ', ' ', ' ', '￼', ''}
						# fmt : on

						# Regular expression to remove non-printing characters (e.g. some unicode control chars) in preprocessing
						__A=	re.compile(
						    F"""[{"".join(map(lowerCAmelCase_			,    list(range(0			,    9	)	) + list(range(11			,    32	)	) + list(range(127			,    160	)	) + [160, 173, 8_203]	)	)}]"""	)
			def __getstate__(  self							:			Optional[int]	)      ->		Tuple:
						__A=	self.__dict__.copy()
						__A=	None
						return state
			def __setstate__(  self							:			int			,    lowerCAmelCase_							:			int	)      ->		Tuple:
						__A=	d

						# for backward compatibility
						if not hasattr(self			,    'sp_model_kwargs'	):
									__A=	{}

						__A=	spm.SentencePieceProcessor(**self.sp_model_kwargs	)
						self.sp_model.Load(self.vocab_file	)
			@property
			# Copied from transformers.models.albert.tokenization_albert.AlbertTokenizer.vocab_size
			def 					lowerCAmelCase     (  self							:			Tuple	)      ->		int:
						return len(self.sp_model	)
			def 					lowerCAmelCase     (  self							:			int			,    lowerCAmelCase_							:			str	)      ->		str:
						__A=	self.non_printing_characters_re.sub(''			,    lowerCAmelCase_	)

						# Normalize whitespaces
						__A=	''.join([char if char not in self.whitespaces else ' ' for char in text]	)

						# NFC Unicode normalization
						__A=	unicodedata.normalize('NFC'			,    lowerCAmelCase_	)
						return text
			def 					lowerCAmelCase     (  self							:			Tuple			,    lowerCAmelCase_							:			str			,    **lowerCAmelCase_							:			Optional[Any]	)      ->		List[str]:
						__A=	self.preprocess_text(lowerCAmelCase_	)
						return self.sp_model.encode(lowerCAmelCase_			,    out_type=lowerCAmelCase_	)
			def 					lowerCAmelCase     (  self							:			Any			,    lowerCAmelCase_							:			str	)      ->		int:
						return self.sp_model.PieceToId(lowerCAmelCase_	)
			def 					lowerCAmelCase     (  self							:			Optional[Any]			,    lowerCAmelCase_							:			int	)      ->		str:
						return self.sp_model.IdToPiece(lowerCAmelCase_	)
			@staticmethod
			def 					lowerCAmelCase     (  lowerCAmelCase_							:			str	)      ->		str:
						return out_string
			def 					lowerCAmelCase     (  self							:			Union[str, Any]			,    lowerCAmelCase_							:			List[str]	)      ->		str:
						__A=	[]
						__A=	''
						__A=	False
						for token in tokens:
									# make sure that special tokens are not decoded using sentencepiece model
									if token in self.all_special_tokens:
												# TODO: Check if this is needed, as it ensures that decode(encode(doc)) != doc by adding extra whitespace in the decoded document
												if not prev_is_special:
															out_string += " "

												out_string += self.sp_model.decode(lowerCAmelCase_	) + token
												__A=	True
												__A=	[]
									else:
												current_sub_tokens.append(lowerCAmelCase_	)
												__A=	False
						out_string += self.sp_model.decode(lowerCAmelCase_	)

						return out_string
			def 					lowerCAmelCase     (  self							:			List[Any]	)      ->		Dict[str, int]:
						__A=	{self.convert_ids_to_tokens(lowerCAmelCase_	): i for i in range(self.vocab_size	)}
						vocab.update(self.added_tokens_encoder	)
						return vocab
			def 					lowerCAmelCase     (  self							:			Dict			,    lowerCAmelCase_							:			str			,    lowerCAmelCase_							:			Optional[str] = None	)      ->		Tuple[str]:
						if not os.path.isdir(lowerCAmelCase_	):
									logger.error(F"""Vocabulary path ({save_directory}) should be a directory"""	)
									return
						__A=	os.path.join(
						    lowerCAmelCase_			,    (filename_prefix + '-' if filename_prefix else '') + VOCAB_FILES_NAMES['vocab_file']	)

						if os.path.abspath(self.vocab_file	) != os.path.abspath(lowerCAmelCase_	) and os.path.isfile(self.vocab_file	):
									copyfile(self.vocab_file			,    lowerCAmelCase_	)
						elif not os.path.isfile(self.vocab_file	):
									with open(lowerCAmelCase_			,    'wb'	) as fi:
												__A=	self.sp_model.serialized_model_proto()
												fi.write(lowerCAmelCase_	)

						return (out_vocab_file,)
			def 					lowerCAmelCase     (  self							:			Optional[Any]			,    lowerCAmelCase_							:			Union[str, List[str]]			,    lowerCAmelCase_							:			Union[str, bool] = False	)      ->		Union[List[int], List[List[int]], "torch.Tensor"]:

						if isinstance(lowerCAmelCase_			,    lowerCAmelCase_	):
									__A=	self.preprocess_text(lowerCAmelCase_	)
									__A=	self.sp_model.encode(lowerCAmelCase_	)
						else:
									__A=	[self.preprocess_text(lowerCAmelCase_	) for t in text]
									__A=	self.sp_model.encode(lowerCAmelCase_	)

						if return_tensors is True or return_tensors == "pt":
									__A=	torch.tensor(lowerCAmelCase_	)

						return token_ids
			def 					lowerCAmelCase     (  self							:			Tuple			,    lowerCAmelCase_							:			Union[int, List[int]]	)      ->		str:
						return self.sp_model.decode(lowerCAmelCase_	)

			def 					lowerCAmelCase     (  self							:			Optional[Any]			,    lowerCAmelCase_							:			"Conversation"	)      ->		List[int]:
						__A=	[F"""User: {text}""" if is_user else F"""Bot: {text}""" for is_user, text in conversation.iter_texts()]
						__A=	(
						    F"""{self.eos_token}{self.bos_token}""" + F"""{self.bos_token}""".join(lowerCAmelCase_	) + F"""{self.bos_token}Bot:"""
						)
						return self.encode(text=lowerCAmelCase_	)



