matlab-prodserver-client 24.2__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (77) hide show
  1. google/__init__.py +7 -0
  2. google/protobuf_ml/__init__.py +33 -0
  3. google/protobuf_ml/descriptor.py +1230 -0
  4. google/protobuf_ml/descriptor_database.py +177 -0
  5. google/protobuf_ml/descriptor_pb2.py +1925 -0
  6. google/protobuf_ml/descriptor_pool.py +1295 -0
  7. google/protobuf_ml/internal/__init__.py +0 -0
  8. google/protobuf_ml/internal/_parameterized.py +443 -0
  9. google/protobuf_ml/internal/api_implementation.py +168 -0
  10. google/protobuf_ml/internal/builder.py +130 -0
  11. google/protobuf_ml/internal/containers.py +708 -0
  12. google/protobuf_ml/internal/decoder.py +1068 -0
  13. google/protobuf_ml/internal/descriptor_database_test.py +127 -0
  14. google/protobuf_ml/internal/descriptor_pool_test.py +1149 -0
  15. google/protobuf_ml/internal/descriptor_test.py +1076 -0
  16. google/protobuf_ml/internal/encoder.py +829 -0
  17. google/protobuf_ml/internal/enum_type_wrapper.py +124 -0
  18. google/protobuf_ml/internal/extension_dict.py +213 -0
  19. google/protobuf_ml/internal/generator_test.py +354 -0
  20. google/protobuf_ml/internal/import_test.py +49 -0
  21. google/protobuf_ml/internal/json_format_test.py +1285 -0
  22. google/protobuf_ml/internal/keywords_test.py +103 -0
  23. google/protobuf_ml/internal/message_factory_test.py +299 -0
  24. google/protobuf_ml/internal/message_listener.py +78 -0
  25. google/protobuf_ml/internal/message_test.py +2573 -0
  26. google/protobuf_ml/internal/proto_builder_test.py +106 -0
  27. google/protobuf_ml/internal/python_message.py +1539 -0
  28. google/protobuf_ml/internal/reflection_test.py +3381 -0
  29. google/protobuf_ml/internal/service_reflection_test.py +139 -0
  30. google/protobuf_ml/internal/symbol_database_test.py +133 -0
  31. google/protobuf_ml/internal/test_util.py +878 -0
  32. google/protobuf_ml/internal/testing_refleaks.py +142 -0
  33. google/protobuf_ml/internal/text_encoding_test.py +67 -0
  34. google/protobuf_ml/internal/text_format_test.py +2447 -0
  35. google/protobuf_ml/internal/type_checkers.py +435 -0
  36. google/protobuf_ml/internal/unknown_fields_test.py +461 -0
  37. google/protobuf_ml/internal/well_known_types.py +887 -0
  38. google/protobuf_ml/internal/well_known_types_test.py +1013 -0
  39. google/protobuf_ml/internal/wire_format.py +268 -0
  40. google/protobuf_ml/internal/wire_format_test.py +252 -0
  41. google/protobuf_ml/json_format.py +912 -0
  42. google/protobuf_ml/message.py +424 -0
  43. google/protobuf_ml/message_factory.py +189 -0
  44. google/protobuf_ml/proto_builder.py +134 -0
  45. google/protobuf_ml/reflection.py +95 -0
  46. google/protobuf_ml/service.py +228 -0
  47. google/protobuf_ml/service_reflection.py +295 -0
  48. google/protobuf_ml/symbol_database.py +194 -0
  49. google/protobuf_ml/text_encoding.py +110 -0
  50. google/protobuf_ml/text_format.py +1842 -0
  51. google/protobuf_ml/unknown_fields.py +120 -0
  52. matlab/__init__.py +43 -0
  53. matlab/bin/win64/libmwfoundation_matlabdata.dll +0 -0
  54. matlab/bin/win64/libmwfoundation_matlabdata_standalone.dll +0 -0
  55. matlab/extern/bin/win64/libMatlabDataArray.dll +0 -0
  56. matlab/extern/bin/win64/matlabmultidimarrayforpython.cp310-win_amd64.pyd +0 -0
  57. matlab/extern/bin/win64/matlabmultidimarrayforpython.cp39-win_amd64.pyd +0 -0
  58. matlab/extern/bin/win64/matlabmultidimarrayforpython.pyd +0 -0
  59. matlab/production_server/__init__.py +2 -0
  60. matlab/production_server/_internal_mps/__init__.py +2 -0
  61. matlab/production_server/_internal_mps/feval_handler.py +76 -0
  62. matlab/production_server/_internal_mps/invocation_handler_utils.py +52 -0
  63. matlab/production_server/_internal_mps/matlab_array_builder.py +201 -0
  64. matlab/production_server/_internal_mps/matlab_response_builder.py +134 -0
  65. matlab/production_server/_proto_generated/MATLABArray_pb2.py +129 -0
  66. matlab/production_server/_proto_generated/MATLABError_pb2.py +27 -0
  67. matlab/production_server/_proto_generated/MATLABParams_pb2.py +26 -0
  68. matlab/production_server/_proto_generated/MATLABResult_pb2.py +27 -0
  69. matlab/production_server/_proto_generated/__init__.py +0 -0
  70. matlab/production_server/client.py +140 -0
  71. matlab/production_server/mpsexceptions.py +56 -0
  72. matlab_prodserver_client-24.2.dist-info/LICENSE.txt +27 -0
  73. matlab_prodserver_client-24.2.dist-info/METADATA +94 -0
  74. matlab_prodserver_client-24.2.dist-info/RECORD +77 -0
  75. matlab_prodserver_client-24.2.dist-info/WHEEL +5 -0
  76. matlab_prodserver_client-24.2.dist-info/top_level.txt +3 -0
  77. six.py +953 -0
