mediapipe-nightly 0.10.10.post20240224__cp311-cp311-macosx_11_0_x86_64.whl → 0.10.11.post20240302__cp311-cp311-macosx_11_0_x86_64.whl
Sign up to get free protection for your applications and to get access to all the features.
- mediapipe/__init__.py +1 -1
- mediapipe/python/__init__.py +1 -0
- mediapipe/python/_framework_bindings.cpython-311-darwin.so +0 -0
- mediapipe/tasks/cc/genai/inference/calculators/__init__.py +0 -0
- mediapipe/tasks/cc/genai/inference/calculators/detokenizer_calculator_pb2.py +27 -0
- mediapipe/tasks/cc/genai/inference/calculators/llm_gpu_calculator_pb2.py +31 -0
- mediapipe/tasks/cc/genai/inference/calculators/tokenizer_calculator_pb2.py +29 -0
- mediapipe/tasks/cc/genai/inference/proto/llm_file_metadata_pb2.py +32 -0
- mediapipe/tasks/cc/genai/inference/proto/llm_params_pb2.py +6 -6
- mediapipe/tasks/cc/genai/inference/proto/transformer_params_pb2.py +18 -18
- mediapipe/tasks/cc/metadata/python/_pywrap_metadata_version.cpython-311-darwin.so +0 -0
- mediapipe/tasks/metadata/schema_py_generated.py +4019 -119
- mediapipe/tasks/python/genai/converter/converter_base.py +4 -1
- mediapipe/tasks/python/genai/converter/llm_converter.py +16 -13
- mediapipe/tasks/python/genai/converter/pytorch_converter.py +7 -4
- mediapipe/tasks/python/genai/converter/pytorch_converter_test.py +1 -1
- mediapipe/tasks/python/genai/converter/safetensors_converter.py +5 -4
- mediapipe/tasks/python/genai/converter/safetensors_converter_test.py +1 -1
- mediapipe/tasks/python/metadata/flatbuffers_lib/_pywrap_flatbuffers.cpython-311-darwin.so +0 -0
- mediapipe/tasks/python/vision/__init__.py +5 -0
- {mediapipe_nightly-0.10.10.post20240224.dist-info → mediapipe_nightly-0.10.11.post20240302.dist-info}/METADATA +3 -1
- {mediapipe_nightly-0.10.10.post20240224.dist-info → mediapipe_nightly-0.10.11.post20240302.dist-info}/RECORD +25 -20
- {mediapipe_nightly-0.10.10.post20240224.dist-info → mediapipe_nightly-0.10.11.post20240302.dist-info}/LICENSE +0 -0
- {mediapipe_nightly-0.10.10.post20240224.dist-info → mediapipe_nightly-0.10.11.post20240302.dist-info}/WHEEL +0 -0
- {mediapipe_nightly-0.10.10.post20240224.dist-info → mediapipe_nightly-0.10.11.post20240302.dist-info}/top_level.txt +0 -0
mediapipe/__init__.py
CHANGED
mediapipe/python/__init__.py
CHANGED
@@ -14,6 +14,7 @@
|
|
14
14
|
|
15
15
|
"""MediaPipe Python API."""
|
16
16
|
|
17
|
+
from mediapipe.python._framework_bindings import model_ckpt_util
|
17
18
|
from mediapipe.python._framework_bindings import resource_util
|
18
19
|
from mediapipe.python._framework_bindings.calculator_graph import CalculatorGraph
|
19
20
|
from mediapipe.python._framework_bindings.calculator_graph import GraphInputStreamAddMode
|
Binary file
|
File without changes
|
@@ -0,0 +1,27 @@
|
|
1
|
+
# -*- coding: utf-8 -*-
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
3
|
+
# source: mediapipe/tasks/cc/genai/inference/calculators/detokenizer_calculator.proto
|
4
|
+
# Protobuf Python Version: 4.25.1
|
5
|
+
"""Generated protocol buffer code."""
|
6
|
+
from google.protobuf import descriptor as _descriptor
|
7
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
8
|
+
from google.protobuf import symbol_database as _symbol_database
|
9
|
+
from google.protobuf.internal import builder as _builder
|
10
|
+
# @@protoc_insertion_point(imports)
|
11
|
+
|
12
|
+
_sym_db = _symbol_database.Default()
|
13
|
+
|
14
|
+
|
15
|
+
|
16
|
+
|
17
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\nKmediapipe/tasks/cc/genai/inference/calculators/detokenizer_calculator.proto\x12\x10odml.infra.proto\"q\n\x1c\x44\x65tokenizerCalculatorOptions\x12\x16\n\x0espm_model_file\x18\x01 \x01(\t\x12\x13\n\x0bstop_tokens\x18\x04 \x03(\t\x12\x18\n\x10num_output_heads\x18\x05 \x01(\x05J\x04\x08\x02\x10\x03J\x04\x08\x03\x10\x04\x42@\n\x1b\x63om.google.odml.infra.protoB!DetokenizerCalculatorOptionsProtob\x06proto3')
|
18
|
+
|
19
|
+
_globals = globals()
|
20
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
21
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'mediapipe.tasks.cc.genai.inference.calculators.detokenizer_calculator_pb2', _globals)
|
22
|
+
if _descriptor._USE_C_DESCRIPTORS == False:
|
23
|
+
_globals['DESCRIPTOR']._options = None
|
24
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\033com.google.odml.infra.protoB!DetokenizerCalculatorOptionsProto'
|
25
|
+
_globals['_DETOKENIZERCALCULATOROPTIONS']._serialized_start=97
|
26
|
+
_globals['_DETOKENIZERCALCULATOROPTIONS']._serialized_end=210
|
27
|
+
# @@protoc_insertion_point(module_scope)
|
@@ -0,0 +1,31 @@
|
|
1
|
+
# -*- coding: utf-8 -*-
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
3
|
+
# source: mediapipe/tasks/cc/genai/inference/calculators/llm_gpu_calculator.proto
|
4
|
+
# Protobuf Python Version: 4.25.1
|
5
|
+
"""Generated protocol buffer code."""
|
6
|
+
from google.protobuf import descriptor as _descriptor
|
7
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
8
|
+
from google.protobuf import symbol_database as _symbol_database
|
9
|
+
from google.protobuf.internal import builder as _builder
|
10
|
+
# @@protoc_insertion_point(imports)
|
11
|
+
|
12
|
+
_sym_db = _symbol_database.Default()
|
13
|
+
|
14
|
+
|
15
|
+
from mediapipe.tasks.cc.genai.inference.proto import llm_file_metadata_pb2 as mediapipe_dot_tasks_dot_cc_dot_genai_dot_inference_dot_proto_dot_llm__file__metadata__pb2
|
16
|
+
from mediapipe.tasks.cc.genai.inference.proto import llm_params_pb2 as mediapipe_dot_tasks_dot_cc_dot_genai_dot_inference_dot_proto_dot_llm__params__pb2
|
17
|
+
|
18
|
+
|
19
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\nGmediapipe/tasks/cc/genai/inference/calculators/llm_gpu_calculator.proto\x12\x10odml.infra.proto\x1a@mediapipe/tasks/cc/genai/inference/proto/llm_file_metadata.proto\x1a\x39mediapipe/tasks/cc/genai/inference/proto/llm_params.proto\"\xf4\x04\n\x17LlmGpuCalculatorOptions\x12\x13\n\x0bweight_path\x18\x01 \x01(\t\x12N\n\x0egpu_model_info\x18\n \x01(\x0b\x32\x36.odml.infra.proto.LlmGpuCalculatorOptions.GpuModelInfo\x12\x19\n\x11num_decode_tokens\x18\x0c \x01(\x05\x12\x1b\n\x13sequence_batch_size\x18\x0e \x01(\x05\x12\x11\n\tlora_path\x18\x13 \x01(\t\x12\x37\n\x0ellm_parameters\x18\x14 \x01(\x0b\x32\x1f.odml.infra.proto.LlmParameters\x12\x18\n\x10num_output_heads\x18\x16 \x01(\x05\x12\x0c\n\x04topk\x18\x17 \x01(\x05\x12\x13\n\x0btemperature\x18\x18 \x01(\x02\x12\x18\n\x0brandom_seed\x18\x19 \x01(\rH\x00\x88\x01\x01\x1a\xc0\x01\n\x0cGpuModelInfo\x12\x1c\n\x14\x61llow_precision_loss\x18\x01 \x01(\x08\x12\x1a\n\x12\x65nable_fast_tuning\x18\x02 \x01(\x08\x12\x1b\n\x13\x65nable_winograd_opt\x18\x03 \x01(\x08\x12\x15\n\ruse_low_power\x18\x04 \x01(\x08\x12\x1e\n\x16prefer_texture_weights\x18\x05 \x01(\x08\x12\"\n\x1a\x65nable_host_mapped_pointer\x18\x06 \x01(\x08\x42\x0e\n\x0c_random_seedJ\x04\x08\x02\x10\x03J\x04\x08\x03\x10\x04J\x04\x08\x04\x10\x05J\x04\x08\x05\x10\x06J\x04\x08\x06\x10\x07J\x04\x08\x07\x10\x08J\x04\x08\x08\x10\tJ\x04\x08\t\x10\nJ\x04\x08\x0b\x10\x0cJ\x04\x08\r\x10\x0eJ\x04\x08\x1a\x10\x1bJ\x04\x08\x1b\x10\x1c\x42;\n\x1b\x63om.google.odml.infra.protoB\x1cLlmGpuCalculatorOptionsProtob\x06proto3')
|
20
|
+
|
21
|
+
_globals = globals()
|
22
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
23
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'mediapipe.tasks.cc.genai.inference.calculators.llm_gpu_calculator_pb2', _globals)
|
24
|
+
if _descriptor._USE_C_DESCRIPTORS == False:
|
25
|
+
_globals['DESCRIPTOR']._options = None
|
26
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\033com.google.odml.infra.protoB\034LlmGpuCalculatorOptionsProto'
|
27
|
+
_globals['_LLMGPUCALCULATOROPTIONS']._serialized_start=219
|
28
|
+
_globals['_LLMGPUCALCULATOROPTIONS']._serialized_end=847
|
29
|
+
_globals['_LLMGPUCALCULATOROPTIONS_GPUMODELINFO']._serialized_start=567
|
30
|
+
_globals['_LLMGPUCALCULATOROPTIONS_GPUMODELINFO']._serialized_end=759
|
31
|
+
# @@protoc_insertion_point(module_scope)
|
@@ -0,0 +1,29 @@
|
|
1
|
+
# -*- coding: utf-8 -*-
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
3
|
+
# source: mediapipe/tasks/cc/genai/inference/calculators/tokenizer_calculator.proto
|
4
|
+
# Protobuf Python Version: 4.25.1
|
5
|
+
"""Generated protocol buffer code."""
|
6
|
+
from google.protobuf import descriptor as _descriptor
|
7
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
8
|
+
from google.protobuf import symbol_database as _symbol_database
|
9
|
+
from google.protobuf.internal import builder as _builder
|
10
|
+
# @@protoc_insertion_point(imports)
|
11
|
+
|
12
|
+
_sym_db = _symbol_database.Default()
|
13
|
+
|
14
|
+
|
15
|
+
|
16
|
+
|
17
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\nImediapipe/tasks/cc/genai/inference/calculators/tokenizer_calculator.proto\x12\x10odml.infra.proto\"\xb7\x02\n\x1aTokenizerCalculatorOptions\x12\x12\n\nmax_tokens\x18\x01 \x01(\x05\x12\x18\n\x0espm_model_file\x18\x02 \x01(\tH\x00\x12Y\n\x11tflite_model_file\x18\x04 \x01(\x0b\x32<.odml.infra.proto.TokenizerCalculatorOptions.TfLiteModelFileH\x00\x12\x16\n\x0estart_token_id\x18\x03 \x01(\x05\x12 \n\x18\x62ytes_to_unicode_mapping\x18\x05 \x01(\x08\x1aH\n\x0fTfLiteModelFile\x12\x12\n\nmodel_file\x18\x01 \x01(\t\x12!\n\x19spm_model_key_in_metadata\x18\x02 \x01(\tB\x0c\n\nmodel_fileB>\n\x1b\x63om.google.odml.infra.protoB\x1fTokenizerCalculatorOptionsProtob\x06proto3')
|
18
|
+
|
19
|
+
_globals = globals()
|
20
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
21
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'mediapipe.tasks.cc.genai.inference.calculators.tokenizer_calculator_pb2', _globals)
|
22
|
+
if _descriptor._USE_C_DESCRIPTORS == False:
|
23
|
+
_globals['DESCRIPTOR']._options = None
|
24
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\033com.google.odml.infra.protoB\037TokenizerCalculatorOptionsProto'
|
25
|
+
_globals['_TOKENIZERCALCULATOROPTIONS']._serialized_start=96
|
26
|
+
_globals['_TOKENIZERCALCULATOROPTIONS']._serialized_end=407
|
27
|
+
_globals['_TOKENIZERCALCULATOROPTIONS_TFLITEMODELFILE']._serialized_start=321
|
28
|
+
_globals['_TOKENIZERCALCULATOROPTIONS_TFLITEMODELFILE']._serialized_end=393
|
29
|
+
# @@protoc_insertion_point(module_scope)
|
@@ -0,0 +1,32 @@
|
|
1
|
+
# -*- coding: utf-8 -*-
|
2
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
3
|
+
# source: mediapipe/tasks/cc/genai/inference/proto/llm_file_metadata.proto
|
4
|
+
# Protobuf Python Version: 4.25.1
|
5
|
+
"""Generated protocol buffer code."""
|
6
|
+
from google.protobuf import descriptor as _descriptor
|
7
|
+
from google.protobuf import descriptor_pool as _descriptor_pool
|
8
|
+
from google.protobuf import symbol_database as _symbol_database
|
9
|
+
from google.protobuf.internal import builder as _builder
|
10
|
+
# @@protoc_insertion_point(imports)
|
11
|
+
|
12
|
+
_sym_db = _symbol_database.Default()
|
13
|
+
|
14
|
+
|
15
|
+
from mediapipe.tasks.cc.genai.inference.proto import llm_params_pb2 as mediapipe_dot_tasks_dot_cc_dot_genai_dot_inference_dot_proto_dot_llm__params__pb2
|
16
|
+
|
17
|
+
|
18
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n@mediapipe/tasks/cc/genai/inference/proto/llm_file_metadata.proto\x12\x10odml.infra.proto\x1a\x39mediapipe/tasks/cc/genai/inference/proto/llm_params.proto\"\xe8\x02\n\x0fLlmFileMetadata\x12=\n\x07tensors\x18\x01 \x03(\x0b\x32,.odml.infra.proto.LlmFileMetadata.TensorInfo\x12\x35\n\x0cmodel_params\x18\x02 \x01(\x0b\x32\x1f.odml.infra.proto.LlmParameters\x12\x11\n\tlora_rank\x18\x03 \x01(\x05\x1a\xcb\x01\n\nTensorInfo\x12\x0c\n\x04name\x18\x01 \x01(\t\x12\x0e\n\x06offset\x18\x02 \x01(\x04\x12\x0c\n\x04size\x18\x03 \x01(\x04\x12H\n\tdata_type\x18\x04 \x01(\x0e\x32\x35.odml.infra.proto.LlmFileMetadata.TensorInfo.DataType\"G\n\x08\x44\x61taType\x12\x0f\n\x0bUNSPECIFIED\x10\x00\x12\x0b\n\x07\x46LOAT32\x10\x01\x12\x08\n\x04INT8\x10\x02\x12\x08\n\x04INT4\x10\x03\x12\t\n\x05UINT4\x10\x04\x42\x33\n\x1b\x63om.google.odml.infra.protoB\x14LlmFileMetadataProtob\x06proto3')
|
19
|
+
|
20
|
+
_globals = globals()
|
21
|
+
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
22
|
+
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'mediapipe.tasks.cc.genai.inference.proto.llm_file_metadata_pb2', _globals)
|
23
|
+
if _descriptor._USE_C_DESCRIPTORS == False:
|
24
|
+
_globals['DESCRIPTOR']._options = None
|
25
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\033com.google.odml.infra.protoB\024LlmFileMetadataProto'
|
26
|
+
_globals['_LLMFILEMETADATA']._serialized_start=146
|
27
|
+
_globals['_LLMFILEMETADATA']._serialized_end=506
|
28
|
+
_globals['_LLMFILEMETADATA_TENSORINFO']._serialized_start=303
|
29
|
+
_globals['_LLMFILEMETADATA_TENSORINFO']._serialized_end=506
|
30
|
+
_globals['_LLMFILEMETADATA_TENSORINFO_DATATYPE']._serialized_start=435
|
31
|
+
_globals['_LLMFILEMETADATA_TENSORINFO_DATATYPE']._serialized_end=506
|
32
|
+
# @@protoc_insertion_point(module_scope)
|
@@ -15,16 +15,16 @@ _sym_db = _symbol_database.Default()
|
|
15
15
|
from mediapipe.tasks.cc.genai.inference.proto import transformer_params_pb2 as mediapipe_dot_tasks_dot_cc_dot_genai_dot_inference_dot_proto_dot_transformer__params__pb2
|
16
16
|
|
17
17
|
|
18
|
-
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n9mediapipe/tasks/cc/genai/inference/proto/llm_params.proto\x12\
|
18
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n9mediapipe/tasks/cc/genai/inference/proto/llm_params.proto\x12\x10odml.infra.proto\x1a\x41mediapipe/tasks/cc/genai/inference/proto/transformer_params.proto\"\x9f\x01\n\rLlmParameters\x12G\n\x16transformer_parameters\x18\x01 \x01(\x0b\x32\'.odml.infra.proto.TransformerParameters\x12\x12\n\nvocab_size\x18\x02 \x01(\x05\x12\x16\n\x0estart_token_id\x18\x04 \x01(\x05\x12\x13\n\x0bstop_tokens\x18\x05 \x03(\tJ\x04\x08\x03\x10\x04*\xd1\x01\n\x0cLlmModelType\x12\x1a\n\x16LLM_MODEL_TYPE_UNKNOWN\x10\x00\x12\x1f\n\x1bLLM_MODEL_TYPE_FALCON_RW_1B\x10\x05\x12\x1b\n\x17LLM_MODEL_TYPE_GEMMA_2B\x10\x06\x12#\n\x1fLLM_MODEL_TYPE_STABLELM_4E1T_3B\x10\x08\x12\x18\n\x14LLM_MODEL_TYPE_PHI_2\x10\x0b\"\x04\x08\x01\x10\x01\"\x04\x08\x02\x10\x02\"\x04\x08\x03\x10\x03\"\x04\x08\x04\x10\x04\"\x04\x08\x07\x10\x07\"\x04\x08\t\x10\t\"\x04\x08\n\x10\nB1\n\x1b\x63om.google.odml.infra.protoB\x12LLMParametersProtob\x06proto3')
|
19
19
|
|
20
20
|
_globals = globals()
|
21
21
|
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
22
22
|
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'mediapipe.tasks.cc.genai.inference.proto.llm_params_pb2', _globals)
|
23
23
|
if _descriptor._USE_C_DESCRIPTORS == False:
|
24
24
|
_globals['DESCRIPTOR']._options = None
|
25
|
-
_globals['DESCRIPTOR']._serialized_options = b'\n
|
26
|
-
_globals['_LLMMODELTYPE']._serialized_start=
|
27
|
-
_globals['_LLMMODELTYPE']._serialized_end=
|
28
|
-
_globals['_LLMPARAMETERS']._serialized_start=
|
29
|
-
_globals['_LLMPARAMETERS']._serialized_end=
|
25
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\033com.google.odml.infra.protoB\022LLMParametersProto'
|
26
|
+
_globals['_LLMMODELTYPE']._serialized_start=309
|
27
|
+
_globals['_LLMMODELTYPE']._serialized_end=518
|
28
|
+
_globals['_LLMPARAMETERS']._serialized_start=147
|
29
|
+
_globals['_LLMPARAMETERS']._serialized_end=306
|
30
30
|
# @@protoc_insertion_point(module_scope)
|
@@ -14,28 +14,28 @@ _sym_db = _symbol_database.Default()
|
|
14
14
|
|
15
15
|
|
16
16
|
|
17
|
-
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\nAmediapipe/tasks/cc/genai/inference/proto/transformer_params.proto\x12\
|
17
|
+
DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\nAmediapipe/tasks/cc/genai/inference/proto/transformer_params.proto\x12\x10odml.infra.proto\"\x9d\r\n\x15TransformerParameters\x12\x12\n\nbatch_size\x18\x01 \x01(\x05\x12\x16\n\x0emax_seq_length\x18\x02 \x01(\x05\x12\x15\n\rembedding_dim\x18\x03 \x01(\x05\x12\x18\n\x10hidden_dimension\x18\x04 \x01(\x05\x12\x16\n\x0ehead_dimension\x18\x05 \x01(\x05\x12\x11\n\tnum_heads\x18\x06 \x01(\x05\x12\x12\n\nnum_stacks\x18\x07 \x01(\x05\x12\x14\n\x0cnum_kv_heads\x18\t \x01(\x05\x12^\n\x17\x66\x65\x65\x64_forward_parameters\x18\x0b \x01(\x0b\x32=.odml.infra.proto.TransformerParameters.FeedForwardParameters\x12`\n\x18\x66inal_project_parameters\x18\x0c \x01(\x0b\x32>.odml.infra.proto.TransformerParameters.FinalProjectParameters\x12>\n\x08pre_norm\x18\r \x01(\x0e\x32,.odml.infra.proto.TransformerParameters.Norm\x12?\n\tpost_norm\x18\x0e \x01(\x0e\x32,.odml.infra.proto.TransformerParameters.Norm\x12@\n\nfinal_norm\x18\x0f \x01(\x0e\x32,.odml.infra.proto.TransformerParameters.Norm\x12\x62\n\x19self_attention_parameters\x18\x10 \x01(\x0b\x32?.odml.infra.proto.TransformerParameters.SelfAttentionParameters\x12+\n#skip_absolute_positional_embeddings\x18\x12 \x01(\x08\x1a\xf1\x01\n\x15\x46\x65\x65\x64\x46orwardParameters\x12\x0f\n\x07no_bias\x18\x01 \x01(\x08\x12\x46\n\nactivation\x18\x02 \x01(\x0e\x32\x32.odml.infra.proto.TransformerParameters.Activation\x12>\n\x08pre_norm\x18\x03 \x01(\x0e\x32,.odml.infra.proto.TransformerParameters.Norm\x12?\n\tpost_norm\x18\x04 \x01(\x0e\x32,.odml.infra.proto.TransformerParameters.Norm\x1a\x41\n\x16\x46inalProjectParameters\x12\x0f\n\x07no_bias\x18\x01 \x01(\x08\x12\x16\n\x0esoft_cap_value\x18\x02 \x01(\x02\x1a\xb1\x02\n\x17SelfAttentionParameters\x12\x13\n\x0bqkv_no_bias\x18\x01 \x01(\x08\x12\x19\n\x11post_proj_no_bias\x18\x02 \x01(\x08\x12V\n\x13\x61ttention_mask_type\x18\x03 \x01(\x0e\x32\x39.odml.infra.proto.TransformerParameters.AttentionMaskType\x12\x16\n\x0esoft_cap_value\x18\x04 \x01(\x02\x12]\n\x14\x61ttention_scale_type\x18\x05 \x01(\x0e\x32:.odml.infra.proto.TransformerParameters.AttentionScaleTypeH\x00\x88\x01\x01\x42\x17\n\x15_attention_scale_type\"<\n\x11\x41ttentionMaskType\x12\x0f\n\x0bUNSPECIFIED\x10\x00\x12\n\n\x06\x43\x41USAL\x10\x01\x12\n\n\x06PREFIX\x10\x02\"F\n\nActivation\x12\x1a\n\x16\x41\x43TIVATION_UNSPECIFIED\x10\x00\x12\x08\n\x04GELU\x10\x01\x12\x08\n\x04SILU\x10\x02\x12\x08\n\x04RELU\x10\x03\"G\n\x04Norm\x12\x14\n\x10NORM_UNSPECIFIED\x10\x00\x12\x0b\n\x07NO_NORM\x10\x01\x12\x0c\n\x08RMS_NORM\x10\x02\x12\x0e\n\nLAYER_NORM\x10\x03\"p\n\x12\x41ttentionScaleType\x12\x1a\n\x16SCALE_TYPE_UNSPECIFIED\x10\x00\x12\x1c\n\x18SCALE_TYPE_PER_DIM_SCALE\x10\x01\x12 \n\x1cSCALE_TYPE_INV_SQRT_HEAD_DIM\x10\x02J\x04\x08\x08\x10\tJ\x04\x08\n\x10\x0bJ\x04\x08\x11\x10\x12\x42\x39\n\x1b\x63om.google.odml.infra.protoB\x1aTransformerParametersProtob\x06proto3')
|
18
18
|
|
19
19
|
_globals = globals()
|
20
20
|
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
|
21
21
|
_builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'mediapipe.tasks.cc.genai.inference.proto.transformer_params_pb2', _globals)
|
22
22
|
if _descriptor._USE_C_DESCRIPTORS == False:
|
23
23
|
_globals['DESCRIPTOR']._options = None
|
24
|
-
_globals['DESCRIPTOR']._serialized_options = b'\n
|
25
|
-
_globals['_TRANSFORMERPARAMETERS']._serialized_start=
|
26
|
-
_globals['_TRANSFORMERPARAMETERS']._serialized_end=
|
27
|
-
_globals['_TRANSFORMERPARAMETERS_FEEDFORWARDPARAMETERS']._serialized_start=
|
28
|
-
_globals['_TRANSFORMERPARAMETERS_FEEDFORWARDPARAMETERS']._serialized_end=
|
29
|
-
_globals['_TRANSFORMERPARAMETERS_FINALPROJECTPARAMETERS']._serialized_start=
|
30
|
-
_globals['_TRANSFORMERPARAMETERS_FINALPROJECTPARAMETERS']._serialized_end=
|
31
|
-
_globals['_TRANSFORMERPARAMETERS_SELFATTENTIONPARAMETERS']._serialized_start=
|
32
|
-
_globals['_TRANSFORMERPARAMETERS_SELFATTENTIONPARAMETERS']._serialized_end=
|
33
|
-
_globals['_TRANSFORMERPARAMETERS_ATTENTIONMASKTYPE']._serialized_start=
|
34
|
-
_globals['_TRANSFORMERPARAMETERS_ATTENTIONMASKTYPE']._serialized_end=
|
35
|
-
_globals['_TRANSFORMERPARAMETERS_ACTIVATION']._serialized_start=
|
36
|
-
_globals['_TRANSFORMERPARAMETERS_ACTIVATION']._serialized_end=
|
37
|
-
_globals['_TRANSFORMERPARAMETERS_NORM']._serialized_start=
|
38
|
-
_globals['_TRANSFORMERPARAMETERS_NORM']._serialized_end=
|
39
|
-
_globals['_TRANSFORMERPARAMETERS_ATTENTIONSCALETYPE']._serialized_start=
|
40
|
-
_globals['_TRANSFORMERPARAMETERS_ATTENTIONSCALETYPE']._serialized_end=
|
24
|
+
_globals['DESCRIPTOR']._serialized_options = b'\n\033com.google.odml.infra.protoB\032TransformerParametersProto'
|
25
|
+
_globals['_TRANSFORMERPARAMETERS']._serialized_start=88
|
26
|
+
_globals['_TRANSFORMERPARAMETERS']._serialized_end=1781
|
27
|
+
_globals['_TRANSFORMERPARAMETERS_FEEDFORWARDPARAMETERS']._serialized_start=826
|
28
|
+
_globals['_TRANSFORMERPARAMETERS_FEEDFORWARDPARAMETERS']._serialized_end=1067
|
29
|
+
_globals['_TRANSFORMERPARAMETERS_FINALPROJECTPARAMETERS']._serialized_start=1069
|
30
|
+
_globals['_TRANSFORMERPARAMETERS_FINALPROJECTPARAMETERS']._serialized_end=1134
|
31
|
+
_globals['_TRANSFORMERPARAMETERS_SELFATTENTIONPARAMETERS']._serialized_start=1137
|
32
|
+
_globals['_TRANSFORMERPARAMETERS_SELFATTENTIONPARAMETERS']._serialized_end=1442
|
33
|
+
_globals['_TRANSFORMERPARAMETERS_ATTENTIONMASKTYPE']._serialized_start=1444
|
34
|
+
_globals['_TRANSFORMERPARAMETERS_ATTENTIONMASKTYPE']._serialized_end=1504
|
35
|
+
_globals['_TRANSFORMERPARAMETERS_ACTIVATION']._serialized_start=1506
|
36
|
+
_globals['_TRANSFORMERPARAMETERS_ACTIVATION']._serialized_end=1576
|
37
|
+
_globals['_TRANSFORMERPARAMETERS_NORM']._serialized_start=1578
|
38
|
+
_globals['_TRANSFORMERPARAMETERS_NORM']._serialized_end=1649
|
39
|
+
_globals['_TRANSFORMERPARAMETERS_ATTENTIONSCALETYPE']._serialized_start=1651
|
40
|
+
_globals['_TRANSFORMERPARAMETERS_ATTENTIONSCALETYPE']._serialized_end=1763
|
41
41
|
# @@protoc_insertion_point(module_scope)
|