nedo-vision-worker 1.0.0__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 (92) hide show
  1. nedo_vision_worker/__init__.py +10 -0
  2. nedo_vision_worker/cli.py +195 -0
  3. nedo_vision_worker/config/ConfigurationManager.py +196 -0
  4. nedo_vision_worker/config/__init__.py +1 -0
  5. nedo_vision_worker/database/DatabaseManager.py +219 -0
  6. nedo_vision_worker/database/__init__.py +1 -0
  7. nedo_vision_worker/doctor.py +453 -0
  8. nedo_vision_worker/initializer/AppInitializer.py +78 -0
  9. nedo_vision_worker/initializer/__init__.py +1 -0
  10. nedo_vision_worker/models/__init__.py +15 -0
  11. nedo_vision_worker/models/ai_model.py +29 -0
  12. nedo_vision_worker/models/auth.py +14 -0
  13. nedo_vision_worker/models/config.py +9 -0
  14. nedo_vision_worker/models/dataset_source.py +30 -0
  15. nedo_vision_worker/models/logs.py +9 -0
  16. nedo_vision_worker/models/ppe_detection.py +39 -0
  17. nedo_vision_worker/models/ppe_detection_label.py +20 -0
  18. nedo_vision_worker/models/restricted_area_violation.py +20 -0
  19. nedo_vision_worker/models/user.py +10 -0
  20. nedo_vision_worker/models/worker_source.py +19 -0
  21. nedo_vision_worker/models/worker_source_pipeline.py +21 -0
  22. nedo_vision_worker/models/worker_source_pipeline_config.py +24 -0
  23. nedo_vision_worker/models/worker_source_pipeline_debug.py +15 -0
  24. nedo_vision_worker/models/worker_source_pipeline_detection.py +14 -0
  25. nedo_vision_worker/protos/AIModelService_pb2.py +46 -0
  26. nedo_vision_worker/protos/AIModelService_pb2_grpc.py +140 -0
  27. nedo_vision_worker/protos/DatasetSourceService_pb2.py +46 -0
  28. nedo_vision_worker/protos/DatasetSourceService_pb2_grpc.py +140 -0
  29. nedo_vision_worker/protos/HumanDetectionService_pb2.py +44 -0
  30. nedo_vision_worker/protos/HumanDetectionService_pb2_grpc.py +140 -0
  31. nedo_vision_worker/protos/PPEDetectionService_pb2.py +46 -0
  32. nedo_vision_worker/protos/PPEDetectionService_pb2_grpc.py +140 -0
  33. nedo_vision_worker/protos/VisionWorkerService_pb2.py +72 -0
  34. nedo_vision_worker/protos/VisionWorkerService_pb2_grpc.py +471 -0
  35. nedo_vision_worker/protos/WorkerSourcePipelineService_pb2.py +64 -0
  36. nedo_vision_worker/protos/WorkerSourcePipelineService_pb2_grpc.py +312 -0
  37. nedo_vision_worker/protos/WorkerSourceService_pb2.py +50 -0
  38. nedo_vision_worker/protos/WorkerSourceService_pb2_grpc.py +183 -0
  39. nedo_vision_worker/protos/__init__.py +1 -0
  40. nedo_vision_worker/repositories/AIModelRepository.py +44 -0
  41. nedo_vision_worker/repositories/DatasetSourceRepository.py +150 -0
  42. nedo_vision_worker/repositories/PPEDetectionRepository.py +112 -0
  43. nedo_vision_worker/repositories/RestrictedAreaRepository.py +88 -0
  44. nedo_vision_worker/repositories/WorkerSourcePipelineDebugRepository.py +90 -0
  45. nedo_vision_worker/repositories/WorkerSourcePipelineDetectionRepository.py +48 -0
  46. nedo_vision_worker/repositories/WorkerSourcePipelineRepository.py +174 -0
  47. nedo_vision_worker/repositories/WorkerSourceRepository.py +46 -0
  48. nedo_vision_worker/repositories/__init__.py +1 -0
  49. nedo_vision_worker/services/AIModelClient.py +362 -0
  50. nedo_vision_worker/services/ConnectionInfoClient.py +57 -0
  51. nedo_vision_worker/services/DatasetSourceClient.py +88 -0
  52. nedo_vision_worker/services/FileToRTMPServer.py +78 -0
  53. nedo_vision_worker/services/GrpcClientBase.py +155 -0
  54. nedo_vision_worker/services/GrpcClientManager.py +141 -0
  55. nedo_vision_worker/services/ImageUploadClient.py +82 -0
  56. nedo_vision_worker/services/PPEDetectionClient.py +108 -0
  57. nedo_vision_worker/services/RTSPtoRTMPStreamer.py +98 -0
  58. nedo_vision_worker/services/RestrictedAreaClient.py +100 -0
  59. nedo_vision_worker/services/SystemUsageClient.py +77 -0
  60. nedo_vision_worker/services/VideoStreamClient.py +161 -0
  61. nedo_vision_worker/services/WorkerSourceClient.py +215 -0
  62. nedo_vision_worker/services/WorkerSourcePipelineClient.py +393 -0
  63. nedo_vision_worker/services/WorkerSourceUpdater.py +134 -0
  64. nedo_vision_worker/services/WorkerStatusClient.py +65 -0
  65. nedo_vision_worker/services/__init__.py +1 -0
  66. nedo_vision_worker/util/HardwareID.py +104 -0
  67. nedo_vision_worker/util/ImageUploader.py +92 -0
  68. nedo_vision_worker/util/Networking.py +94 -0
  69. nedo_vision_worker/util/PlatformDetector.py +50 -0
  70. nedo_vision_worker/util/SystemMonitor.py +299 -0
  71. nedo_vision_worker/util/VideoProbeUtil.py +120 -0
  72. nedo_vision_worker/util/__init__.py +1 -0
  73. nedo_vision_worker/worker/CoreActionWorker.py +125 -0
  74. nedo_vision_worker/worker/DataSenderWorker.py +168 -0
  75. nedo_vision_worker/worker/DataSyncWorker.py +143 -0
  76. nedo_vision_worker/worker/DatasetFrameSender.py +208 -0
  77. nedo_vision_worker/worker/DatasetFrameWorker.py +412 -0
  78. nedo_vision_worker/worker/PPEDetectionManager.py +86 -0
  79. nedo_vision_worker/worker/PipelineActionWorker.py +129 -0
  80. nedo_vision_worker/worker/PipelineImageWorker.py +116 -0
  81. nedo_vision_worker/worker/RabbitMQListener.py +170 -0
  82. nedo_vision_worker/worker/RestrictedAreaManager.py +85 -0
  83. nedo_vision_worker/worker/SystemUsageManager.py +111 -0
  84. nedo_vision_worker/worker/VideoStreamWorker.py +139 -0
  85. nedo_vision_worker/worker/WorkerManager.py +155 -0
  86. nedo_vision_worker/worker/__init__.py +1 -0
  87. nedo_vision_worker/worker_service.py +264 -0
  88. nedo_vision_worker-1.0.0.dist-info/METADATA +563 -0
  89. nedo_vision_worker-1.0.0.dist-info/RECORD +92 -0
  90. nedo_vision_worker-1.0.0.dist-info/WHEEL +5 -0
  91. nedo_vision_worker-1.0.0.dist-info/entry_points.txt +2 -0
  92. nedo_vision_worker-1.0.0.dist-info/top_level.txt +1 -0
