diff --git a/Makefile b/Makefile
index 2419dc5..ab67aef 100644
--- a/Makefile
+++ b/Makefile
@@ -1,18 +1,26 @@
VERSION := $(shell cat VERSION)
+REQUIRED_PROTOC_VERSION := 31.1
-.PHONY: all python java readme
+.PHONY: all python java readme check-protoc-version
-all: clean python java readme
+all: check-protoc-version clean python java readme
+
+check-protoc-version:
+ @INSTALLED_VERSION=$$(protoc --version | awk '{print $$2}'); \
+ if [ "$$INSTALLED_VERSION" != "$(REQUIRED_PROTOC_VERSION)" ]; then \
+ echo "Error: protoc version $(REQUIRED_PROTOC_VERSION) required, but $$INSTALLED_VERSION is installed."; \
+ exit 1; \
+ fi
clean:
rm -f python/visionapi/visionapi/*pb2.py*
rm -f java/visionapi/src/main/java/de/starwit/visionapi/*.java
-python:
+python: check-protoc-version
protoc -I=. --python_out=python/visionapi/ --pyi_out=python/visionapi/ visionapi/*.proto
(cd python/visionapi && poetry version $(VERSION))
-java:
+java: check-protoc-version
protoc -I=. --java_out=java/visionapi/src/main/java/ visionapi/*.proto
(cd java/visionapi && mvn versions:set -DgenerateBackupPoms=false -DnewVersion=$(VERSION))
diff --git a/README.md b/README.md
index 44de750..37fd984 100644
--- a/README.md
+++ b/README.md
@@ -6,7 +6,7 @@ This repo contains the main data model for the Starwit Awareness Engine (SAE). S
### Python / Poetry
- Add the following to your `pyproject.toml` dependencies section\
- `visionapi = { git = "https://github.com/starwit/vision-api.git", subdirectory = "python/visionapi", tag = "3.4.0" }`
+ `visionapi = { git = "https://github.com/starwit/vision-api.git", subdirectory = "python/visionapi", tag = "3.5.0" }`
### Java / Maven
- Add dependency to your project:
@@ -14,7 +14,7 @@ This repo contains the main data model for the Starwit Awareness Engine (SAE). S
de.starwit
vision-api
- 3.4.0
+ 3.5.0
```
- Add maven repository to your `~/.m2/settings.xml` (adapt example / your config as necessary):
@@ -65,7 +65,7 @@ This repo contains the main data model for the Starwit Awareness Engine (SAE). S
sudo apt install pipx
pipx install protoc-wrapper==31.1.0
```
-* ! If you change protoc version, you need to change protobuf version in `java\visionapi\pom.xml` and `python\visionapi\pyproject.toml`
+* ! If you change protoc version, you need to change protobuf version in `java\visionapi\pom.xml`, `python\visionapi\pyproject.toml` and protoc version in `Makefile`
## How-To Update
1. Make desired changes in `./visionapi`
@@ -82,6 +82,9 @@ This repo contains the main data model for the Starwit Awareness Engine (SAE). S
```
## Changelog
+### 3.5.0
+- Add `ModelMetadata` containing `class_names` mapping to `SaeMessage`
+
### 3.4.0
- Add `MessageType` field `type` to all top-level messages
- Add `TypeMessage` as a dummy to deserialize type field
diff --git a/VERSION b/VERSION
index fbcbf73..e5b8203 100644
--- a/VERSION
+++ b/VERSION
@@ -1 +1 @@
-3.4.0
\ No newline at end of file
+3.5.0
\ No newline at end of file
diff --git a/java/visionapi/pom.xml b/java/visionapi/pom.xml
index f069aa4..b17e113 100644
--- a/java/visionapi/pom.xml
+++ b/java/visionapi/pom.xml
@@ -6,7 +6,7 @@
vision-api
jar
- 3.4.0
+ 3.5.0
visionapi
https://github.com/starwit/vision-api
diff --git a/java/visionapi/src/main/java/de/starwit/visionapi/Sae.java b/java/visionapi/src/main/java/de/starwit/visionapi/Sae.java
index 2cb378c..542030c 100644
--- a/java/visionapi/src/main/java/de/starwit/visionapi/Sae.java
+++ b/java/visionapi/src/main/java/de/starwit/visionapi/Sae.java
@@ -84,6 +84,21 @@ de.starwit.visionapi.Sae.DetectionOrBuilder getDetectionsOrBuilder(
*/
de.starwit.visionapi.Sae.MetricsOrBuilder getMetricsOrBuilder();
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ * @return Whether the modelMetadata field is set.
+ */
+ boolean hasModelMetadata();
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ * @return The modelMetadata.
+ */
+ de.starwit.visionapi.Sae.ModelMetadata getModelMetadata();
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ */
+ de.starwit.visionapi.Sae.ModelMetadataOrBuilder getModelMetadataOrBuilder();
+
/**
* .visionapi.MessageType type = 1000;
* @return The enum numeric value on the wire for type.
@@ -228,6 +243,32 @@ public de.starwit.visionapi.Sae.MetricsOrBuilder getMetricsOrBuilder() {
return metrics_ == null ? de.starwit.visionapi.Sae.Metrics.getDefaultInstance() : metrics_;
}
+ public static final int MODEL_METADATA_FIELD_NUMBER = 100;
+ private de.starwit.visionapi.Sae.ModelMetadata modelMetadata_;
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ * @return Whether the modelMetadata field is set.
+ */
+ @java.lang.Override
+ public boolean hasModelMetadata() {
+ return ((bitField0_ & 0x00000004) != 0);
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ * @return The modelMetadata.
+ */
+ @java.lang.Override
+ public de.starwit.visionapi.Sae.ModelMetadata getModelMetadata() {
+ return modelMetadata_ == null ? de.starwit.visionapi.Sae.ModelMetadata.getDefaultInstance() : modelMetadata_;
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ */
+ @java.lang.Override
+ public de.starwit.visionapi.Sae.ModelMetadataOrBuilder getModelMetadataOrBuilder() {
+ return modelMetadata_ == null ? de.starwit.visionapi.Sae.ModelMetadata.getDefaultInstance() : modelMetadata_;
+ }
+
public static final int TYPE_FIELD_NUMBER = 1000;
private int type_ = 0;
/**
@@ -269,6 +310,9 @@ public void writeTo(com.google.protobuf.CodedOutputStream output)
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(99, getMetrics());
}
+ if (((bitField0_ & 0x00000004) != 0)) {
+ output.writeMessage(100, getModelMetadata());
+ }
if (type_ != de.starwit.visionapi.Common.MessageType.UNSPECIFIED.getNumber()) {
output.writeEnum(1000, type_);
}
@@ -293,6 +337,10 @@ public int getSerializedSize() {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(99, getMetrics());
}
+ if (((bitField0_ & 0x00000004) != 0)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(100, getModelMetadata());
+ }
if (type_ != de.starwit.visionapi.Common.MessageType.UNSPECIFIED.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1000, type_);
@@ -324,6 +372,11 @@ public boolean equals(final java.lang.Object obj) {
if (!getMetrics()
.equals(other.getMetrics())) return false;
}
+ if (hasModelMetadata() != other.hasModelMetadata()) return false;
+ if (hasModelMetadata()) {
+ if (!getModelMetadata()
+ .equals(other.getModelMetadata())) return false;
+ }
if (type_ != other.type_) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
@@ -348,6 +401,10 @@ public int hashCode() {
hash = (37 * hash) + METRICS_FIELD_NUMBER;
hash = (53 * hash) + getMetrics().hashCode();
}
+ if (hasModelMetadata()) {
+ hash = (37 * hash) + MODEL_METADATA_FIELD_NUMBER;
+ hash = (53 * hash) + getModelMetadata().hashCode();
+ }
hash = (37 * hash) + TYPE_FIELD_NUMBER;
hash = (53 * hash) + type_;
hash = (29 * hash) + getUnknownFields().hashCode();
@@ -483,6 +540,7 @@ private void maybeForceBuilderInitialization() {
internalGetFrameFieldBuilder();
internalGetDetectionsFieldBuilder();
internalGetMetricsFieldBuilder();
+ internalGetModelMetadataFieldBuilder();
}
}
@java.lang.Override
@@ -506,6 +564,11 @@ public Builder clear() {
metricsBuilder_.dispose();
metricsBuilder_ = null;
}
+ modelMetadata_ = null;
+ if (modelMetadataBuilder_ != null) {
+ modelMetadataBuilder_.dispose();
+ modelMetadataBuilder_ = null;
+ }
type_ = 0;
return this;
}
@@ -567,6 +630,12 @@ private void buildPartial0(de.starwit.visionapi.Sae.SaeMessage result) {
to_bitField0_ |= 0x00000002;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
+ result.modelMetadata_ = modelMetadataBuilder_ == null
+ ? modelMetadata_
+ : modelMetadataBuilder_.build();
+ to_bitField0_ |= 0x00000004;
+ }
+ if (((from_bitField0_ & 0x00000010) != 0)) {
result.type_ = type_;
}
result.bitField0_ |= to_bitField0_;
@@ -616,6 +685,9 @@ public Builder mergeFrom(de.starwit.visionapi.Sae.SaeMessage other) {
if (other.hasMetrics()) {
mergeMetrics(other.getMetrics());
}
+ if (other.hasModelMetadata()) {
+ mergeModelMetadata(other.getModelMetadata());
+ }
if (other.type_ != 0) {
setTypeValue(other.getTypeValue());
}
@@ -672,9 +744,16 @@ public Builder mergeFrom(
bitField0_ |= 0x00000004;
break;
} // case 794
+ case 802: {
+ input.readMessage(
+ internalGetModelMetadataFieldBuilder().getBuilder(),
+ extensionRegistry);
+ bitField0_ |= 0x00000008;
+ break;
+ } // case 802
case 8000: {
type_ = input.readEnum();
- bitField0_ |= 0x00000008;
+ bitField0_ |= 0x00000010;
break;
} // case 8000
default: {
@@ -1176,6 +1255,127 @@ public de.starwit.visionapi.Sae.MetricsOrBuilder getMetricsOrBuilder() {
return metricsBuilder_;
}
+ private de.starwit.visionapi.Sae.ModelMetadata modelMetadata_;
+ private com.google.protobuf.SingleFieldBuilder<
+ de.starwit.visionapi.Sae.ModelMetadata, de.starwit.visionapi.Sae.ModelMetadata.Builder, de.starwit.visionapi.Sae.ModelMetadataOrBuilder> modelMetadataBuilder_;
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ * @return Whether the modelMetadata field is set.
+ */
+ public boolean hasModelMetadata() {
+ return ((bitField0_ & 0x00000008) != 0);
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ * @return The modelMetadata.
+ */
+ public de.starwit.visionapi.Sae.ModelMetadata getModelMetadata() {
+ if (modelMetadataBuilder_ == null) {
+ return modelMetadata_ == null ? de.starwit.visionapi.Sae.ModelMetadata.getDefaultInstance() : modelMetadata_;
+ } else {
+ return modelMetadataBuilder_.getMessage();
+ }
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ */
+ public Builder setModelMetadata(de.starwit.visionapi.Sae.ModelMetadata value) {
+ if (modelMetadataBuilder_ == null) {
+ if (value == null) {
+ throw new NullPointerException();
+ }
+ modelMetadata_ = value;
+ } else {
+ modelMetadataBuilder_.setMessage(value);
+ }
+ bitField0_ |= 0x00000008;
+ onChanged();
+ return this;
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ */
+ public Builder setModelMetadata(
+ de.starwit.visionapi.Sae.ModelMetadata.Builder builderForValue) {
+ if (modelMetadataBuilder_ == null) {
+ modelMetadata_ = builderForValue.build();
+ } else {
+ modelMetadataBuilder_.setMessage(builderForValue.build());
+ }
+ bitField0_ |= 0x00000008;
+ onChanged();
+ return this;
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ */
+ public Builder mergeModelMetadata(de.starwit.visionapi.Sae.ModelMetadata value) {
+ if (modelMetadataBuilder_ == null) {
+ if (((bitField0_ & 0x00000008) != 0) &&
+ modelMetadata_ != null &&
+ modelMetadata_ != de.starwit.visionapi.Sae.ModelMetadata.getDefaultInstance()) {
+ getModelMetadataBuilder().mergeFrom(value);
+ } else {
+ modelMetadata_ = value;
+ }
+ } else {
+ modelMetadataBuilder_.mergeFrom(value);
+ }
+ if (modelMetadata_ != null) {
+ bitField0_ |= 0x00000008;
+ onChanged();
+ }
+ return this;
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ */
+ public Builder clearModelMetadata() {
+ bitField0_ = (bitField0_ & ~0x00000008);
+ modelMetadata_ = null;
+ if (modelMetadataBuilder_ != null) {
+ modelMetadataBuilder_.dispose();
+ modelMetadataBuilder_ = null;
+ }
+ onChanged();
+ return this;
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ */
+ public de.starwit.visionapi.Sae.ModelMetadata.Builder getModelMetadataBuilder() {
+ bitField0_ |= 0x00000008;
+ onChanged();
+ return internalGetModelMetadataFieldBuilder().getBuilder();
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ */
+ public de.starwit.visionapi.Sae.ModelMetadataOrBuilder getModelMetadataOrBuilder() {
+ if (modelMetadataBuilder_ != null) {
+ return modelMetadataBuilder_.getMessageOrBuilder();
+ } else {
+ return modelMetadata_ == null ?
+ de.starwit.visionapi.Sae.ModelMetadata.getDefaultInstance() : modelMetadata_;
+ }
+ }
+ /**
+ * .visionapi.ModelMetadata model_metadata = 100;
+ */
+ private com.google.protobuf.SingleFieldBuilder<
+ de.starwit.visionapi.Sae.ModelMetadata, de.starwit.visionapi.Sae.ModelMetadata.Builder, de.starwit.visionapi.Sae.ModelMetadataOrBuilder>
+ internalGetModelMetadataFieldBuilder() {
+ if (modelMetadataBuilder_ == null) {
+ modelMetadataBuilder_ = new com.google.protobuf.SingleFieldBuilder<
+ de.starwit.visionapi.Sae.ModelMetadata, de.starwit.visionapi.Sae.ModelMetadata.Builder, de.starwit.visionapi.Sae.ModelMetadataOrBuilder>(
+ getModelMetadata(),
+ getParentForChildren(),
+ isClean());
+ modelMetadata_ = null;
+ }
+ return modelMetadataBuilder_;
+ }
+
private int type_ = 0;
/**
* .visionapi.MessageType type = 1000;
@@ -1191,7 +1391,7 @@ public de.starwit.visionapi.Sae.MetricsOrBuilder getMetricsOrBuilder() {
*/
public Builder setTypeValue(int value) {
type_ = value;
- bitField0_ |= 0x00000008;
+ bitField0_ |= 0x00000010;
onChanged();
return this;
}
@@ -1211,7 +1411,7 @@ public de.starwit.visionapi.Common.MessageType getType() {
*/
public Builder setType(de.starwit.visionapi.Common.MessageType value) {
if (value == null) { throw new NullPointerException(); }
- bitField0_ |= 0x00000008;
+ bitField0_ |= 0x00000010;
type_ = value.getNumber();
onChanged();
return this;
@@ -1221,7 +1421,7 @@ public Builder setType(de.starwit.visionapi.Common.MessageType value) {
* @return This builder for chaining.
*/
public Builder clearType() {
- bitField0_ = (bitField0_ & ~0x00000008);
+ bitField0_ = (bitField0_ & ~0x00000010);
type_ = 0;
onChanged();
return this;
@@ -5146,67 +5346,51 @@ public de.starwit.visionapi.Sae.Metrics getDefaultInstanceForType() {
}
- public interface PositionMessageOrBuilder extends
- // @@protoc_insertion_point(interface_extends:visionapi.PositionMessage)
+ public interface ModelMetadataOrBuilder extends
+ // @@protoc_insertion_point(interface_extends:visionapi.ModelMetadata)
com.google.protobuf.MessageOrBuilder {
/**
- * uint64 timestamp_utc_ms = 1;
- * @return The timestampUtcMs.
- */
- long getTimestampUtcMs();
-
- /**
- * .visionapi.GeoCoordinate geo_coordinate = 2;
- * @return Whether the geoCoordinate field is set.
- */
- boolean hasGeoCoordinate();
- /**
- * .visionapi.GeoCoordinate geo_coordinate = 2;
- * @return The geoCoordinate.
- */
- de.starwit.visionapi.Common.GeoCoordinate getGeoCoordinate();
- /**
- * .visionapi.GeoCoordinate geo_coordinate = 2;
+ * map<uint32, string> class_names = 1;
*/
- de.starwit.visionapi.Common.GeoCoordinateOrBuilder getGeoCoordinateOrBuilder();
-
+ int getClassNamesCount();
/**
- * float hdop = 3;
- * @return The hdop.
+ * map<uint32, string> class_names = 1;
*/
- float getHdop();
-
+ boolean containsClassNames(
+ int key);
/**
- * bool fix = 4;
- * @return The fix.
+ * Use {@link #getClassNamesMap()} instead.
*/
- boolean getFix();
-
+ @java.lang.Deprecated
+ java.util.Map
+ getClassNames();
/**
- * bytes sae_uuid = 5;
- * @return The saeUuid.
+ * map<uint32, string> class_names = 1;
*/
- com.google.protobuf.ByteString getSaeUuid();
-
+ java.util.Map
+ getClassNamesMap();
/**
- * .visionapi.MessageType type = 1000;
- * @return The enum numeric value on the wire for type.
+ * map<uint32, string> class_names = 1;
*/
- int getTypeValue();
+ /* nullable */
+java.lang.String getClassNamesOrDefault(
+ int key,
+ /* nullable */
+java.lang.String defaultValue);
/**
- * .visionapi.MessageType type = 1000;
- * @return The type.
+ * map<uint32, string> class_names = 1;
*/
- de.starwit.visionapi.Common.MessageType getType();
+ java.lang.String getClassNamesOrThrow(
+ int key);
}
/**
- * Protobuf type {@code visionapi.PositionMessage}
+ * Protobuf type {@code visionapi.ModelMetadata}
*/
- public static final class PositionMessage extends
+ public static final class ModelMetadata extends
com.google.protobuf.GeneratedMessage implements
- // @@protoc_insertion_point(message_implements:visionapi.PositionMessage)
- PositionMessageOrBuilder {
+ // @@protoc_insertion_point(message_implements:visionapi.ModelMetadata)
+ ModelMetadataOrBuilder {
private static final long serialVersionUID = 0L;
static {
com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
@@ -5215,117 +5399,117 @@ public static final class PositionMessage extends
/* minor= */ 31,
/* patch= */ 1,
/* suffix= */ "",
- PositionMessage.class.getName());
+ ModelMetadata.class.getName());
}
- // Use PositionMessage.newBuilder() to construct.
- private PositionMessage(com.google.protobuf.GeneratedMessage.Builder> builder) {
+ // Use ModelMetadata.newBuilder() to construct.
+ private ModelMetadata(com.google.protobuf.GeneratedMessage.Builder> builder) {
super(builder);
}
- private PositionMessage() {
- saeUuid_ = com.google.protobuf.ByteString.EMPTY;
- type_ = 0;
+ private ModelMetadata() {
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
- return de.starwit.visionapi.Sae.internal_static_visionapi_PositionMessage_descriptor;
+ return de.starwit.visionapi.Sae.internal_static_visionapi_ModelMetadata_descriptor;
}
+ @SuppressWarnings({"rawtypes"})
+ @java.lang.Override
+ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(
+ int number) {
+ switch (number) {
+ case 1:
+ return internalGetClassNames();
+ default:
+ throw new RuntimeException(
+ "Invalid map field number: " + number);
+ }
+ }
@java.lang.Override
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
- return de.starwit.visionapi.Sae.internal_static_visionapi_PositionMessage_fieldAccessorTable
+ return de.starwit.visionapi.Sae.internal_static_visionapi_ModelMetadata_fieldAccessorTable
.ensureFieldAccessorsInitialized(
- de.starwit.visionapi.Sae.PositionMessage.class, de.starwit.visionapi.Sae.PositionMessage.Builder.class);
+ de.starwit.visionapi.Sae.ModelMetadata.class, de.starwit.visionapi.Sae.ModelMetadata.Builder.class);
}
- private int bitField0_;
- public static final int TIMESTAMP_UTC_MS_FIELD_NUMBER = 1;
- private long timestampUtcMs_ = 0L;
- /**
- * uint64 timestamp_utc_ms = 1;
- * @return The timestampUtcMs.
- */
- @java.lang.Override
- public long getTimestampUtcMs() {
- return timestampUtcMs_;
+ public static final int CLASS_NAMES_FIELD_NUMBER = 1;
+ private static final class ClassNamesDefaultEntryHolder {
+ static final com.google.protobuf.MapEntry<
+ java.lang.Integer, java.lang.String> defaultEntry =
+ com.google.protobuf.MapEntry
+ .newDefaultInstance(
+ de.starwit.visionapi.Sae.internal_static_visionapi_ModelMetadata_ClassNamesEntry_descriptor,
+ com.google.protobuf.WireFormat.FieldType.UINT32,
+ 0,
+ com.google.protobuf.WireFormat.FieldType.STRING,
+ "");
}
-
- public static final int GEO_COORDINATE_FIELD_NUMBER = 2;
- private de.starwit.visionapi.Common.GeoCoordinate geoCoordinate_;
- /**
- * .visionapi.GeoCoordinate geo_coordinate = 2;
- * @return Whether the geoCoordinate field is set.
- */
- @java.lang.Override
- public boolean hasGeoCoordinate() {
- return ((bitField0_ & 0x00000001) != 0);
+ @SuppressWarnings("serial")
+ private com.google.protobuf.MapField<
+ java.lang.Integer, java.lang.String> classNames_;
+ private com.google.protobuf.MapField
+ internalGetClassNames() {
+ if (classNames_ == null) {
+ return com.google.protobuf.MapField.emptyMapField(
+ ClassNamesDefaultEntryHolder.defaultEntry);
+ }
+ return classNames_;
}
- /**
- * .visionapi.GeoCoordinate geo_coordinate = 2;
- * @return The geoCoordinate.
- */
- @java.lang.Override
- public de.starwit.visionapi.Common.GeoCoordinate getGeoCoordinate() {
- return geoCoordinate_ == null ? de.starwit.visionapi.Common.GeoCoordinate.getDefaultInstance() : geoCoordinate_;
+ public int getClassNamesCount() {
+ return internalGetClassNames().getMap().size();
}
/**
- * .visionapi.GeoCoordinate geo_coordinate = 2;
+ * map<uint32, string> class_names = 1;
*/
@java.lang.Override
- public de.starwit.visionapi.Common.GeoCoordinateOrBuilder getGeoCoordinateOrBuilder() {
- return geoCoordinate_ == null ? de.starwit.visionapi.Common.GeoCoordinate.getDefaultInstance() : geoCoordinate_;
- }
+ public boolean containsClassNames(
+ int key) {
- public static final int HDOP_FIELD_NUMBER = 3;
- private float hdop_ = 0F;
+ return internalGetClassNames().getMap().containsKey(key);
+ }
/**
- * float hdop = 3;
- * @return The hdop.
+ * Use {@link #getClassNamesMap()} instead.
*/
@java.lang.Override
- public float getHdop() {
- return hdop_;
+ @java.lang.Deprecated
+ public java.util.Map getClassNames() {
+ return getClassNamesMap();
}
-
- public static final int FIX_FIELD_NUMBER = 4;
- private boolean fix_ = false;
/**
- * bool fix = 4;
- * @return The fix.
+ * map<uint32, string> class_names = 1;
*/
@java.lang.Override
- public boolean getFix() {
- return fix_;
+ public java.util.Map getClassNamesMap() {
+ return internalGetClassNames().getMap();
}
-
- public static final int SAE_UUID_FIELD_NUMBER = 5;
- private com.google.protobuf.ByteString saeUuid_ = com.google.protobuf.ByteString.EMPTY;
/**
- * bytes sae_uuid = 5;
- * @return The saeUuid.
+ * map<uint32, string> class_names = 1;
*/
@java.lang.Override
- public com.google.protobuf.ByteString getSaeUuid() {
- return saeUuid_;
- }
+ public /* nullable */
+java.lang.String getClassNamesOrDefault(
+ int key,
+ /* nullable */
+java.lang.String defaultValue) {
- public static final int TYPE_FIELD_NUMBER = 1000;
- private int type_ = 0;
- /**
- * .visionapi.MessageType type = 1000;
- * @return The enum numeric value on the wire for type.
- */
- @java.lang.Override public int getTypeValue() {
- return type_;
+ java.util.Map map =
+ internalGetClassNames().getMap();
+ return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
- * .visionapi.MessageType type = 1000;
- * @return The type.
+ * map<uint32, string> class_names = 1;
*/
- @java.lang.Override public de.starwit.visionapi.Common.MessageType getType() {
- de.starwit.visionapi.Common.MessageType result = de.starwit.visionapi.Common.MessageType.forNumber(type_);
- return result == null ? de.starwit.visionapi.Common.MessageType.UNRECOGNIZED : result;
+ @java.lang.Override
+ public java.lang.String getClassNamesOrThrow(
+ int key) {
+
+ java.util.Map map =
+ internalGetClassNames().getMap();
+ if (!map.containsKey(key)) {
+ throw new java.lang.IllegalArgumentException();
+ }
+ return map.get(key);
}
private byte memoizedIsInitialized = -1;
@@ -5342,24 +5526,12 @@ public final boolean isInitialized() {
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
- if (timestampUtcMs_ != 0L) {
- output.writeUInt64(1, timestampUtcMs_);
- }
- if (((bitField0_ & 0x00000001) != 0)) {
- output.writeMessage(2, getGeoCoordinate());
- }
- if (java.lang.Float.floatToRawIntBits(hdop_) != 0) {
- output.writeFloat(3, hdop_);
- }
- if (fix_ != false) {
- output.writeBool(4, fix_);
- }
- if (!saeUuid_.isEmpty()) {
- output.writeBytes(5, saeUuid_);
- }
- if (type_ != de.starwit.visionapi.Common.MessageType.UNSPECIFIED.getNumber()) {
- output.writeEnum(1000, type_);
- }
+ com.google.protobuf.GeneratedMessage
+ .serializeIntegerMapTo(
+ output,
+ internalGetClassNames(),
+ ClassNamesDefaultEntryHolder.defaultEntry,
+ 1);
getUnknownFields().writeTo(output);
}
@@ -5369,16 +5541,719 @@ public int getSerializedSize() {
if (size != -1) return size;
size = 0;
- if (timestampUtcMs_ != 0L) {
- size += com.google.protobuf.CodedOutputStream
- .computeUInt64Size(1, timestampUtcMs_);
- }
- if (((bitField0_ & 0x00000001) != 0)) {
+ for (java.util.Map.Entry entry
+ : internalGetClassNames().getMap().entrySet()) {
+ com.google.protobuf.MapEntry
+ classNames__ = ClassNamesDefaultEntryHolder.defaultEntry.newBuilderForType()
+ .setKey(entry.getKey())
+ .setValue(entry.getValue())
+ .build();
size += com.google.protobuf.CodedOutputStream
- .computeMessageSize(2, getGeoCoordinate());
+ .computeMessageSize(1, classNames__);
}
- if (java.lang.Float.floatToRawIntBits(hdop_) != 0) {
- size += com.google.protobuf.CodedOutputStream
+ size += getUnknownFields().getSerializedSize();
+ memoizedSize = size;
+ return size;
+ }
+
+ @java.lang.Override
+ public boolean equals(final java.lang.Object obj) {
+ if (obj == this) {
+ return true;
+ }
+ if (!(obj instanceof de.starwit.visionapi.Sae.ModelMetadata)) {
+ return super.equals(obj);
+ }
+ de.starwit.visionapi.Sae.ModelMetadata other = (de.starwit.visionapi.Sae.ModelMetadata) obj;
+
+ if (!internalGetClassNames().equals(
+ other.internalGetClassNames())) return false;
+ if (!getUnknownFields().equals(other.getUnknownFields())) return false;
+ return true;
+ }
+
+ @java.lang.Override
+ public int hashCode() {
+ if (memoizedHashCode != 0) {
+ return memoizedHashCode;
+ }
+ int hash = 41;
+ hash = (19 * hash) + getDescriptor().hashCode();
+ if (!internalGetClassNames().getMap().isEmpty()) {
+ hash = (37 * hash) + CLASS_NAMES_FIELD_NUMBER;
+ hash = (53 * hash) + internalGetClassNames().hashCode();
+ }
+ hash = (29 * hash) + getUnknownFields().hashCode();
+ memoizedHashCode = hash;
+ return hash;
+ }
+
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(
+ java.nio.ByteBuffer data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(
+ java.nio.ByteBuffer data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(
+ com.google.protobuf.ByteString data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(
+ com.google.protobuf.ByteString data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(byte[] data)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data);
+ }
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(
+ byte[] data,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ return PARSER.parseFrom(data, extensionRegistry);
+ }
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessage
+ .parseWithIOException(PARSER, input);
+ }
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(
+ java.io.InputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessage
+ .parseWithIOException(PARSER, input, extensionRegistry);
+ }
+
+ public static de.starwit.visionapi.Sae.ModelMetadata parseDelimitedFrom(java.io.InputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessage
+ .parseDelimitedWithIOException(PARSER, input);
+ }
+
+ public static de.starwit.visionapi.Sae.ModelMetadata parseDelimitedFrom(
+ java.io.InputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessage
+ .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
+ }
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(
+ com.google.protobuf.CodedInputStream input)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessage
+ .parseWithIOException(PARSER, input);
+ }
+ public static de.starwit.visionapi.Sae.ModelMetadata parseFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ return com.google.protobuf.GeneratedMessage
+ .parseWithIOException(PARSER, input, extensionRegistry);
+ }
+
+ @java.lang.Override
+ public Builder newBuilderForType() { return newBuilder(); }
+ public static Builder newBuilder() {
+ return DEFAULT_INSTANCE.toBuilder();
+ }
+ public static Builder newBuilder(de.starwit.visionapi.Sae.ModelMetadata prototype) {
+ return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
+ }
+ @java.lang.Override
+ public Builder toBuilder() {
+ return this == DEFAULT_INSTANCE
+ ? new Builder() : new Builder().mergeFrom(this);
+ }
+
+ @java.lang.Override
+ protected Builder newBuilderForType(
+ com.google.protobuf.GeneratedMessage.BuilderParent parent) {
+ Builder builder = new Builder(parent);
+ return builder;
+ }
+ /**
+ * Protobuf type {@code visionapi.ModelMetadata}
+ */
+ public static final class Builder extends
+ com.google.protobuf.GeneratedMessage.Builder implements
+ // @@protoc_insertion_point(builder_implements:visionapi.ModelMetadata)
+ de.starwit.visionapi.Sae.ModelMetadataOrBuilder {
+ public static final com.google.protobuf.Descriptors.Descriptor
+ getDescriptor() {
+ return de.starwit.visionapi.Sae.internal_static_visionapi_ModelMetadata_descriptor;
+ }
+
+ @SuppressWarnings({"rawtypes"})
+ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(
+ int number) {
+ switch (number) {
+ case 1:
+ return internalGetClassNames();
+ default:
+ throw new RuntimeException(
+ "Invalid map field number: " + number);
+ }
+ }
+ @SuppressWarnings({"rawtypes"})
+ protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection(
+ int number) {
+ switch (number) {
+ case 1:
+ return internalGetMutableClassNames();
+ default:
+ throw new RuntimeException(
+ "Invalid map field number: " + number);
+ }
+ }
+ @java.lang.Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ internalGetFieldAccessorTable() {
+ return de.starwit.visionapi.Sae.internal_static_visionapi_ModelMetadata_fieldAccessorTable
+ .ensureFieldAccessorsInitialized(
+ de.starwit.visionapi.Sae.ModelMetadata.class, de.starwit.visionapi.Sae.ModelMetadata.Builder.class);
+ }
+
+ // Construct using de.starwit.visionapi.Sae.ModelMetadata.newBuilder()
+ private Builder() {
+
+ }
+
+ private Builder(
+ com.google.protobuf.GeneratedMessage.BuilderParent parent) {
+ super(parent);
+
+ }
+ @java.lang.Override
+ public Builder clear() {
+ super.clear();
+ bitField0_ = 0;
+ internalGetMutableClassNames().clear();
+ return this;
+ }
+
+ @java.lang.Override
+ public com.google.protobuf.Descriptors.Descriptor
+ getDescriptorForType() {
+ return de.starwit.visionapi.Sae.internal_static_visionapi_ModelMetadata_descriptor;
+ }
+
+ @java.lang.Override
+ public de.starwit.visionapi.Sae.ModelMetadata getDefaultInstanceForType() {
+ return de.starwit.visionapi.Sae.ModelMetadata.getDefaultInstance();
+ }
+
+ @java.lang.Override
+ public de.starwit.visionapi.Sae.ModelMetadata build() {
+ de.starwit.visionapi.Sae.ModelMetadata result = buildPartial();
+ if (!result.isInitialized()) {
+ throw newUninitializedMessageException(result);
+ }
+ return result;
+ }
+
+ @java.lang.Override
+ public de.starwit.visionapi.Sae.ModelMetadata buildPartial() {
+ de.starwit.visionapi.Sae.ModelMetadata result = new de.starwit.visionapi.Sae.ModelMetadata(this);
+ if (bitField0_ != 0) { buildPartial0(result); }
+ onBuilt();
+ return result;
+ }
+
+ private void buildPartial0(de.starwit.visionapi.Sae.ModelMetadata result) {
+ int from_bitField0_ = bitField0_;
+ if (((from_bitField0_ & 0x00000001) != 0)) {
+ result.classNames_ = internalGetClassNames();
+ result.classNames_.makeImmutable();
+ }
+ }
+
+ @java.lang.Override
+ public Builder mergeFrom(com.google.protobuf.Message other) {
+ if (other instanceof de.starwit.visionapi.Sae.ModelMetadata) {
+ return mergeFrom((de.starwit.visionapi.Sae.ModelMetadata)other);
+ } else {
+ super.mergeFrom(other);
+ return this;
+ }
+ }
+
+ public Builder mergeFrom(de.starwit.visionapi.Sae.ModelMetadata other) {
+ if (other == de.starwit.visionapi.Sae.ModelMetadata.getDefaultInstance()) return this;
+ internalGetMutableClassNames().mergeFrom(
+ other.internalGetClassNames());
+ bitField0_ |= 0x00000001;
+ this.mergeUnknownFields(other.getUnknownFields());
+ onChanged();
+ return this;
+ }
+
+ @java.lang.Override
+ public final boolean isInitialized() {
+ return true;
+ }
+
+ @java.lang.Override
+ public Builder mergeFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws java.io.IOException {
+ if (extensionRegistry == null) {
+ throw new java.lang.NullPointerException();
+ }
+ try {
+ boolean done = false;
+ while (!done) {
+ int tag = input.readTag();
+ switch (tag) {
+ case 0:
+ done = true;
+ break;
+ case 10: {
+ com.google.protobuf.MapEntry
+ classNames__ = input.readMessage(
+ ClassNamesDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
+ internalGetMutableClassNames().getMutableMap().put(
+ classNames__.getKey(), classNames__.getValue());
+ bitField0_ |= 0x00000001;
+ break;
+ } // case 10
+ default: {
+ if (!super.parseUnknownField(input, extensionRegistry, tag)) {
+ done = true; // was an endgroup tag
+ }
+ break;
+ } // default:
+ } // switch (tag)
+ } // while (!done)
+ } catch (com.google.protobuf.InvalidProtocolBufferException e) {
+ throw e.unwrapIOException();
+ } finally {
+ onChanged();
+ } // finally
+ return this;
+ }
+ private int bitField0_;
+
+ private com.google.protobuf.MapField<
+ java.lang.Integer, java.lang.String> classNames_;
+ private com.google.protobuf.MapField
+ internalGetClassNames() {
+ if (classNames_ == null) {
+ return com.google.protobuf.MapField.emptyMapField(
+ ClassNamesDefaultEntryHolder.defaultEntry);
+ }
+ return classNames_;
+ }
+ private com.google.protobuf.MapField
+ internalGetMutableClassNames() {
+ if (classNames_ == null) {
+ classNames_ = com.google.protobuf.MapField.newMapField(
+ ClassNamesDefaultEntryHolder.defaultEntry);
+ }
+ if (!classNames_.isMutable()) {
+ classNames_ = classNames_.copy();
+ }
+ bitField0_ |= 0x00000001;
+ onChanged();
+ return classNames_;
+ }
+ public int getClassNamesCount() {
+ return internalGetClassNames().getMap().size();
+ }
+ /**
+ * map<uint32, string> class_names = 1;
+ */
+ @java.lang.Override
+ public boolean containsClassNames(
+ int key) {
+
+ return internalGetClassNames().getMap().containsKey(key);
+ }
+ /**
+ * Use {@link #getClassNamesMap()} instead.
+ */
+ @java.lang.Override
+ @java.lang.Deprecated
+ public java.util.Map getClassNames() {
+ return getClassNamesMap();
+ }
+ /**
+ * map<uint32, string> class_names = 1;
+ */
+ @java.lang.Override
+ public java.util.Map getClassNamesMap() {
+ return internalGetClassNames().getMap();
+ }
+ /**
+ * map<uint32, string> class_names = 1;
+ */
+ @java.lang.Override
+ public /* nullable */
+java.lang.String getClassNamesOrDefault(
+ int key,
+ /* nullable */
+java.lang.String defaultValue) {
+
+ java.util.Map map =
+ internalGetClassNames().getMap();
+ return map.containsKey(key) ? map.get(key) : defaultValue;
+ }
+ /**
+ * map<uint32, string> class_names = 1;
+ */
+ @java.lang.Override
+ public java.lang.String getClassNamesOrThrow(
+ int key) {
+
+ java.util.Map map =
+ internalGetClassNames().getMap();
+ if (!map.containsKey(key)) {
+ throw new java.lang.IllegalArgumentException();
+ }
+ return map.get(key);
+ }
+ public Builder clearClassNames() {
+ bitField0_ = (bitField0_ & ~0x00000001);
+ internalGetMutableClassNames().getMutableMap()
+ .clear();
+ return this;
+ }
+ /**
+ * map<uint32, string> class_names = 1;
+ */
+ public Builder removeClassNames(
+ int key) {
+
+ internalGetMutableClassNames().getMutableMap()
+ .remove(key);
+ return this;
+ }
+ /**
+ * Use alternate mutation accessors instead.
+ */
+ @java.lang.Deprecated
+ public java.util.Map
+ getMutableClassNames() {
+ bitField0_ |= 0x00000001;
+ return internalGetMutableClassNames().getMutableMap();
+ }
+ /**
+ * map<uint32, string> class_names = 1;
+ */
+ public Builder putClassNames(
+ int key,
+ java.lang.String value) {
+
+ if (value == null) { throw new NullPointerException("map value"); }
+ internalGetMutableClassNames().getMutableMap()
+ .put(key, value);
+ bitField0_ |= 0x00000001;
+ return this;
+ }
+ /**
+ * map<uint32, string> class_names = 1;
+ */
+ public Builder putAllClassNames(
+ java.util.Map values) {
+ internalGetMutableClassNames().getMutableMap()
+ .putAll(values);
+ bitField0_ |= 0x00000001;
+ return this;
+ }
+
+ // @@protoc_insertion_point(builder_scope:visionapi.ModelMetadata)
+ }
+
+ // @@protoc_insertion_point(class_scope:visionapi.ModelMetadata)
+ private static final de.starwit.visionapi.Sae.ModelMetadata DEFAULT_INSTANCE;
+ static {
+ DEFAULT_INSTANCE = new de.starwit.visionapi.Sae.ModelMetadata();
+ }
+
+ public static de.starwit.visionapi.Sae.ModelMetadata getDefaultInstance() {
+ return DEFAULT_INSTANCE;
+ }
+
+ private static final com.google.protobuf.Parser
+ PARSER = new com.google.protobuf.AbstractParser() {
+ @java.lang.Override
+ public ModelMetadata parsePartialFrom(
+ com.google.protobuf.CodedInputStream input,
+ com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+ throws com.google.protobuf.InvalidProtocolBufferException {
+ Builder builder = newBuilder();
+ try {
+ builder.mergeFrom(input, extensionRegistry);
+ } catch (com.google.protobuf.InvalidProtocolBufferException e) {
+ throw e.setUnfinishedMessage(builder.buildPartial());
+ } catch (com.google.protobuf.UninitializedMessageException e) {
+ throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
+ } catch (java.io.IOException e) {
+ throw new com.google.protobuf.InvalidProtocolBufferException(e)
+ .setUnfinishedMessage(builder.buildPartial());
+ }
+ return builder.buildPartial();
+ }
+ };
+
+ public static com.google.protobuf.Parser parser() {
+ return PARSER;
+ }
+
+ @java.lang.Override
+ public com.google.protobuf.Parser getParserForType() {
+ return PARSER;
+ }
+
+ @java.lang.Override
+ public de.starwit.visionapi.Sae.ModelMetadata getDefaultInstanceForType() {
+ return DEFAULT_INSTANCE;
+ }
+
+ }
+
+ public interface PositionMessageOrBuilder extends
+ // @@protoc_insertion_point(interface_extends:visionapi.PositionMessage)
+ com.google.protobuf.MessageOrBuilder {
+
+ /**
+ * uint64 timestamp_utc_ms = 1;
+ * @return The timestampUtcMs.
+ */
+ long getTimestampUtcMs();
+
+ /**
+ * .visionapi.GeoCoordinate geo_coordinate = 2;
+ * @return Whether the geoCoordinate field is set.
+ */
+ boolean hasGeoCoordinate();
+ /**
+ * .visionapi.GeoCoordinate geo_coordinate = 2;
+ * @return The geoCoordinate.
+ */
+ de.starwit.visionapi.Common.GeoCoordinate getGeoCoordinate();
+ /**
+ * .visionapi.GeoCoordinate geo_coordinate = 2;
+ */
+ de.starwit.visionapi.Common.GeoCoordinateOrBuilder getGeoCoordinateOrBuilder();
+
+ /**
+ * float hdop = 3;
+ * @return The hdop.
+ */
+ float getHdop();
+
+ /**
+ * bool fix = 4;
+ * @return The fix.
+ */
+ boolean getFix();
+
+ /**
+ * bytes sae_uuid = 5;
+ * @return The saeUuid.
+ */
+ com.google.protobuf.ByteString getSaeUuid();
+
+ /**
+ * .visionapi.MessageType type = 1000;
+ * @return The enum numeric value on the wire for type.
+ */
+ int getTypeValue();
+ /**
+ * .visionapi.MessageType type = 1000;
+ * @return The type.
+ */
+ de.starwit.visionapi.Common.MessageType getType();
+ }
+ /**
+ * Protobuf type {@code visionapi.PositionMessage}
+ */
+ public static final class PositionMessage extends
+ com.google.protobuf.GeneratedMessage implements
+ // @@protoc_insertion_point(message_implements:visionapi.PositionMessage)
+ PositionMessageOrBuilder {
+ private static final long serialVersionUID = 0L;
+ static {
+ com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
+ com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
+ /* major= */ 4,
+ /* minor= */ 31,
+ /* patch= */ 1,
+ /* suffix= */ "",
+ PositionMessage.class.getName());
+ }
+ // Use PositionMessage.newBuilder() to construct.
+ private PositionMessage(com.google.protobuf.GeneratedMessage.Builder> builder) {
+ super(builder);
+ }
+ private PositionMessage() {
+ saeUuid_ = com.google.protobuf.ByteString.EMPTY;
+ type_ = 0;
+ }
+
+ public static final com.google.protobuf.Descriptors.Descriptor
+ getDescriptor() {
+ return de.starwit.visionapi.Sae.internal_static_visionapi_PositionMessage_descriptor;
+ }
+
+ @java.lang.Override
+ protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ internalGetFieldAccessorTable() {
+ return de.starwit.visionapi.Sae.internal_static_visionapi_PositionMessage_fieldAccessorTable
+ .ensureFieldAccessorsInitialized(
+ de.starwit.visionapi.Sae.PositionMessage.class, de.starwit.visionapi.Sae.PositionMessage.Builder.class);
+ }
+
+ private int bitField0_;
+ public static final int TIMESTAMP_UTC_MS_FIELD_NUMBER = 1;
+ private long timestampUtcMs_ = 0L;
+ /**
+ * uint64 timestamp_utc_ms = 1;
+ * @return The timestampUtcMs.
+ */
+ @java.lang.Override
+ public long getTimestampUtcMs() {
+ return timestampUtcMs_;
+ }
+
+ public static final int GEO_COORDINATE_FIELD_NUMBER = 2;
+ private de.starwit.visionapi.Common.GeoCoordinate geoCoordinate_;
+ /**
+ * .visionapi.GeoCoordinate geo_coordinate = 2;
+ * @return Whether the geoCoordinate field is set.
+ */
+ @java.lang.Override
+ public boolean hasGeoCoordinate() {
+ return ((bitField0_ & 0x00000001) != 0);
+ }
+ /**
+ * .visionapi.GeoCoordinate geo_coordinate = 2;
+ * @return The geoCoordinate.
+ */
+ @java.lang.Override
+ public de.starwit.visionapi.Common.GeoCoordinate getGeoCoordinate() {
+ return geoCoordinate_ == null ? de.starwit.visionapi.Common.GeoCoordinate.getDefaultInstance() : geoCoordinate_;
+ }
+ /**
+ * .visionapi.GeoCoordinate geo_coordinate = 2;
+ */
+ @java.lang.Override
+ public de.starwit.visionapi.Common.GeoCoordinateOrBuilder getGeoCoordinateOrBuilder() {
+ return geoCoordinate_ == null ? de.starwit.visionapi.Common.GeoCoordinate.getDefaultInstance() : geoCoordinate_;
+ }
+
+ public static final int HDOP_FIELD_NUMBER = 3;
+ private float hdop_ = 0F;
+ /**
+ * float hdop = 3;
+ * @return The hdop.
+ */
+ @java.lang.Override
+ public float getHdop() {
+ return hdop_;
+ }
+
+ public static final int FIX_FIELD_NUMBER = 4;
+ private boolean fix_ = false;
+ /**
+ * bool fix = 4;
+ * @return The fix.
+ */
+ @java.lang.Override
+ public boolean getFix() {
+ return fix_;
+ }
+
+ public static final int SAE_UUID_FIELD_NUMBER = 5;
+ private com.google.protobuf.ByteString saeUuid_ = com.google.protobuf.ByteString.EMPTY;
+ /**
+ * bytes sae_uuid = 5;
+ * @return The saeUuid.
+ */
+ @java.lang.Override
+ public com.google.protobuf.ByteString getSaeUuid() {
+ return saeUuid_;
+ }
+
+ public static final int TYPE_FIELD_NUMBER = 1000;
+ private int type_ = 0;
+ /**
+ * .visionapi.MessageType type = 1000;
+ * @return The enum numeric value on the wire for type.
+ */
+ @java.lang.Override public int getTypeValue() {
+ return type_;
+ }
+ /**
+ * .visionapi.MessageType type = 1000;
+ * @return The type.
+ */
+ @java.lang.Override public de.starwit.visionapi.Common.MessageType getType() {
+ de.starwit.visionapi.Common.MessageType result = de.starwit.visionapi.Common.MessageType.forNumber(type_);
+ return result == null ? de.starwit.visionapi.Common.MessageType.UNRECOGNIZED : result;
+ }
+
+ private byte memoizedIsInitialized = -1;
+ @java.lang.Override
+ public final boolean isInitialized() {
+ byte isInitialized = memoizedIsInitialized;
+ if (isInitialized == 1) return true;
+ if (isInitialized == 0) return false;
+
+ memoizedIsInitialized = 1;
+ return true;
+ }
+
+ @java.lang.Override
+ public void writeTo(com.google.protobuf.CodedOutputStream output)
+ throws java.io.IOException {
+ if (timestampUtcMs_ != 0L) {
+ output.writeUInt64(1, timestampUtcMs_);
+ }
+ if (((bitField0_ & 0x00000001) != 0)) {
+ output.writeMessage(2, getGeoCoordinate());
+ }
+ if (java.lang.Float.floatToRawIntBits(hdop_) != 0) {
+ output.writeFloat(3, hdop_);
+ }
+ if (fix_ != false) {
+ output.writeBool(4, fix_);
+ }
+ if (!saeUuid_.isEmpty()) {
+ output.writeBytes(5, saeUuid_);
+ }
+ if (type_ != de.starwit.visionapi.Common.MessageType.UNSPECIFIED.getNumber()) {
+ output.writeEnum(1000, type_);
+ }
+ getUnknownFields().writeTo(output);
+ }
+
+ @java.lang.Override
+ public int getSerializedSize() {
+ int size = memoizedSize;
+ if (size != -1) return size;
+
+ size = 0;
+ if (timestampUtcMs_ != 0L) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeUInt64Size(1, timestampUtcMs_);
+ }
+ if (((bitField0_ & 0x00000001) != 0)) {
+ size += com.google.protobuf.CodedOutputStream
+ .computeMessageSize(2, getGeoCoordinate());
+ }
+ if (java.lang.Float.floatToRawIntBits(hdop_) != 0) {
+ size += com.google.protobuf.CodedOutputStream
.computeFloatSize(3, hdop_);
}
if (fix_ != false) {
@@ -6142,6 +7017,16 @@ public de.starwit.visionapi.Sae.PositionMessage getDefaultInstanceForType() {
private static final
com.google.protobuf.GeneratedMessage.FieldAccessorTable
internal_static_visionapi_Metrics_fieldAccessorTable;
+ private static final com.google.protobuf.Descriptors.Descriptor
+ internal_static_visionapi_ModelMetadata_descriptor;
+ private static final
+ com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ internal_static_visionapi_ModelMetadata_fieldAccessorTable;
+ private static final com.google.protobuf.Descriptors.Descriptor
+ internal_static_visionapi_ModelMetadata_ClassNamesEntry_descriptor;
+ private static final
+ com.google.protobuf.GeneratedMessage.FieldAccessorTable
+ internal_static_visionapi_ModelMetadata_ClassNamesEntry_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_visionapi_PositionMessage_descriptor;
private static final
@@ -6157,31 +7042,35 @@ public de.starwit.visionapi.Sae.PositionMessage getDefaultInstanceForType() {
static {
java.lang.String[] descriptorData = {
"\n\023visionapi/sae.proto\022\tvisionapi\032\026vision" +
- "api/common.proto\"\250\001\n\nSaeMessage\022$\n\005frame" +
+ "api/common.proto\"\332\001\n\nSaeMessage\022$\n\005frame" +
"\030\001 \001(\0132\025.visionapi.VideoFrame\022(\n\ndetecti" +
"ons\030\002 \003(\0132\024.visionapi.Detection\022#\n\007metri" +
- "cs\030c \001(\0132\022.visionapi.Metrics\022%\n\004type\030\350\007 " +
- "\001(\0162\026.visionapi.MessageType\"\272\001\n\nVideoFra" +
- "me\022\021\n\tsource_id\030\001 \001(\t\022\030\n\020timestamp_utc_m" +
- "s\030\002 \001(\004\022\037\n\005shape\030\003 \001(\0132\020.visionapi.Shape" +
- "\022\022\n\nframe_data\030\004 \001(\014\022\027\n\017frame_data_jpeg\030" +
- "\005 \001(\014\0221\n\017camera_location\030\006 \001(\0132\030.visiona" +
- "pi.GeoCoordinate\"8\n\005Shape\022\016\n\006height\030\001 \001(" +
- "\r\022\r\n\005width\030\002 \001(\r\022\020\n\010channels\030\003 \001(\r\"\244\001\n\tD" +
- "etection\022,\n\014bounding_box\030\001 \001(\0132\026.visiona" +
- "pi.BoundingBox\022\022\n\nconfidence\030\002 \001(\002\022\020\n\010cl" +
- "ass_id\030\003 \001(\r\022\021\n\tobject_id\030\004 \001(\014\0220\n\016geo_c" +
- "oordinate\030\005 \001(\0132\030.visionapi.GeoCoordinat" +
- "e\"I\n\013BoundingBox\022\r\n\005min_x\030\001 \001(\002\022\r\n\005min_y" +
- "\030\002 \001(\002\022\r\n\005max_x\030\003 \001(\002\022\r\n\005max_y\030\004 \001(\002\"R\n\007" +
- "Metrics\022#\n\033detection_inference_time_us\030\001" +
- " \001(\r\022\"\n\032tracking_inference_time_us\030\002 \001(\r" +
- "\"\261\001\n\017PositionMessage\022\030\n\020timestamp_utc_ms" +
- "\030\001 \001(\004\0220\n\016geo_coordinate\030\002 \001(\0132\030.visiona" +
- "pi.GeoCoordinate\022\014\n\004hdop\030\003 \001(\002\022\013\n\003fix\030\004 " +
- "\001(\010\022\020\n\010sae_uuid\030\005 \001(\014\022%\n\004type\030\350\007 \001(\0162\026.v" +
- "isionapi.MessageTypeB\026\n\024de.starwit.visio" +
- "napib\006proto3"
+ "cs\030c \001(\0132\022.visionapi.Metrics\0220\n\016model_me" +
+ "tadata\030d \001(\0132\030.visionapi.ModelMetadata\022%" +
+ "\n\004type\030\350\007 \001(\0162\026.visionapi.MessageType\"\272\001" +
+ "\n\nVideoFrame\022\021\n\tsource_id\030\001 \001(\t\022\030\n\020times" +
+ "tamp_utc_ms\030\002 \001(\004\022\037\n\005shape\030\003 \001(\0132\020.visio" +
+ "napi.Shape\022\022\n\nframe_data\030\004 \001(\014\022\027\n\017frame_" +
+ "data_jpeg\030\005 \001(\014\0221\n\017camera_location\030\006 \001(\013" +
+ "2\030.visionapi.GeoCoordinate\"8\n\005Shape\022\016\n\006h" +
+ "eight\030\001 \001(\r\022\r\n\005width\030\002 \001(\r\022\020\n\010channels\030\003" +
+ " \001(\r\"\244\001\n\tDetection\022,\n\014bounding_box\030\001 \001(\013" +
+ "2\026.visionapi.BoundingBox\022\022\n\nconfidence\030\002" +
+ " \001(\002\022\020\n\010class_id\030\003 \001(\r\022\021\n\tobject_id\030\004 \001(" +
+ "\014\0220\n\016geo_coordinate\030\005 \001(\0132\030.visionapi.Ge" +
+ "oCoordinate\"I\n\013BoundingBox\022\r\n\005min_x\030\001 \001(" +
+ "\002\022\r\n\005min_y\030\002 \001(\002\022\r\n\005max_x\030\003 \001(\002\022\r\n\005max_y" +
+ "\030\004 \001(\002\"R\n\007Metrics\022#\n\033detection_inference" +
+ "_time_us\030\001 \001(\r\022\"\n\032tracking_inference_tim" +
+ "e_us\030\002 \001(\r\"\201\001\n\rModelMetadata\022=\n\013class_na" +
+ "mes\030\001 \003(\0132(.visionapi.ModelMetadata.Clas" +
+ "sNamesEntry\0321\n\017ClassNamesEntry\022\013\n\003key\030\001 " +
+ "\001(\r\022\r\n\005value\030\002 \001(\t:\0028\001\"\261\001\n\017PositionMessa" +
+ "ge\022\030\n\020timestamp_utc_ms\030\001 \001(\004\0220\n\016geo_coor" +
+ "dinate\030\002 \001(\0132\030.visionapi.GeoCoordinate\022\014" +
+ "\n\004hdop\030\003 \001(\002\022\013\n\003fix\030\004 \001(\010\022\020\n\010sae_uuid\030\005 " +
+ "\001(\014\022%\n\004type\030\350\007 \001(\0162\026.visionapi.MessageTy" +
+ "peB\026\n\024de.starwit.visionapib\006proto3"
};
descriptor = com.google.protobuf.Descriptors.FileDescriptor
.internalBuildGeneratedFileFrom(descriptorData,
@@ -6193,7 +7082,7 @@ public de.starwit.visionapi.Sae.PositionMessage getDefaultInstanceForType() {
internal_static_visionapi_SaeMessage_fieldAccessorTable = new
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_visionapi_SaeMessage_descriptor,
- new java.lang.String[] { "Frame", "Detections", "Metrics", "Type", });
+ new java.lang.String[] { "Frame", "Detections", "Metrics", "ModelMetadata", "Type", });
internal_static_visionapi_VideoFrame_descriptor =
getDescriptor().getMessageTypes().get(1);
internal_static_visionapi_VideoFrame_fieldAccessorTable = new
@@ -6224,8 +7113,20 @@ public de.starwit.visionapi.Sae.PositionMessage getDefaultInstanceForType() {
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_visionapi_Metrics_descriptor,
new java.lang.String[] { "DetectionInferenceTimeUs", "TrackingInferenceTimeUs", });
- internal_static_visionapi_PositionMessage_descriptor =
+ internal_static_visionapi_ModelMetadata_descriptor =
getDescriptor().getMessageTypes().get(6);
+ internal_static_visionapi_ModelMetadata_fieldAccessorTable = new
+ com.google.protobuf.GeneratedMessage.FieldAccessorTable(
+ internal_static_visionapi_ModelMetadata_descriptor,
+ new java.lang.String[] { "ClassNames", });
+ internal_static_visionapi_ModelMetadata_ClassNamesEntry_descriptor =
+ internal_static_visionapi_ModelMetadata_descriptor.getNestedTypes().get(0);
+ internal_static_visionapi_ModelMetadata_ClassNamesEntry_fieldAccessorTable = new
+ com.google.protobuf.GeneratedMessage.FieldAccessorTable(
+ internal_static_visionapi_ModelMetadata_ClassNamesEntry_descriptor,
+ new java.lang.String[] { "Key", "Value", });
+ internal_static_visionapi_PositionMessage_descriptor =
+ getDescriptor().getMessageTypes().get(7);
internal_static_visionapi_PositionMessage_fieldAccessorTable = new
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
internal_static_visionapi_PositionMessage_descriptor,
diff --git a/python/visionapi/pyproject.toml b/python/visionapi/pyproject.toml
index e60af3b..d8e8123 100644
--- a/python/visionapi/pyproject.toml
+++ b/python/visionapi/pyproject.toml
@@ -1,6 +1,6 @@
[tool.poetry]
name = "visionapi"
-version = "3.4.0"
+version = "3.5.0"
description = ""
authors = ["flonix8 "]
readme = "README.md"
diff --git a/python/visionapi/visionapi/sae_pb2.py b/python/visionapi/visionapi/sae_pb2.py
index 0b3235e..8e2dbf7 100644
--- a/python/visionapi/visionapi/sae_pb2.py
+++ b/python/visionapi/visionapi/sae_pb2.py
@@ -25,7 +25,7 @@
from visionapi import common_pb2 as visionapi_dot_common__pb2
-DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x13visionapi/sae.proto\x12\tvisionapi\x1a\x16visionapi/common.proto\"\xa8\x01\n\nSaeMessage\x12$\n\x05\x66rame\x18\x01 \x01(\x0b\x32\x15.visionapi.VideoFrame\x12(\n\ndetections\x18\x02 \x03(\x0b\x32\x14.visionapi.Detection\x12#\n\x07metrics\x18\x63 \x01(\x0b\x32\x12.visionapi.Metrics\x12%\n\x04type\x18\xe8\x07 \x01(\x0e\x32\x16.visionapi.MessageType\"\xba\x01\n\nVideoFrame\x12\x11\n\tsource_id\x18\x01 \x01(\t\x12\x18\n\x10timestamp_utc_ms\x18\x02 \x01(\x04\x12\x1f\n\x05shape\x18\x03 \x01(\x0b\x32\x10.visionapi.Shape\x12\x12\n\nframe_data\x18\x04 \x01(\x0c\x12\x17\n\x0f\x66rame_data_jpeg\x18\x05 \x01(\x0c\x12\x31\n\x0f\x63\x61mera_location\x18\x06 \x01(\x0b\x32\x18.visionapi.GeoCoordinate\"8\n\x05Shape\x12\x0e\n\x06height\x18\x01 \x01(\r\x12\r\n\x05width\x18\x02 \x01(\r\x12\x10\n\x08\x63hannels\x18\x03 \x01(\r\"\xa4\x01\n\tDetection\x12,\n\x0c\x62ounding_box\x18\x01 \x01(\x0b\x32\x16.visionapi.BoundingBox\x12\x12\n\nconfidence\x18\x02 \x01(\x02\x12\x10\n\x08\x63lass_id\x18\x03 \x01(\r\x12\x11\n\tobject_id\x18\x04 \x01(\x0c\x12\x30\n\x0egeo_coordinate\x18\x05 \x01(\x0b\x32\x18.visionapi.GeoCoordinate\"I\n\x0b\x42oundingBox\x12\r\n\x05min_x\x18\x01 \x01(\x02\x12\r\n\x05min_y\x18\x02 \x01(\x02\x12\r\n\x05max_x\x18\x03 \x01(\x02\x12\r\n\x05max_y\x18\x04 \x01(\x02\"R\n\x07Metrics\x12#\n\x1b\x64\x65tection_inference_time_us\x18\x01 \x01(\r\x12\"\n\x1atracking_inference_time_us\x18\x02 \x01(\r\"\xb1\x01\n\x0fPositionMessage\x12\x18\n\x10timestamp_utc_ms\x18\x01 \x01(\x04\x12\x30\n\x0egeo_coordinate\x18\x02 \x01(\x0b\x32\x18.visionapi.GeoCoordinate\x12\x0c\n\x04hdop\x18\x03 \x01(\x02\x12\x0b\n\x03\x66ix\x18\x04 \x01(\x08\x12\x10\n\x08sae_uuid\x18\x05 \x01(\x0c\x12%\n\x04type\x18\xe8\x07 \x01(\x0e\x32\x16.visionapi.MessageTypeB\x16\n\x14\x64\x65.starwit.visionapib\x06proto3')
+DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x13visionapi/sae.proto\x12\tvisionapi\x1a\x16visionapi/common.proto\"\xda\x01\n\nSaeMessage\x12$\n\x05\x66rame\x18\x01 \x01(\x0b\x32\x15.visionapi.VideoFrame\x12(\n\ndetections\x18\x02 \x03(\x0b\x32\x14.visionapi.Detection\x12#\n\x07metrics\x18\x63 \x01(\x0b\x32\x12.visionapi.Metrics\x12\x30\n\x0emodel_metadata\x18\x64 \x01(\x0b\x32\x18.visionapi.ModelMetadata\x12%\n\x04type\x18\xe8\x07 \x01(\x0e\x32\x16.visionapi.MessageType\"\xba\x01\n\nVideoFrame\x12\x11\n\tsource_id\x18\x01 \x01(\t\x12\x18\n\x10timestamp_utc_ms\x18\x02 \x01(\x04\x12\x1f\n\x05shape\x18\x03 \x01(\x0b\x32\x10.visionapi.Shape\x12\x12\n\nframe_data\x18\x04 \x01(\x0c\x12\x17\n\x0f\x66rame_data_jpeg\x18\x05 \x01(\x0c\x12\x31\n\x0f\x63\x61mera_location\x18\x06 \x01(\x0b\x32\x18.visionapi.GeoCoordinate\"8\n\x05Shape\x12\x0e\n\x06height\x18\x01 \x01(\r\x12\r\n\x05width\x18\x02 \x01(\r\x12\x10\n\x08\x63hannels\x18\x03 \x01(\r\"\xa4\x01\n\tDetection\x12,\n\x0c\x62ounding_box\x18\x01 \x01(\x0b\x32\x16.visionapi.BoundingBox\x12\x12\n\nconfidence\x18\x02 \x01(\x02\x12\x10\n\x08\x63lass_id\x18\x03 \x01(\r\x12\x11\n\tobject_id\x18\x04 \x01(\x0c\x12\x30\n\x0egeo_coordinate\x18\x05 \x01(\x0b\x32\x18.visionapi.GeoCoordinate\"I\n\x0b\x42oundingBox\x12\r\n\x05min_x\x18\x01 \x01(\x02\x12\r\n\x05min_y\x18\x02 \x01(\x02\x12\r\n\x05max_x\x18\x03 \x01(\x02\x12\r\n\x05max_y\x18\x04 \x01(\x02\"R\n\x07Metrics\x12#\n\x1b\x64\x65tection_inference_time_us\x18\x01 \x01(\r\x12\"\n\x1atracking_inference_time_us\x18\x02 \x01(\r\"\x81\x01\n\rModelMetadata\x12=\n\x0b\x63lass_names\x18\x01 \x03(\x0b\x32(.visionapi.ModelMetadata.ClassNamesEntry\x1a\x31\n\x0f\x43lassNamesEntry\x12\x0b\n\x03key\x18\x01 \x01(\r\x12\r\n\x05value\x18\x02 \x01(\t:\x02\x38\x01\"\xb1\x01\n\x0fPositionMessage\x12\x18\n\x10timestamp_utc_ms\x18\x01 \x01(\x04\x12\x30\n\x0egeo_coordinate\x18\x02 \x01(\x0b\x32\x18.visionapi.GeoCoordinate\x12\x0c\n\x04hdop\x18\x03 \x01(\x02\x12\x0b\n\x03\x66ix\x18\x04 \x01(\x08\x12\x10\n\x08sae_uuid\x18\x05 \x01(\x0c\x12%\n\x04type\x18\xe8\x07 \x01(\x0e\x32\x16.visionapi.MessageTypeB\x16\n\x14\x64\x65.starwit.visionapib\x06proto3')
_globals = globals()
_builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, _globals)
@@ -33,18 +33,24 @@
if not _descriptor._USE_C_DESCRIPTORS:
_globals['DESCRIPTOR']._loaded_options = None
_globals['DESCRIPTOR']._serialized_options = b'\n\024de.starwit.visionapi'
+ _globals['_MODELMETADATA_CLASSNAMESENTRY']._loaded_options = None
+ _globals['_MODELMETADATA_CLASSNAMESENTRY']._serialized_options = b'8\001'
_globals['_SAEMESSAGE']._serialized_start=59
- _globals['_SAEMESSAGE']._serialized_end=227
- _globals['_VIDEOFRAME']._serialized_start=230
- _globals['_VIDEOFRAME']._serialized_end=416
- _globals['_SHAPE']._serialized_start=418
- _globals['_SHAPE']._serialized_end=474
- _globals['_DETECTION']._serialized_start=477
- _globals['_DETECTION']._serialized_end=641
- _globals['_BOUNDINGBOX']._serialized_start=643
- _globals['_BOUNDINGBOX']._serialized_end=716
- _globals['_METRICS']._serialized_start=718
- _globals['_METRICS']._serialized_end=800
- _globals['_POSITIONMESSAGE']._serialized_start=803
- _globals['_POSITIONMESSAGE']._serialized_end=980
+ _globals['_SAEMESSAGE']._serialized_end=277
+ _globals['_VIDEOFRAME']._serialized_start=280
+ _globals['_VIDEOFRAME']._serialized_end=466
+ _globals['_SHAPE']._serialized_start=468
+ _globals['_SHAPE']._serialized_end=524
+ _globals['_DETECTION']._serialized_start=527
+ _globals['_DETECTION']._serialized_end=691
+ _globals['_BOUNDINGBOX']._serialized_start=693
+ _globals['_BOUNDINGBOX']._serialized_end=766
+ _globals['_METRICS']._serialized_start=768
+ _globals['_METRICS']._serialized_end=850
+ _globals['_MODELMETADATA']._serialized_start=853
+ _globals['_MODELMETADATA']._serialized_end=982
+ _globals['_MODELMETADATA_CLASSNAMESENTRY']._serialized_start=933
+ _globals['_MODELMETADATA_CLASSNAMESENTRY']._serialized_end=982
+ _globals['_POSITIONMESSAGE']._serialized_start=985
+ _globals['_POSITIONMESSAGE']._serialized_end=1162
# @@protoc_insertion_point(module_scope)
diff --git a/python/visionapi/visionapi/sae_pb2.pyi b/python/visionapi/visionapi/sae_pb2.pyi
index 305b294..6afb950 100644
--- a/python/visionapi/visionapi/sae_pb2.pyi
+++ b/python/visionapi/visionapi/sae_pb2.pyi
@@ -8,16 +8,18 @@ from typing import ClassVar as _ClassVar, Optional as _Optional, Union as _Union
DESCRIPTOR: _descriptor.FileDescriptor
class SaeMessage(_message.Message):
- __slots__ = ("frame", "detections", "metrics", "type")
+ __slots__ = ("frame", "detections", "metrics", "model_metadata", "type")
FRAME_FIELD_NUMBER: _ClassVar[int]
DETECTIONS_FIELD_NUMBER: _ClassVar[int]
METRICS_FIELD_NUMBER: _ClassVar[int]
+ MODEL_METADATA_FIELD_NUMBER: _ClassVar[int]
TYPE_FIELD_NUMBER: _ClassVar[int]
frame: VideoFrame
detections: _containers.RepeatedCompositeFieldContainer[Detection]
metrics: Metrics
+ model_metadata: ModelMetadata
type: _common_pb2.MessageType
- def __init__(self, frame: _Optional[_Union[VideoFrame, _Mapping]] = ..., detections: _Optional[_Iterable[_Union[Detection, _Mapping]]] = ..., metrics: _Optional[_Union[Metrics, _Mapping]] = ..., type: _Optional[_Union[_common_pb2.MessageType, str]] = ...) -> None: ...
+ def __init__(self, frame: _Optional[_Union[VideoFrame, _Mapping]] = ..., detections: _Optional[_Iterable[_Union[Detection, _Mapping]]] = ..., metrics: _Optional[_Union[Metrics, _Mapping]] = ..., model_metadata: _Optional[_Union[ModelMetadata, _Mapping]] = ..., type: _Optional[_Union[_common_pb2.MessageType, str]] = ...) -> None: ...
class VideoFrame(_message.Message):
__slots__ = ("source_id", "timestamp_utc_ms", "shape", "frame_data", "frame_data_jpeg", "camera_location")
@@ -79,6 +81,19 @@ class Metrics(_message.Message):
tracking_inference_time_us: int
def __init__(self, detection_inference_time_us: _Optional[int] = ..., tracking_inference_time_us: _Optional[int] = ...) -> None: ...
+class ModelMetadata(_message.Message):
+ __slots__ = ("class_names",)
+ class ClassNamesEntry(_message.Message):
+ __slots__ = ("key", "value")
+ KEY_FIELD_NUMBER: _ClassVar[int]
+ VALUE_FIELD_NUMBER: _ClassVar[int]
+ key: int
+ value: str
+ def __init__(self, key: _Optional[int] = ..., value: _Optional[str] = ...) -> None: ...
+ CLASS_NAMES_FIELD_NUMBER: _ClassVar[int]
+ class_names: _containers.ScalarMap[int, str]
+ def __init__(self, class_names: _Optional[_Mapping[int, str]] = ...) -> None: ...
+
class PositionMessage(_message.Message):
__slots__ = ("timestamp_utc_ms", "geo_coordinate", "hdop", "fix", "sae_uuid", "type")
TIMESTAMP_UTC_MS_FIELD_NUMBER: _ClassVar[int]
diff --git a/visionapi/sae.proto b/visionapi/sae.proto
index 59c3d06..aa9d15d 100644
--- a/visionapi/sae.proto
+++ b/visionapi/sae.proto
@@ -10,6 +10,7 @@ message SaeMessage {
VideoFrame frame = 1;
repeated Detection detections = 2;
Metrics metrics = 99;
+ ModelMetadata model_metadata = 100;
MessageType type = 1000;
}
@@ -48,6 +49,10 @@ message Metrics {
uint32 tracking_inference_time_us = 2;
}
+message ModelMetadata {
+ map class_names = 1;
+}
+
message PositionMessage {
uint64 timestamp_utc_ms = 1;
GeoCoordinate geo_coordinate = 2;