@@ -0,0 +1,130 @@
1
+ # Protocol Buffers - Google's data interchange format
2
+ # Copyright 2008 Google Inc. All rights reserved.
3
+ # https://developers.google.com/protocol-buffers/
4
+ #
5
+ # Redistribution and use in source and binary forms, with or without
6
+ # modification, are permitted provided that the following conditions are
7
+ # met:
8
+ #
9
+ # * Redistributions of source code must retain the above copyright
10
+ # notice, this list of conditions and the following disclaimer.
11
+ # * Redistributions in binary form must reproduce the above
12
+ # copyright notice, this list of conditions and the following disclaimer
13
+ # in the documentation and/or other materials provided with the
14
+ # distribution.
15
+ # * Neither the name of Google Inc. nor the names of its
16
+ # contributors may be used to endorse or promote products derived from
17
+ # this software without specific prior written permission.
18
+ #
19
+ # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
20
+ # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
21
+ # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
22
+ # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
23
+ # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
24
+ # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
25
+ # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
26
+ # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
27
+ # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
28
+ # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29
+ # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30
+
31
+ """Builds descriptors, message classes and services for generated _pb2.py.
32
+
33
+ This file is only called in python generated _pb2.py files. It builds
34
+ descriptors, message classes and services that users can directly use
35
+ in generated code.
36
+ """
37
+
38
+ __author__ = 'jieluo@google.com (Jie Luo)'
39
+
40
+ from google.protobuf_ml.internal import enum_type_wrapper
41
+ from google.protobuf_ml import message as _message
42
+ from google.protobuf_ml import reflection as _reflection
43
+ from google.protobuf_ml import symbol_database as _symbol_database
44
+
45
+ _sym_db = _symbol_database.Default()
46
+
47
+
48
+ def BuildMessageAndEnumDescriptors(file_des, module):
49
+ """Builds message and enum descriptors.
50
+
51
+ Args:
52
+ file_des: FileDescriptor of the .proto file
53
+ module: Generated _pb2 module
54
+ """
55
+
56
+ def BuildNestedDescriptors(msg_des, prefix):
57
+ for (name, nested_msg) in msg_des.nested_types_by_name.items():
58
+ module_name = prefix + name.upper()
59
+ module[module_name] = nested_msg
60
+ BuildNestedDescriptors(nested_msg, module_name + '_')
61
+ for enum_des in msg_des.enum_types:
62
+ module[prefix + enum_des.name.upper()] = enum_des
63
+
64
+ for (name, msg_des) in file_des.message_types_by_name.items():
65
+ module_name = '_' + name.upper()
66
+ module[module_name] = msg_des
67
+ BuildNestedDescriptors(msg_des, module_name + '_')
68
+
69
+
70
+ def BuildTopDescriptorsAndMessages(file_des, module_name, module):
71
+ """Builds top level descriptors and message classes.
72
+
73
+ Args:
74
+ file_des: FileDescriptor of the .proto file
75
+ module_name: str, the name of generated _pb2 module
76
+ module: Generated _pb2 module
77
+ """
78
+
79
+ def BuildMessage(msg_des):
80
+ create_dict = {}
81
+ for (name, nested_msg) in msg_des.nested_types_by_name.items():
82
+ create_dict[name] = BuildMessage(nested_msg)
83
+ create_dict['DESCRIPTOR'] = msg_des
84
+ create_dict['__module__'] = module_name
85
+ message_class = _reflection.GeneratedProtocolMessageType(
86
+ msg_des.name, (_message.Message,), create_dict)
87
+ _sym_db.RegisterMessage(message_class)
88
+ return message_class
89
+
90
+ # top level enums
91
+ for (name, enum_des) in file_des.enum_types_by_name.items():
92
+ module['_' + name.upper()] = enum_des
93
+ module[name] = enum_type_wrapper.EnumTypeWrapper(enum_des)
94
+ for enum_value in enum_des.values:
95
+ module[enum_value.name] = enum_value.number
96
+
97
+ # top level extensions
98
+ for (name, extension_des) in file_des.extensions_by_name.items():
99
+ module[name.upper() + '_FIELD_NUMBER'] = extension_des.number
100
+ module[name] = extension_des
101
+
102
+ # services
103
+ for (name, service) in file_des.services_by_name.items():
104
+ module['_' + name.upper()] = service
105
+
106
+ # Build messages.
107
+ for (name, msg_des) in file_des.message_types_by_name.items():
108
+ module[name] = BuildMessage(msg_des)
109
+
110
+
111
+ def BuildServices(file_des, module_name, module):
112
+ """Builds services classes and services stub class.
113
+
114
+ Args:
115
+ file_des: FileDescriptor of the .proto file
116
+ module_name: str, the name of generated _pb2 module
117
+ module: Generated _pb2 module
118
+ """
119
+ # pylint: disable=g-import-not-at-top
120
+ from google.protobuf_ml import service as _service
121
+ from google.protobuf_ml import service_reflection
122
+ # pylint: enable=g-import-not-at-top
123
+ for (name, service) in file_des.services_by_name.items():
124
+ module[name] = service_reflection.GeneratedServiceType(
125
+ name, (_service.Service,),
126
+ dict(DESCRIPTOR=service, __module__=module_name))
127
+ stub_name = name + '_Stub'
128
+ module[stub_name] = service_reflection.GeneratedServiceStubType(
129
+ stub_name, (module[name],),
130
+ dict(DESCRIPTOR=service, __module__=module_name))