@@ -0,0 +1,140 @@
1
+ # Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
2
+ """Client and server classes corresponding to protobuf-defined services."""
3
+ import grpc
4
+ import warnings
5
+
6
+ from nedo_vision_worker.protos import HumanDetectionService_pb2 as nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2
7
+
8
+ GRPC_GENERATED_VERSION = '1.73.1'
9
+ GRPC_VERSION = grpc.__version__
10
+ _version_not_supported = False
11
+
12
+ try:
13
+ from grpc._utilities import first_version_is_lower
14
+ _version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION)
15
+ except ImportError:
16
+ _version_not_supported = True
17
+
18
+ if _version_not_supported:
19
+ raise RuntimeError(
20
+ f'The grpc package installed is at version {GRPC_VERSION},'
21
+ + f' but the generated code in nedo_vision_worker/protos/HumanDetectionService_pb2_grpc.py depends on'
22
+ + f' grpcio>={GRPC_GENERATED_VERSION}.'
23
+ + f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}'
24
+ + f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.'
25
+ )
26
+
27
+
28
+ class HumanDetectionGRPCServiceStub(object):
29
+ """Missing associated documentation comment in .proto file."""
30
+
31
+ def __init__(self, channel):
32
+ """Constructor.
33
+
34
+ Args:
35
+ channel: A grpc.Channel.
36
+ """
37
+ self.Upsert = channel.unary_unary(
38
+ '/Sindika.AspNet.App005.Services.HumanDetectionGRPCService/Upsert',
39
+ request_serializer=nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionRequest.SerializeToString,
40
+ response_deserializer=nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionResponse.FromString,
41
+ _registered_method=True)
42
+ self.UpsertBatch = channel.unary_unary(
43
+ '/Sindika.AspNet.App005.Services.HumanDetectionGRPCService/UpsertBatch',
44
+ request_serializer=nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionBatchRequest.SerializeToString,
45
+ response_deserializer=nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionBatchResponse.FromString,
46
+ _registered_method=True)
47
+
48
+
49
+ class HumanDetectionGRPCServiceServicer(object):
50
+ """Missing associated documentation comment in .proto file."""
51
+
52
+ def Upsert(self, request, context):
53
+ """Missing associated documentation comment in .proto file."""
54
+ context.set_code(grpc.StatusCode.UNIMPLEMENTED)
55
+ context.set_details('Method not implemented!')
56
+ raise NotImplementedError('Method not implemented!')
57
+
58
+ def UpsertBatch(self, request, context):
59
+ """Missing associated documentation comment in .proto file."""
60
+ context.set_code(grpc.StatusCode.UNIMPLEMENTED)
61
+ context.set_details('Method not implemented!')
62
+ raise NotImplementedError('Method not implemented!')
63
+
64
+
65
+ def add_HumanDetectionGRPCServiceServicer_to_server(servicer, server):
66
+ rpc_method_handlers = {
67
+ 'Upsert': grpc.unary_unary_rpc_method_handler(
68
+ servicer.Upsert,
69
+ request_deserializer=nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionRequest.FromString,
70
+ response_serializer=nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionResponse.SerializeToString,
71
+ ),
72
+ 'UpsertBatch': grpc.unary_unary_rpc_method_handler(
73
+ servicer.UpsertBatch,
74
+ request_deserializer=nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionBatchRequest.FromString,
75
+ response_serializer=nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionBatchResponse.SerializeToString,
76
+ ),
77
+ }
78
+ generic_handler = grpc.method_handlers_generic_handler(
79
+ 'Sindika.AspNet.App005.Services.HumanDetectionGRPCService', rpc_method_handlers)
80
+ server.add_generic_rpc_handlers((generic_handler,))
81
+ server.add_registered_method_handlers('Sindika.AspNet.App005.Services.HumanDetectionGRPCService', rpc_method_handlers)
82
+
83
+
84
+ # This class is part of an EXPERIMENTAL API.
85
+ class HumanDetectionGRPCService(object):
86
+ """Missing associated documentation comment in .proto file."""
87
+
88
+ @staticmethod
89
+ def Upsert(request,
90
+ target,
91
+ options=(),
92
+ channel_credentials=None,
93
+ call_credentials=None,
94
+ insecure=False,
95
+ compression=None,
96
+ wait_for_ready=None,
97
+ timeout=None,
98
+ metadata=None):
99
+ return grpc.experimental.unary_unary(
100
+ request,
101
+ target,
102
+ '/Sindika.AspNet.App005.Services.HumanDetectionGRPCService/Upsert',
103
+ nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionRequest.SerializeToString,
104
+ nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionResponse.FromString,
105
+ options,
106
+ channel_credentials,
107
+ insecure,
108
+ call_credentials,
109
+ compression,
110
+ wait_for_ready,
111
+ timeout,
112
+ metadata,
113
+ _registered_method=True)
114
+
115
+ @staticmethod
116
+ def UpsertBatch(request,
117
+ target,
118
+ options=(),
119
+ channel_credentials=None,
120
+ call_credentials=None,
121
+ insecure=False,
122
+ compression=None,
123
+ wait_for_ready=None,
124
+ timeout=None,
125
+ metadata=None):
126
+ return grpc.experimental.unary_unary(
127
+ request,
128
+ target,
129
+ '/Sindika.AspNet.App005.Services.HumanDetectionGRPCService/UpsertBatch',
130
+ nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionBatchRequest.SerializeToString,
131
+ nedo__vision__worker_dot_protos_dot_HumanDetectionService__pb2.UpsertHumanDetectionBatchResponse.FromString,
132
+ options,
133
+ channel_credentials,
134
+ insecure,
135
+ call_credentials,
136
+ compression,
137
+ wait_for_ready,
138
+ timeout,
139
+ metadata,
140
+ _registered_method=True)
@@ -0,0 +1,46 @@
1
+ # -*- coding: utf-8 -*-
2
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
3
+ # NO CHECKED-IN PROTOBUF GENCODE
4
+ # source: nedo_vision_worker/protos/PPEDetectionService.proto
5
+ # Protobuf Python Version: 6.31.0
6
+ """Generated protocol buffer code."""
7
+ from google.protobuf import descriptor as _descriptor
8
+ from google.protobuf import descriptor_pool as _descriptor_pool
9
+ from google.protobuf import runtime_version as _runtime_version
10
+ from google.protobuf import symbol_database as _symbol_database
11
+ from google.protobuf.internal import builder as _builder
12
+ _runtime_version.ValidateProtobufRuntimeVersion(
13
+ _runtime_version.Domain.PUBLIC,
14
+ 6,
15
+ 31,
16
+ 0,
17
+ '',
18
+ 'nedo_vision_worker/protos/PPEDetectionService.proto'
19
+ )
20
+ # @@protoc_insertion_point(imports)
21
+
22
+ _sym_db = _symbol_database.Default()
23
+
24
+
25
+
26
+
27
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n3nedo_vision_worker/protos/PPEDetectionService.proto\x12\x1eSindika.AspNet.App005.Services\">\n\x1aUpsertPPEDetectionResponse\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x0f\n\x07message\x18\x02 \x01(\t\"C\n\x1fUpsertPPEDetectionBatchResponse\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x0f\n\x07message\x18\x02 \x01(\t\"\xff\x01\n\x19UpsertPPEDetectionRequest\x12\x11\n\tperson_id\x18\x01 \x01(\t\x12\x11\n\tworker_id\x18\x02 \x01(\t\x12\x18\n\x10worker_source_id\x18\x03 \x01(\t\x12\r\n\x05image\x18\x04 \x01(\x0c\x12\x18\n\x10worker_timestamp\x18\x05 \x01(\t\x12V\n\x14ppe_detection_labels\x18\x06 \x03(\x0b\x32\x38.Sindika.AspNet.App005.Services.PPEDetectionLabelRequest\x12\x12\n\nimage_tile\x18\x07 \x01(\x0c\x12\r\n\x05token\x18\x08 \x01(\t\"\x99\x01\n\x18PPEDetectionLabelRequest\x12\x0c\n\x04\x63ode\x18\x01 \x01(\t\x12\x18\n\x10\x63onfidence_score\x18\x02 \x01(\x01\x12\x10\n\x08\x62_box_x1\x18\x03 \x01(\x01\x12\x10\n\x08\x62_box_y1\x18\x04 \x01(\x01\x12\x10\n\x08\x62_box_x2\x18\x05 \x01(\x01\x12\x10\n\x08\x62_box_y2\x18\x06 \x01(\x01\x12\r\n\x05token\x18\x07 \x01(\t\"\x8a\x01\n\x1eUpsertPPEDetectionBatchRequest\x12Y\n\x16ppe_detection_requests\x18\x01 \x03(\x0b\x32\x39.Sindika.AspNet.App005.Services.UpsertPPEDetectionRequest\x12\r\n\x05token\x18\x02 \x01(\t2\xab\x02\n\x17PPEDetectionGRPCService\x12\x7f\n\x06Upsert\x12\x39.Sindika.AspNet.App005.Services.UpsertPPEDetectionRequest\x1a:.Sindika.AspNet.App005.Services.UpsertPPEDetectionResponse\x12\x8e\x01\n\x0bUpsertBatch\x12>.Sindika.AspNet.App005.Services.UpsertPPEDetectionBatchRequest\x1a?.Sindika.AspNet.App005.Services.UpsertPPEDetectionBatchResponseb\x06proto3')
28
+
29
+ _globals = globals()
30
+ _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
31
+ _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'nedo_vision_worker.protos.PPEDetectionService_pb2', _globals)
32
+ if not _descriptor._USE_C_DESCRIPTORS:
33
+ DESCRIPTOR._loaded_options = None
34
+ _globals['_UPSERTPPEDETECTIONRESPONSE']._serialized_start=87
35
+ _globals['_UPSERTPPEDETECTIONRESPONSE']._serialized_end=149
36
+ _globals['_UPSERTPPEDETECTIONBATCHRESPONSE']._serialized_start=151
37
+ _globals['_UPSERTPPEDETECTIONBATCHRESPONSE']._serialized_end=218
38
+ _globals['_UPSERTPPEDETECTIONREQUEST']._serialized_start=221
39
+ _globals['_UPSERTPPEDETECTIONREQUEST']._serialized_end=476
40
+ _globals['_PPEDETECTIONLABELREQUEST']._serialized_start=479
41
+ _globals['_PPEDETECTIONLABELREQUEST']._serialized_end=632
42
+ _globals['_UPSERTPPEDETECTIONBATCHREQUEST']._serialized_start=635
43
+ _globals['_UPSERTPPEDETECTIONBATCHREQUEST']._serialized_end=773
44
+ _globals['_PPEDETECTIONGRPCSERVICE']._serialized_start=776
45
+ _globals['_PPEDETECTIONGRPCSERVICE']._serialized_end=1075
46
+ # @@protoc_insertion_point(module_scope)
@@ -0,0 +1,140 @@
1
+ # Generated by the gRPC Python protocol compiler plugin. DO NOT EDIT!
2
+ """Client and server classes corresponding to protobuf-defined services."""
3
+ import grpc
4
+ import warnings
5
+
6
+ from nedo_vision_worker.protos import PPEDetectionService_pb2 as nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2
7
+
8
+ GRPC_GENERATED_VERSION = '1.73.1'
9
+ GRPC_VERSION = grpc.__version__
10
+ _version_not_supported = False
11
+
12
+ try:
13
+ from grpc._utilities import first_version_is_lower
14
+ _version_not_supported = first_version_is_lower(GRPC_VERSION, GRPC_GENERATED_VERSION)
15
+ except ImportError:
16
+ _version_not_supported = True
17
+
18
+ if _version_not_supported:
19
+ raise RuntimeError(
20
+ f'The grpc package installed is at version {GRPC_VERSION},'
21
+ + f' but the generated code in nedo_vision_worker/protos/PPEDetectionService_pb2_grpc.py depends on'
22
+ + f' grpcio>={GRPC_GENERATED_VERSION}.'
23
+ + f' Please upgrade your grpc module to grpcio>={GRPC_GENERATED_VERSION}'
24
+ + f' or downgrade your generated code using grpcio-tools<={GRPC_VERSION}.'
25
+ )
26
+
27
+
28
+ class PPEDetectionGRPCServiceStub(object):
29
+ """Missing associated documentation comment in .proto file."""
30
+
31
+ def __init__(self, channel):
32
+ """Constructor.
33
+
34
+ Args:
35
+ channel: A grpc.Channel.
36
+ """
37
+ self.Upsert = channel.unary_unary(
38
+ '/Sindika.AspNet.App005.Services.PPEDetectionGRPCService/Upsert',
39
+ request_serializer=nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionRequest.SerializeToString,
40
+ response_deserializer=nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionResponse.FromString,
41
+ _registered_method=True)
42
+ self.UpsertBatch = channel.unary_unary(
43
+ '/Sindika.AspNet.App005.Services.PPEDetectionGRPCService/UpsertBatch',
44
+ request_serializer=nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionBatchRequest.SerializeToString,
45
+ response_deserializer=nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionBatchResponse.FromString,
46
+ _registered_method=True)
47
+
48
+
49
+ class PPEDetectionGRPCServiceServicer(object):
50
+ """Missing associated documentation comment in .proto file."""
51
+
52
+ def Upsert(self, request, context):
53
+ """Missing associated documentation comment in .proto file."""
54
+ context.set_code(grpc.StatusCode.UNIMPLEMENTED)
55
+ context.set_details('Method not implemented!')
56
+ raise NotImplementedError('Method not implemented!')
57
+
58
+ def UpsertBatch(self, request, context):
59
+ """Missing associated documentation comment in .proto file."""
60
+ context.set_code(grpc.StatusCode.UNIMPLEMENTED)
61
+ context.set_details('Method not implemented!')
62
+ raise NotImplementedError('Method not implemented!')
63
+
64
+
65
+ def add_PPEDetectionGRPCServiceServicer_to_server(servicer, server):
66
+ rpc_method_handlers = {
67
+ 'Upsert': grpc.unary_unary_rpc_method_handler(
68
+ servicer.Upsert,
69
+ request_deserializer=nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionRequest.FromString,
70
+ response_serializer=nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionResponse.SerializeToString,
71
+ ),
72
+ 'UpsertBatch': grpc.unary_unary_rpc_method_handler(
73
+ servicer.UpsertBatch,
74
+ request_deserializer=nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionBatchRequest.FromString,
75
+ response_serializer=nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionBatchResponse.SerializeToString,
76
+ ),
77
+ }
78
+ generic_handler = grpc.method_handlers_generic_handler(
79
+ 'Sindika.AspNet.App005.Services.PPEDetectionGRPCService', rpc_method_handlers)
80
+ server.add_generic_rpc_handlers((generic_handler,))
81
+ server.add_registered_method_handlers('Sindika.AspNet.App005.Services.PPEDetectionGRPCService', rpc_method_handlers)
82
+
83
+
84
+ # This class is part of an EXPERIMENTAL API.
85
+ class PPEDetectionGRPCService(object):
86
+ """Missing associated documentation comment in .proto file."""
87
+
88
+ @staticmethod
89
+ def Upsert(request,
90
+ target,
91
+ options=(),
92
+ channel_credentials=None,
93
+ call_credentials=None,
94
+ insecure=False,
95
+ compression=None,
96
+ wait_for_ready=None,
97
+ timeout=None,
98
+ metadata=None):
99
+ return grpc.experimental.unary_unary(
100
+ request,
101
+ target,
102
+ '/Sindika.AspNet.App005.Services.PPEDetectionGRPCService/Upsert',
103
+ nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionRequest.SerializeToString,
104
+ nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionResponse.FromString,
105
+ options,
106
+ channel_credentials,
107
+ insecure,
108
+ call_credentials,
109
+ compression,
110
+ wait_for_ready,
111
+ timeout,
112
+ metadata,
113
+ _registered_method=True)
114
+
115
+ @staticmethod
116
+ def UpsertBatch(request,
117
+ target,
118
+ options=(),
119
+ channel_credentials=None,
120
+ call_credentials=None,
121
+ insecure=False,
122
+ compression=None,
123
+ wait_for_ready=None,
124
+ timeout=None,
125
+ metadata=None):
126
+ return grpc.experimental.unary_unary(
127
+ request,
128
+ target,
129
+ '/Sindika.AspNet.App005.Services.PPEDetectionGRPCService/UpsertBatch',
130
+ nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionBatchRequest.SerializeToString,
131
+ nedo__vision__worker_dot_protos_dot_PPEDetectionService__pb2.UpsertPPEDetectionBatchResponse.FromString,
132
+ options,
133
+ channel_credentials,
134
+ insecure,
135
+ call_credentials,
136
+ compression,
137
+ wait_for_ready,
138
+ timeout,
139
+ metadata,
140
+ _registered_method=True)
@@ -0,0 +1,72 @@
1
+ # -*- coding: utf-8 -*-
2
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
3
+ # NO CHECKED-IN PROTOBUF GENCODE
4
+ # source: nedo_vision_worker/protos/VisionWorkerService.proto
5
+ # Protobuf Python Version: 6.31.0
6
+ """Generated protocol buffer code."""
7
+ from google.protobuf import descriptor as _descriptor
8
+ from google.protobuf import descriptor_pool as _descriptor_pool
9
+ from google.protobuf import runtime_version as _runtime_version
10
+ from google.protobuf import symbol_database as _symbol_database
11
+ from google.protobuf.internal import builder as _builder
12
+ _runtime_version.ValidateProtobufRuntimeVersion(
13
+ _runtime_version.Domain.PUBLIC,
14
+ 6,
15
+ 31,
16
+ 0,
17
+ '',
18
+ 'nedo_vision_worker/protos/VisionWorkerService.proto'
19
+ )
20
+ # @@protoc_insertion_point(imports)
21
+
22
+ _sym_db = _symbol_database.Default()
23
+
24
+
25
+
26
+
27
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n3nedo_vision_worker/protos/VisionWorkerService.proto\x12\x1eSindika.AspNet.App005.Services\"/\n\x1eGetWorkerConnectionInfoRequest\x12\r\n\x05token\x18\x01 \x01(\t\"\xbf\x01\n\x1fGetWorkerConnectionInfoResponse\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x0f\n\x07message\x18\x02 \x01(\t\x12\x15\n\rrabbitmq_host\x18\x03 \x01(\t\x12\x15\n\rrabbitmq_port\x18\x04 \x01(\x05\x12\x19\n\x11rabbitmq_username\x18\x05 \x01(\t\x12\x19\n\x11rabbitmq_password\x18\x06 \x01(\t\x12\x0f\n\x02id\x18\x07 \x01(\tH\x00\x88\x01\x01\x42\x05\n\x03_id\"\xff\x01\n\x12SystemUsageRequest\x12\x11\n\tdevice_id\x18\x01 \x01(\t\x12\x11\n\tcpu_usage\x18\x02 \x01(\x02\x12\x17\n\x0f\x63pu_temperature\x18\x03 \x01(\x02\x12\x19\n\x11ram_usage_percent\x18\x04 \x01(\x02\x12\x11\n\tram_total\x18\x05 \x01(\x04\x12\x10\n\x08ram_used\x18\x06 \x01(\x04\x12\x10\n\x08ram_free\x18\x07 \x01(\x04\x12\x35\n\x03gpu\x18\x08 \x03(\x0b\x32(.Sindika.AspNet.App005.Services.GPUUsage\x12\x12\n\nlatency_ms\x18\t \x01(\x02\x12\r\n\x05token\x18\n \x01(\t\"\xb3\x01\n\x08GPUUsage\x12\x11\n\tgpu_index\x18\x01 \x01(\x05\x12\x19\n\x11gpu_usage_percent\x18\x02 \x01(\x02\x12\x1c\n\x14memory_usage_percent\x18\x03 \x01(\x02\x12\x1b\n\x13temperature_celsius\x18\x04 \x01(\x02\x12\x14\n\x0ctotal_memory\x18\x05 \x01(\x04\x12\x13\n\x0bused_memory\x18\x06 \x01(\x04\x12\x13\n\x0b\x66ree_memory\x18\x07 \x01(\x04\"7\n\x13SystemUsageResponse\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x0f\n\x07message\x18\x02 \x01(\t\"8\n\x14LastImageDateRequest\x12\x11\n\tdevice_id\x18\x01 \x01(\t\x12\r\n\x05token\x18\x02 \x01(\t\"U\n\x15LastImageDateResponse\x12\x1a\n\x12last_uploaded_date\x18\x01 \x01(\t\x12\x0f\n\x07success\x18\x02 \x01(\x08\x12\x0f\n\x07message\x18\x03 \x01(\t\"\\\n\x12UploadImageRequest\x12\x11\n\tdevice_id\x18\x01 \x01(\t\x12\x10\n\x08metadata\x18\x02 \x01(\t\x12\x12\n\nimage_data\x18\x03 \x01(\x0c\x12\r\n\x05token\x18\x04 \x01(\t\"7\n\x13UploadImageResponse\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x0f\n\x07message\x18\x02 \x01(\t\"\x14\n\x12HealthCheckRequest\"%\n\x13HealthCheckResponse\x12\x0e\n\x06status\x18\x01 \x01(\t\"T\n\nVideoFrame\x12\x11\n\tworker_id\x18\x01 \x01(\t\x12\x0c\n\x04uuid\x18\x02 \x01(\t\x12\x12\n\nframe_data\x18\x03 \x01(\x0c\x12\x11\n\ttimestamp\x18\x04 \x01(\x03\"1\n\rVideoResponse\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x0f\n\x07message\x18\x02 \x01(\t\"e\n\x19UpdateWorkerStatusRequest\x12\x11\n\tworker_id\x18\x01 \x01(\t\x12\x13\n\x0bstatus_code\x18\x02 \x01(\t\x12\x11\n\ttimestamp\x18\x03 \x01(\x03\x12\r\n\x05token\x18\x04 \x01(\t\">\n\x1aUpdateWorkerStatusResponse\x12\x0f\n\x07success\x18\x01 \x01(\x08\x12\x0f\n\x07message\x18\x02 \x01(\t2\xb0\x03\n\x13VisionWorkerService\x12\x94\x01\n\x11GetConnectionInfo\x12>.Sindika.AspNet.App005.Services.GetWorkerConnectionInfoRequest\x1a?.Sindika.AspNet.App005.Services.GetWorkerConnectionInfoResponse\x12z\n\x0fSendSystemUsage\x12\x32.Sindika.AspNet.App005.Services.SystemUsageRequest\x1a\x33.Sindika.AspNet.App005.Services.SystemUsageResponse\x12\x85\x01\n\x0cUpdateStatus\x12\x39.Sindika.AspNet.App005.Services.UpdateWorkerStatusRequest\x1a:.Sindika.AspNet.App005.Services.UpdateWorkerStatusResponse2\x87\x02\n\x0cImageService\x12\x7f\n\x10GetLastImageDate\x12\x34.Sindika.AspNet.App005.Services.LastImageDateRequest\x1a\x35.Sindika.AspNet.App005.Services.LastImageDateResponse\x12v\n\x0bUploadImage\x12\x32.Sindika.AspNet.App005.Services.UploadImageRequest\x1a\x33.Sindika.AspNet.App005.Services.UploadImageResponse2\x8c\x01\n\x12HealthCheckService\x12v\n\x0bHealthCheck\x12\x32.Sindika.AspNet.App005.Services.HealthCheckRequest\x1a\x33.Sindika.AspNet.App005.Services.HealthCheckResponse2\x80\x01\n\x12VideoStreamService\x12j\n\x0bStreamVideo\x12*.Sindika.AspNet.App005.Services.VideoFrame\x1a-.Sindika.AspNet.App005.Services.VideoResponse(\x01\x62\x06proto3')
28
+
29
+ _globals = globals()
30
+ _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
31
+ _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'nedo_vision_worker.protos.VisionWorkerService_pb2', _globals)
32
+ if not _descriptor._USE_C_DESCRIPTORS:
33
+ DESCRIPTOR._loaded_options = None
34
+ _globals['_GETWORKERCONNECTIONINFOREQUEST']._serialized_start=87
35
+ _globals['_GETWORKERCONNECTIONINFOREQUEST']._serialized_end=134
36
+ _globals['_GETWORKERCONNECTIONINFORESPONSE']._serialized_start=137
37
+ _globals['_GETWORKERCONNECTIONINFORESPONSE']._serialized_end=328
38
+ _globals['_SYSTEMUSAGEREQUEST']._serialized_start=331
39
+ _globals['_SYSTEMUSAGEREQUEST']._serialized_end=586
40
+ _globals['_GPUUSAGE']._serialized_start=589
41
+ _globals['_GPUUSAGE']._serialized_end=768
42
+ _globals['_SYSTEMUSAGERESPONSE']._serialized_start=770
43
+ _globals['_SYSTEMUSAGERESPONSE']._serialized_end=825
44
+ _globals['_LASTIMAGEDATEREQUEST']._serialized_start=827
45
+ _globals['_LASTIMAGEDATEREQUEST']._serialized_end=883
46
+ _globals['_LASTIMAGEDATERESPONSE']._serialized_start=885
47
+ _globals['_LASTIMAGEDATERESPONSE']._serialized_end=970
48
+ _globals['_UPLOADIMAGEREQUEST']._serialized_start=972
49
+ _globals['_UPLOADIMAGEREQUEST']._serialized_end=1064
50
+ _globals['_UPLOADIMAGERESPONSE']._serialized_start=1066
51
+ _globals['_UPLOADIMAGERESPONSE']._serialized_end=1121
52
+ _globals['_HEALTHCHECKREQUEST']._serialized_start=1123
53
+ _globals['_HEALTHCHECKREQUEST']._serialized_end=1143
54
+ _globals['_HEALTHCHECKRESPONSE']._serialized_start=1145
55
+ _globals['_HEALTHCHECKRESPONSE']._serialized_end=1182
56
+ _globals['_VIDEOFRAME']._serialized_start=1184
57
+ _globals['_VIDEOFRAME']._serialized_end=1268
58
+ _globals['_VIDEORESPONSE']._serialized_start=1270
59
+ _globals['_VIDEORESPONSE']._serialized_end=1319
60
+ _globals['_UPDATEWORKERSTATUSREQUEST']._serialized_start=1321
61
+ _globals['_UPDATEWORKERSTATUSREQUEST']._serialized_end=1422
62
+ _globals['_UPDATEWORKERSTATUSRESPONSE']._serialized_start=1424
63
+ _globals['_UPDATEWORKERSTATUSRESPONSE']._serialized_end=1486
64
+ _globals['_VISIONWORKERSERVICE']._serialized_start=1489
65
+ _globals['_VISIONWORKERSERVICE']._serialized_end=1921
66
+ _globals['_IMAGESERVICE']._serialized_start=1924
67
+ _globals['_IMAGESERVICE']._serialized_end=2187
68
+ _globals['_HEALTHCHECKSERVICE']._serialized_start=2190
69
+ _globals['_HEALTHCHECKSERVICE']._serialized_end=2330
70
+ _globals['_VIDEOSTREAMSERVICE']._serialized_start=2333
71
+ _globals['_VIDEOSTREAMSERVICE']._serialized_end=2461
72
+ # @@protoc_insertion_point(module_scope)