Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
* The index into the outputs of the operation that produced this tensor.
*
*
* int32 output_num = 2;
*/
public Builder clearOutputNum() {
outputNum_ = 0;
onChanged();
return this;
}
public final Builder setUnknownFields(
final org.nd4j.shade.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFieldsProto3(unknownFields);
}
public final Builder mergeUnknownFields(
final org.nd4j.shade.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:tensorflow.eager.RemoteTensorHandle)
}
// @@protoc_insertion_point(class_scope:tensorflow.eager.RemoteTensorHandle)
private static final tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle();
}
public static tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final org.nd4j.shade.protobuf.Parser
PARSER = new org.nd4j.shade.protobuf.AbstractParser() {
public RemoteTensorHandle parsePartialFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return new RemoteTensorHandle(input, extensionRegistry);
}
};
public static org.nd4j.shade.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public org.nd4j.shade.protobuf.Parser getParserForType() {
return PARSER;
}
public tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface OperationOrBuilder extends
// @@protoc_insertion_point(interface_extends:tensorflow.eager.Operation)
org.nd4j.shade.protobuf.MessageOrBuilder {
/**
*
* A unique identifier for the operation. Set by the client so that the client
* can uniquely identify the outputs of the scheduled operation.
* In the initial implementation, sending duplicate IDs has undefined
* behaviour, but additional constraints may be placed upon this in the
* future.
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
*
* Protobuf type {@code tensorflow.eager.Operation}
*/
public static final class Operation extends
org.nd4j.shade.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:tensorflow.eager.Operation)
OperationOrBuilder {
private static final long serialVersionUID = 0L;
// Use Operation.newBuilder() to construct.
private Operation(org.nd4j.shade.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private Operation() {
id_ = 0L;
name_ = "";
inputs_ = java.util.Collections.emptyList();
controlOpIds_ = java.util.Collections.emptyList();
device_ = "";
}
@java.lang.Override
public final org.nd4j.shade.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Operation(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
org.nd4j.shade.protobuf.UnknownFieldSet.Builder unknownFields =
org.nd4j.shade.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!parseUnknownFieldProto3(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
case 8: {
id_ = input.readInt64();
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
name_ = s;
break;
}
case 26: {
if (!((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
inputs_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000004;
}
inputs_.add(
input.readMessage(tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.parser(), extensionRegistry));
break;
}
case 32: {
if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
controlOpIds_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000008;
}
controlOpIds_.add(input.readInt64());
break;
}
case 34: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
if (!((mutable_bitField0_ & 0x00000008) == 0x00000008) && input.getBytesUntilLimit() > 0) {
controlOpIds_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000008;
}
while (input.getBytesUntilLimit() > 0) {
controlOpIds_.add(input.readInt64());
}
input.popLimit(limit);
break;
}
case 42: {
if (!((mutable_bitField0_ & 0x00000010) == 0x00000010)) {
attrs_ = org.nd4j.shade.protobuf.MapField.newMapField(
AttrsDefaultEntryHolder.defaultEntry);
mutable_bitField0_ |= 0x00000010;
}
org.nd4j.shade.protobuf.MapEntry
attrs__ = input.readMessage(
AttrsDefaultEntryHolder.defaultEntry.getParserForType(), extensionRegistry);
attrs_.getMutableMap().put(
attrs__.getKey(), attrs__.getValue());
break;
}
case 50: {
java.lang.String s = input.readStringRequireUtf8();
device_ = s;
break;
}
}
}
} catch (org.nd4j.shade.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new org.nd4j.shade.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000004) == 0x00000004)) {
inputs_ = java.util.Collections.unmodifiableList(inputs_);
}
if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
controlOpIds_ = java.util.Collections.unmodifiableList(controlOpIds_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final org.nd4j.shade.protobuf.Descriptors.Descriptor
getDescriptor() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_Operation_descriptor;
}
@SuppressWarnings({"rawtypes"})
protected org.nd4j.shade.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 5:
return internalGetAttrs();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
protected org.nd4j.shade.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_Operation_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tensorflow.eager.EagerServiceOuterClass.Operation.class, tensorflow.eager.EagerServiceOuterClass.Operation.Builder.class);
}
private int bitField0_;
public static final int ID_FIELD_NUMBER = 1;
private long id_;
/**
*
* A unique identifier for the operation. Set by the client so that the client
* can uniquely identify the outputs of the scheduled operation.
* In the initial implementation, sending duplicate IDs has undefined
* behaviour, but additional constraints may be placed upon this in the
* future.
*
*
* int64 id = 1;
*/
public long getId() {
return id_;
}
public static final int NAME_FIELD_NUMBER = 2;
private volatile java.lang.Object name_;
/**
* string name = 2;
*/
public java.lang.String getName() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
org.nd4j.shade.protobuf.ByteString bs =
(org.nd4j.shade.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
name_ = s;
return s;
}
}
/**
* string name = 2;
*/
public org.nd4j.shade.protobuf.ByteString
getNameBytes() {
java.lang.Object ref = name_;
if (ref instanceof java.lang.String) {
org.nd4j.shade.protobuf.ByteString b =
org.nd4j.shade.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
name_ = b;
return b;
} else {
return (org.nd4j.shade.protobuf.ByteString) ref;
}
}
public static final int INPUTS_FIELD_NUMBER = 3;
private java.util.List inputs_;
/**
* repeated .tensorflow.eager.RemoteTensorHandle inputs = 3;
*/
public java.util.List getInputsList() {
return inputs_;
}
/**
* repeated .tensorflow.eager.RemoteTensorHandle inputs = 3;
*/
public java.util.List extends tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandleOrBuilder>
getInputsOrBuilderList() {
return inputs_;
}
/**
* repeated .tensorflow.eager.RemoteTensorHandle inputs = 3;
*/
public int getInputsCount() {
return inputs_.size();
}
/**
* repeated .tensorflow.eager.RemoteTensorHandle inputs = 3;
*/
public tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle getInputs(int index) {
return inputs_.get(index);
}
/**
* repeated .tensorflow.eager.RemoteTensorHandle inputs = 3;
*/
public tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandleOrBuilder getInputsOrBuilder(
int index) {
return inputs_.get(index);
}
public static final int CONTROL_OP_IDS_FIELD_NUMBER = 4;
private java.util.List controlOpIds_;
/**
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
*
* repeated int64 control_op_ids = 4;
*/
public int getControlOpIdsCount() {
return controlOpIds_.size();
}
/**
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
*
* repeated int64 control_op_ids = 4;
*/
public long getControlOpIds(int index) {
return controlOpIds_.get(index);
}
private int controlOpIdsMemoizedSerializedSize = -1;
public static final int ATTRS_FIELD_NUMBER = 5;
private static final class AttrsDefaultEntryHolder {
static final org.nd4j.shade.protobuf.MapEntry<
java.lang.String, org.tensorflow.framework.AttrValue> defaultEntry =
org.nd4j.shade.protobuf.MapEntry
.newDefaultInstance(
tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_Operation_AttrsEntry_descriptor,
org.nd4j.shade.protobuf.WireFormat.FieldType.STRING,
"",
org.nd4j.shade.protobuf.WireFormat.FieldType.MESSAGE,
org.tensorflow.framework.AttrValue.getDefaultInstance());
}
private org.nd4j.shade.protobuf.MapField<
java.lang.String, org.tensorflow.framework.AttrValue> attrs_;
private org.nd4j.shade.protobuf.MapField
internalGetAttrs() {
if (attrs_ == null) {
return org.nd4j.shade.protobuf.MapField.emptyMapField(
AttrsDefaultEntryHolder.defaultEntry);
}
return attrs_;
}
public int getAttrsCount() {
return internalGetAttrs().getMap().size();
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public boolean containsAttrs(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
return internalGetAttrs().getMap().containsKey(key);
}
/**
* Use {@link #getAttrsMap()} instead.
*/
@java.lang.Deprecated
public java.util.Map getAttrs() {
return getAttrsMap();
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public java.util.Map getAttrsMap() {
return internalGetAttrs().getMap();
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public org.tensorflow.framework.AttrValue getAttrsOrDefault(
java.lang.String key,
org.tensorflow.framework.AttrValue defaultValue) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetAttrs().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public org.tensorflow.framework.AttrValue getAttrsOrThrow(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetAttrs().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public static final int DEVICE_FIELD_NUMBER = 6;
private volatile java.lang.Object device_;
/**
* string device = 6;
*/
public java.lang.String getDevice() {
java.lang.Object ref = device_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
org.nd4j.shade.protobuf.ByteString bs =
(org.nd4j.shade.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
device_ = s;
return s;
}
}
/**
* string device = 6;
*/
public org.nd4j.shade.protobuf.ByteString
getDeviceBytes() {
java.lang.Object ref = device_;
if (ref instanceof java.lang.String) {
org.nd4j.shade.protobuf.ByteString b =
org.nd4j.shade.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
device_ = b;
return b;
} else {
return (org.nd4j.shade.protobuf.ByteString) ref;
}
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
public void writeTo(org.nd4j.shade.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
if (id_ != 0L) {
output.writeInt64(1, id_);
}
if (!getNameBytes().isEmpty()) {
org.nd4j.shade.protobuf.GeneratedMessageV3.writeString(output, 2, name_);
}
for (int i = 0; i < inputs_.size(); i++) {
output.writeMessage(3, inputs_.get(i));
}
if (getControlOpIdsList().size() > 0) {
output.writeUInt32NoTag(34);
output.writeUInt32NoTag(controlOpIdsMemoizedSerializedSize);
}
for (int i = 0; i < controlOpIds_.size(); i++) {
output.writeInt64NoTag(controlOpIds_.get(i));
}
org.nd4j.shade.protobuf.GeneratedMessageV3
.serializeStringMapTo(
output,
internalGetAttrs(),
AttrsDefaultEntryHolder.defaultEntry,
5);
if (!getDeviceBytes().isEmpty()) {
org.nd4j.shade.protobuf.GeneratedMessageV3.writeString(output, 6, device_);
}
unknownFields.writeTo(output);
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (id_ != 0L) {
size += org.nd4j.shade.protobuf.CodedOutputStream
.computeInt64Size(1, id_);
}
if (!getNameBytes().isEmpty()) {
size += org.nd4j.shade.protobuf.GeneratedMessageV3.computeStringSize(2, name_);
}
for (int i = 0; i < inputs_.size(); i++) {
size += org.nd4j.shade.protobuf.CodedOutputStream
.computeMessageSize(3, inputs_.get(i));
}
{
int dataSize = 0;
for (int i = 0; i < controlOpIds_.size(); i++) {
dataSize += org.nd4j.shade.protobuf.CodedOutputStream
.computeInt64SizeNoTag(controlOpIds_.get(i));
}
size += dataSize;
if (!getControlOpIdsList().isEmpty()) {
size += 1;
size += org.nd4j.shade.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
controlOpIdsMemoizedSerializedSize = dataSize;
}
for (java.util.Map.Entry entry
: internalGetAttrs().getMap().entrySet()) {
org.nd4j.shade.protobuf.MapEntry
attrs__ = AttrsDefaultEntryHolder.defaultEntry.newBuilderForType()
.setKey(entry.getKey())
.setValue(entry.getValue())
.build();
size += org.nd4j.shade.protobuf.CodedOutputStream
.computeMessageSize(5, attrs__);
}
if (!getDeviceBytes().isEmpty()) {
size += org.nd4j.shade.protobuf.GeneratedMessageV3.computeStringSize(6, device_);
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tensorflow.eager.EagerServiceOuterClass.Operation)) {
return super.equals(obj);
}
tensorflow.eager.EagerServiceOuterClass.Operation other = (tensorflow.eager.EagerServiceOuterClass.Operation) obj;
boolean result = true;
result = result && (getId()
== other.getId());
result = result && getName()
.equals(other.getName());
result = result && getInputsList()
.equals(other.getInputsList());
result = result && getControlOpIdsList()
.equals(other.getControlOpIdsList());
result = result && internalGetAttrs().equals(
other.internalGetAttrs());
result = result && getDevice()
.equals(other.getDevice());
result = result && unknownFields.equals(other.unknownFields);
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + ID_FIELD_NUMBER;
hash = (53 * hash) + org.nd4j.shade.protobuf.Internal.hashLong(
getId());
hash = (37 * hash) + NAME_FIELD_NUMBER;
hash = (53 * hash) + getName().hashCode();
if (getInputsCount() > 0) {
hash = (37 * hash) + INPUTS_FIELD_NUMBER;
hash = (53 * hash) + getInputsList().hashCode();
}
if (getControlOpIdsCount() > 0) {
hash = (37 * hash) + CONTROL_OP_IDS_FIELD_NUMBER;
hash = (53 * hash) + getControlOpIdsList().hashCode();
}
if (!internalGetAttrs().getMap().isEmpty()) {
hash = (37 * hash) + ATTRS_FIELD_NUMBER;
hash = (53 * hash) + internalGetAttrs().hashCode();
}
hash = (37 * hash) + DEVICE_FIELD_NUMBER;
hash = (53 * hash) + getDevice().hashCode();
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(
java.nio.ByteBuffer data)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(
java.nio.ByteBuffer data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(
org.nd4j.shade.protobuf.ByteString data)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(
org.nd4j.shade.protobuf.ByteString data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(byte[] data)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(
byte[] data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(java.io.InputStream input)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(
java.io.InputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseDelimitedFrom(
java.io.InputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(
org.nd4j.shade.protobuf.CodedInputStream input)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tensorflow.eager.EagerServiceOuterClass.Operation parseFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tensorflow.eager.EagerServiceOuterClass.Operation prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
org.nd4j.shade.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* A proto representation of an eager operation.
*
*
* Protobuf type {@code tensorflow.eager.Operation}
*/
public static final class Builder extends
org.nd4j.shade.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:tensorflow.eager.Operation)
tensorflow.eager.EagerServiceOuterClass.OperationOrBuilder {
public static final org.nd4j.shade.protobuf.Descriptors.Descriptor
getDescriptor() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_Operation_descriptor;
}
@SuppressWarnings({"rawtypes"})
protected org.nd4j.shade.protobuf.MapField internalGetMapField(
int number) {
switch (number) {
case 5:
return internalGetAttrs();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
@SuppressWarnings({"rawtypes"})
protected org.nd4j.shade.protobuf.MapField internalGetMutableMapField(
int number) {
switch (number) {
case 5:
return internalGetMutableAttrs();
default:
throw new RuntimeException(
"Invalid map field number: " + number);
}
}
protected org.nd4j.shade.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_Operation_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tensorflow.eager.EagerServiceOuterClass.Operation.class, tensorflow.eager.EagerServiceOuterClass.Operation.Builder.class);
}
// Construct using tensorflow.eager.EagerServiceOuterClass.Operation.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
org.nd4j.shade.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (org.nd4j.shade.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getInputsFieldBuilder();
}
}
public Builder clear() {
super.clear();
id_ = 0L;
name_ = "";
if (inputsBuilder_ == null) {
inputs_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
} else {
inputsBuilder_.clear();
}
controlOpIds_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000008);
internalGetMutableAttrs().clear();
device_ = "";
return this;
}
public org.nd4j.shade.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_Operation_descriptor;
}
public tensorflow.eager.EagerServiceOuterClass.Operation getDefaultInstanceForType() {
return tensorflow.eager.EagerServiceOuterClass.Operation.getDefaultInstance();
}
public tensorflow.eager.EagerServiceOuterClass.Operation build() {
tensorflow.eager.EagerServiceOuterClass.Operation result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public tensorflow.eager.EagerServiceOuterClass.Operation buildPartial() {
tensorflow.eager.EagerServiceOuterClass.Operation result = new tensorflow.eager.EagerServiceOuterClass.Operation(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
result.id_ = id_;
result.name_ = name_;
if (inputsBuilder_ == null) {
if (((bitField0_ & 0x00000004) == 0x00000004)) {
inputs_ = java.util.Collections.unmodifiableList(inputs_);
bitField0_ = (bitField0_ & ~0x00000004);
}
result.inputs_ = inputs_;
} else {
result.inputs_ = inputsBuilder_.build();
}
if (((bitField0_ & 0x00000008) == 0x00000008)) {
controlOpIds_ = java.util.Collections.unmodifiableList(controlOpIds_);
bitField0_ = (bitField0_ & ~0x00000008);
}
result.controlOpIds_ = controlOpIds_;
result.attrs_ = internalGetAttrs();
result.attrs_.makeImmutable();
result.device_ = device_;
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
public Builder clone() {
return (Builder) super.clone();
}
public Builder setField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.setField(field, value);
}
public Builder clearField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
public Builder clearOneof(
org.nd4j.shade.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
public Builder setRepeatedField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
public Builder addRepeatedField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.addRepeatedField(field, value);
}
public Builder mergeFrom(org.nd4j.shade.protobuf.Message other) {
if (other instanceof tensorflow.eager.EagerServiceOuterClass.Operation) {
return mergeFrom((tensorflow.eager.EagerServiceOuterClass.Operation)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tensorflow.eager.EagerServiceOuterClass.Operation other) {
if (other == tensorflow.eager.EagerServiceOuterClass.Operation.getDefaultInstance()) return this;
if (other.getId() != 0L) {
setId(other.getId());
}
if (!other.getName().isEmpty()) {
name_ = other.name_;
onChanged();
}
if (inputsBuilder_ == null) {
if (!other.inputs_.isEmpty()) {
if (inputs_.isEmpty()) {
inputs_ = other.inputs_;
bitField0_ = (bitField0_ & ~0x00000004);
} else {
ensureInputsIsMutable();
inputs_.addAll(other.inputs_);
}
onChanged();
}
} else {
if (!other.inputs_.isEmpty()) {
if (inputsBuilder_.isEmpty()) {
inputsBuilder_.dispose();
inputsBuilder_ = null;
inputs_ = other.inputs_;
bitField0_ = (bitField0_ & ~0x00000004);
inputsBuilder_ =
org.nd4j.shade.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getInputsFieldBuilder() : null;
} else {
inputsBuilder_.addAllMessages(other.inputs_);
}
}
}
if (!other.controlOpIds_.isEmpty()) {
if (controlOpIds_.isEmpty()) {
controlOpIds_ = other.controlOpIds_;
bitField0_ = (bitField0_ & ~0x00000008);
} else {
ensureControlOpIdsIsMutable();
controlOpIds_.addAll(other.controlOpIds_);
}
onChanged();
}
internalGetMutableAttrs().mergeFrom(
other.internalGetAttrs());
if (!other.getDevice().isEmpty()) {
device_ = other.device_;
onChanged();
}
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
public final boolean isInitialized() {
return true;
}
public Builder mergeFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
tensorflow.eager.EagerServiceOuterClass.Operation parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (org.nd4j.shade.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (tensorflow.eager.EagerServiceOuterClass.Operation) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private long id_ ;
/**
*
* A unique identifier for the operation. Set by the client so that the client
* can uniquely identify the outputs of the scheduled operation.
* In the initial implementation, sending duplicate IDs has undefined
* behaviour, but additional constraints may be placed upon this in the
* future.
*
*
* int64 id = 1;
*/
public long getId() {
return id_;
}
/**
*
* A unique identifier for the operation. Set by the client so that the client
* can uniquely identify the outputs of the scheduled operation.
* In the initial implementation, sending duplicate IDs has undefined
* behaviour, but additional constraints may be placed upon this in the
* future.
*
* A unique identifier for the operation. Set by the client so that the client
* can uniquely identify the outputs of the scheduled operation.
* In the initial implementation, sending duplicate IDs has undefined
* behaviour, but additional constraints may be placed upon this in the
* future.
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
*
* repeated int64 control_op_ids = 4;
*/
public int getControlOpIdsCount() {
return controlOpIds_.size();
}
/**
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
*
* repeated int64 control_op_ids = 4;
*/
public long getControlOpIds(int index) {
return controlOpIds_.get(index);
}
/**
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
*
* repeated int64 control_op_ids = 4;
*/
public Builder setControlOpIds(
int index, long value) {
ensureControlOpIdsIsMutable();
controlOpIds_.set(index, value);
onChanged();
return this;
}
/**
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
* Control Operation IDs that will be respected when ops are re-ordered by
* async execution. If async execution (+ op re-ordering) is not enabled, this
* should have no effect.
*
*
* repeated int64 control_op_ids = 4;
*/
public Builder clearControlOpIds() {
controlOpIds_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000008);
onChanged();
return this;
}
private org.nd4j.shade.protobuf.MapField<
java.lang.String, org.tensorflow.framework.AttrValue> attrs_;
private org.nd4j.shade.protobuf.MapField
internalGetAttrs() {
if (attrs_ == null) {
return org.nd4j.shade.protobuf.MapField.emptyMapField(
AttrsDefaultEntryHolder.defaultEntry);
}
return attrs_;
}
private org.nd4j.shade.protobuf.MapField
internalGetMutableAttrs() {
onChanged();;
if (attrs_ == null) {
attrs_ = org.nd4j.shade.protobuf.MapField.newMapField(
AttrsDefaultEntryHolder.defaultEntry);
}
if (!attrs_.isMutable()) {
attrs_ = attrs_.copy();
}
return attrs_;
}
public int getAttrsCount() {
return internalGetAttrs().getMap().size();
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public boolean containsAttrs(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
return internalGetAttrs().getMap().containsKey(key);
}
/**
* Use {@link #getAttrsMap()} instead.
*/
@java.lang.Deprecated
public java.util.Map getAttrs() {
return getAttrsMap();
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public java.util.Map getAttrsMap() {
return internalGetAttrs().getMap();
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public org.tensorflow.framework.AttrValue getAttrsOrDefault(
java.lang.String key,
org.tensorflow.framework.AttrValue defaultValue) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetAttrs().getMap();
return map.containsKey(key) ? map.get(key) : defaultValue;
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public org.tensorflow.framework.AttrValue getAttrsOrThrow(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
java.util.Map map =
internalGetAttrs().getMap();
if (!map.containsKey(key)) {
throw new java.lang.IllegalArgumentException();
}
return map.get(key);
}
public Builder clearAttrs() {
internalGetMutableAttrs().getMutableMap()
.clear();
return this;
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public Builder removeAttrs(
java.lang.String key) {
if (key == null) { throw new java.lang.NullPointerException(); }
internalGetMutableAttrs().getMutableMap()
.remove(key);
return this;
}
/**
* Use alternate mutation accessors instead.
*/
@java.lang.Deprecated
public java.util.Map
getMutableAttrs() {
return internalGetMutableAttrs().getMutableMap();
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public Builder putAttrs(
java.lang.String key,
org.tensorflow.framework.AttrValue value) {
if (key == null) { throw new java.lang.NullPointerException(); }
if (value == null) { throw new java.lang.NullPointerException(); }
internalGetMutableAttrs().getMutableMap()
.put(key, value);
return this;
}
/**
* map<string, .tensorflow.AttrValue> attrs = 5;
*/
public Builder putAllAttrs(
java.util.Map values) {
internalGetMutableAttrs().getMutableMap()
.putAll(values);
return this;
}
private java.lang.Object device_ = "";
/**
* string device = 6;
*/
public java.lang.String getDevice() {
java.lang.Object ref = device_;
if (!(ref instanceof java.lang.String)) {
org.nd4j.shade.protobuf.ByteString bs =
(org.nd4j.shade.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
device_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string device = 6;
*/
public org.nd4j.shade.protobuf.ByteString
getDeviceBytes() {
java.lang.Object ref = device_;
if (ref instanceof String) {
org.nd4j.shade.protobuf.ByteString b =
org.nd4j.shade.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
device_ = b;
return b;
} else {
return (org.nd4j.shade.protobuf.ByteString) ref;
}
}
/**
* string device = 6;
*/
public Builder setDevice(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
device_ = value;
onChanged();
return this;
}
/**
* string device = 6;
*/
public Builder clearDevice() {
device_ = getDefaultInstance().getDevice();
onChanged();
return this;
}
/**
* string device = 6;
*/
public Builder setDeviceBytes(
org.nd4j.shade.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
device_ = value;
onChanged();
return this;
}
public final Builder setUnknownFields(
final org.nd4j.shade.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFieldsProto3(unknownFields);
}
public final Builder mergeUnknownFields(
final org.nd4j.shade.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:tensorflow.eager.Operation)
}
// @@protoc_insertion_point(class_scope:tensorflow.eager.Operation)
private static final tensorflow.eager.EagerServiceOuterClass.Operation DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tensorflow.eager.EagerServiceOuterClass.Operation();
}
public static tensorflow.eager.EagerServiceOuterClass.Operation getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final org.nd4j.shade.protobuf.Parser
PARSER = new org.nd4j.shade.protobuf.AbstractParser() {
public Operation parsePartialFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return new Operation(input, extensionRegistry);
}
};
public static org.nd4j.shade.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public org.nd4j.shade.protobuf.Parser getParserForType() {
return PARSER;
}
public tensorflow.eager.EagerServiceOuterClass.Operation getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface QueueItemOrBuilder extends
// @@protoc_insertion_point(interface_extends:tensorflow.eager.QueueItem)
org.nd4j.shade.protobuf.MessageOrBuilder {
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
boolean hasHandleToDecref();
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle getHandleToDecref();
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandleOrBuilder getHandleToDecrefOrBuilder();
/**
* .tensorflow.eager.Operation operation = 2;
*/
boolean hasOperation();
/**
* .tensorflow.eager.Operation operation = 2;
*/
tensorflow.eager.EagerServiceOuterClass.Operation getOperation();
/**
* .tensorflow.eager.Operation operation = 2;
*/
tensorflow.eager.EagerServiceOuterClass.OperationOrBuilder getOperationOrBuilder();
public tensorflow.eager.EagerServiceOuterClass.QueueItem.ItemCase getItemCase();
}
/**
* Protobuf type {@code tensorflow.eager.QueueItem}
*/
public static final class QueueItem extends
org.nd4j.shade.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:tensorflow.eager.QueueItem)
QueueItemOrBuilder {
private static final long serialVersionUID = 0L;
// Use QueueItem.newBuilder() to construct.
private QueueItem(org.nd4j.shade.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private QueueItem() {
}
@java.lang.Override
public final org.nd4j.shade.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private QueueItem(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
org.nd4j.shade.protobuf.UnknownFieldSet.Builder unknownFields =
org.nd4j.shade.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!parseUnknownFieldProto3(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
case 10: {
tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.Builder subBuilder = null;
if (itemCase_ == 1) {
subBuilder = ((tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_).toBuilder();
}
item_ =
input.readMessage(tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom((tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_);
item_ = subBuilder.buildPartial();
}
itemCase_ = 1;
break;
}
case 18: {
tensorflow.eager.EagerServiceOuterClass.Operation.Builder subBuilder = null;
if (itemCase_ == 2) {
subBuilder = ((tensorflow.eager.EagerServiceOuterClass.Operation) item_).toBuilder();
}
item_ =
input.readMessage(tensorflow.eager.EagerServiceOuterClass.Operation.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom((tensorflow.eager.EagerServiceOuterClass.Operation) item_);
item_ = subBuilder.buildPartial();
}
itemCase_ = 2;
break;
}
}
}
} catch (org.nd4j.shade.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new org.nd4j.shade.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final org.nd4j.shade.protobuf.Descriptors.Descriptor
getDescriptor() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_QueueItem_descriptor;
}
protected org.nd4j.shade.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_QueueItem_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tensorflow.eager.EagerServiceOuterClass.QueueItem.class, tensorflow.eager.EagerServiceOuterClass.QueueItem.Builder.class);
}
private int itemCase_ = 0;
private java.lang.Object item_;
public enum ItemCase
implements org.nd4j.shade.protobuf.Internal.EnumLite {
HANDLE_TO_DECREF(1),
OPERATION(2),
ITEM_NOT_SET(0);
private final int value;
private ItemCase(int value) {
this.value = value;
}
/**
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static ItemCase valueOf(int value) {
return forNumber(value);
}
public static ItemCase forNumber(int value) {
switch (value) {
case 1: return HANDLE_TO_DECREF;
case 2: return OPERATION;
case 0: return ITEM_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public ItemCase
getItemCase() {
return ItemCase.forNumber(
itemCase_);
}
public static final int HANDLE_TO_DECREF_FIELD_NUMBER = 1;
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public boolean hasHandleToDecref() {
return itemCase_ == 1;
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle getHandleToDecref() {
if (itemCase_ == 1) {
return (tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_;
}
return tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.getDefaultInstance();
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandleOrBuilder getHandleToDecrefOrBuilder() {
if (itemCase_ == 1) {
return (tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_;
}
return tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.getDefaultInstance();
}
public static final int OPERATION_FIELD_NUMBER = 2;
/**
* .tensorflow.eager.Operation operation = 2;
*/
public boolean hasOperation() {
return itemCase_ == 2;
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
public tensorflow.eager.EagerServiceOuterClass.Operation getOperation() {
if (itemCase_ == 2) {
return (tensorflow.eager.EagerServiceOuterClass.Operation) item_;
}
return tensorflow.eager.EagerServiceOuterClass.Operation.getDefaultInstance();
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
public tensorflow.eager.EagerServiceOuterClass.OperationOrBuilder getOperationOrBuilder() {
if (itemCase_ == 2) {
return (tensorflow.eager.EagerServiceOuterClass.Operation) item_;
}
return tensorflow.eager.EagerServiceOuterClass.Operation.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
public void writeTo(org.nd4j.shade.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (itemCase_ == 1) {
output.writeMessage(1, (tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_);
}
if (itemCase_ == 2) {
output.writeMessage(2, (tensorflow.eager.EagerServiceOuterClass.Operation) item_);
}
unknownFields.writeTo(output);
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (itemCase_ == 1) {
size += org.nd4j.shade.protobuf.CodedOutputStream
.computeMessageSize(1, (tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_);
}
if (itemCase_ == 2) {
size += org.nd4j.shade.protobuf.CodedOutputStream
.computeMessageSize(2, (tensorflow.eager.EagerServiceOuterClass.Operation) item_);
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tensorflow.eager.EagerServiceOuterClass.QueueItem)) {
return super.equals(obj);
}
tensorflow.eager.EagerServiceOuterClass.QueueItem other = (tensorflow.eager.EagerServiceOuterClass.QueueItem) obj;
boolean result = true;
result = result && getItemCase().equals(
other.getItemCase());
if (!result) return false;
switch (itemCase_) {
case 1:
result = result && getHandleToDecref()
.equals(other.getHandleToDecref());
break;
case 2:
result = result && getOperation()
.equals(other.getOperation());
break;
case 0:
default:
}
result = result && unknownFields.equals(other.unknownFields);
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
switch (itemCase_) {
case 1:
hash = (37 * hash) + HANDLE_TO_DECREF_FIELD_NUMBER;
hash = (53 * hash) + getHandleToDecref().hashCode();
break;
case 2:
hash = (37 * hash) + OPERATION_FIELD_NUMBER;
hash = (53 * hash) + getOperation().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(
java.nio.ByteBuffer data)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(
java.nio.ByteBuffer data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(
org.nd4j.shade.protobuf.ByteString data)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(
org.nd4j.shade.protobuf.ByteString data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(byte[] data)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(
byte[] data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(java.io.InputStream input)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(
java.io.InputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseDelimitedFrom(
java.io.InputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(
org.nd4j.shade.protobuf.CodedInputStream input)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem parseFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tensorflow.eager.EagerServiceOuterClass.QueueItem prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
org.nd4j.shade.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code tensorflow.eager.QueueItem}
*/
public static final class Builder extends
org.nd4j.shade.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:tensorflow.eager.QueueItem)
tensorflow.eager.EagerServiceOuterClass.QueueItemOrBuilder {
public static final org.nd4j.shade.protobuf.Descriptors.Descriptor
getDescriptor() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_QueueItem_descriptor;
}
protected org.nd4j.shade.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_QueueItem_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tensorflow.eager.EagerServiceOuterClass.QueueItem.class, tensorflow.eager.EagerServiceOuterClass.QueueItem.Builder.class);
}
// Construct using tensorflow.eager.EagerServiceOuterClass.QueueItem.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
org.nd4j.shade.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (org.nd4j.shade.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
public Builder clear() {
super.clear();
itemCase_ = 0;
item_ = null;
return this;
}
public org.nd4j.shade.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_QueueItem_descriptor;
}
public tensorflow.eager.EagerServiceOuterClass.QueueItem getDefaultInstanceForType() {
return tensorflow.eager.EagerServiceOuterClass.QueueItem.getDefaultInstance();
}
public tensorflow.eager.EagerServiceOuterClass.QueueItem build() {
tensorflow.eager.EagerServiceOuterClass.QueueItem result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public tensorflow.eager.EagerServiceOuterClass.QueueItem buildPartial() {
tensorflow.eager.EagerServiceOuterClass.QueueItem result = new tensorflow.eager.EagerServiceOuterClass.QueueItem(this);
if (itemCase_ == 1) {
if (handleToDecrefBuilder_ == null) {
result.item_ = item_;
} else {
result.item_ = handleToDecrefBuilder_.build();
}
}
if (itemCase_ == 2) {
if (operationBuilder_ == null) {
result.item_ = item_;
} else {
result.item_ = operationBuilder_.build();
}
}
result.itemCase_ = itemCase_;
onBuilt();
return result;
}
public Builder clone() {
return (Builder) super.clone();
}
public Builder setField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.setField(field, value);
}
public Builder clearField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
public Builder clearOneof(
org.nd4j.shade.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
public Builder setRepeatedField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
public Builder addRepeatedField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.addRepeatedField(field, value);
}
public Builder mergeFrom(org.nd4j.shade.protobuf.Message other) {
if (other instanceof tensorflow.eager.EagerServiceOuterClass.QueueItem) {
return mergeFrom((tensorflow.eager.EagerServiceOuterClass.QueueItem)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tensorflow.eager.EagerServiceOuterClass.QueueItem other) {
if (other == tensorflow.eager.EagerServiceOuterClass.QueueItem.getDefaultInstance()) return this;
switch (other.getItemCase()) {
case HANDLE_TO_DECREF: {
mergeHandleToDecref(other.getHandleToDecref());
break;
}
case OPERATION: {
mergeOperation(other.getOperation());
break;
}
case ITEM_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
public final boolean isInitialized() {
return true;
}
public Builder mergeFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
tensorflow.eager.EagerServiceOuterClass.QueueItem parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (org.nd4j.shade.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (tensorflow.eager.EagerServiceOuterClass.QueueItem) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int itemCase_ = 0;
private java.lang.Object item_;
public ItemCase
getItemCase() {
return ItemCase.forNumber(
itemCase_);
}
public Builder clearItem() {
itemCase_ = 0;
item_ = null;
onChanged();
return this;
}
private org.nd4j.shade.protobuf.SingleFieldBuilderV3<
tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle, tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.Builder, tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandleOrBuilder> handleToDecrefBuilder_;
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public boolean hasHandleToDecref() {
return itemCase_ == 1;
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle getHandleToDecref() {
if (handleToDecrefBuilder_ == null) {
if (itemCase_ == 1) {
return (tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_;
}
return tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.getDefaultInstance();
} else {
if (itemCase_ == 1) {
return handleToDecrefBuilder_.getMessage();
}
return tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.getDefaultInstance();
}
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public Builder setHandleToDecref(tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle value) {
if (handleToDecrefBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
item_ = value;
onChanged();
} else {
handleToDecrefBuilder_.setMessage(value);
}
itemCase_ = 1;
return this;
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public Builder setHandleToDecref(
tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.Builder builderForValue) {
if (handleToDecrefBuilder_ == null) {
item_ = builderForValue.build();
onChanged();
} else {
handleToDecrefBuilder_.setMessage(builderForValue.build());
}
itemCase_ = 1;
return this;
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public Builder mergeHandleToDecref(tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle value) {
if (handleToDecrefBuilder_ == null) {
if (itemCase_ == 1 &&
item_ != tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.getDefaultInstance()) {
item_ = tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.newBuilder((tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_)
.mergeFrom(value).buildPartial();
} else {
item_ = value;
}
onChanged();
} else {
if (itemCase_ == 1) {
handleToDecrefBuilder_.mergeFrom(value);
}
handleToDecrefBuilder_.setMessage(value);
}
itemCase_ = 1;
return this;
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public Builder clearHandleToDecref() {
if (handleToDecrefBuilder_ == null) {
if (itemCase_ == 1) {
itemCase_ = 0;
item_ = null;
onChanged();
}
} else {
if (itemCase_ == 1) {
itemCase_ = 0;
item_ = null;
}
handleToDecrefBuilder_.clear();
}
return this;
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.Builder getHandleToDecrefBuilder() {
return getHandleToDecrefFieldBuilder().getBuilder();
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
public tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandleOrBuilder getHandleToDecrefOrBuilder() {
if ((itemCase_ == 1) && (handleToDecrefBuilder_ != null)) {
return handleToDecrefBuilder_.getMessageOrBuilder();
} else {
if (itemCase_ == 1) {
return (tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_;
}
return tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.getDefaultInstance();
}
}
/**
* .tensorflow.eager.RemoteTensorHandle handle_to_decref = 1;
*/
private org.nd4j.shade.protobuf.SingleFieldBuilderV3<
tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle, tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.Builder, tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandleOrBuilder>
getHandleToDecrefFieldBuilder() {
if (handleToDecrefBuilder_ == null) {
if (!(itemCase_ == 1)) {
item_ = tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.getDefaultInstance();
}
handleToDecrefBuilder_ = new org.nd4j.shade.protobuf.SingleFieldBuilderV3<
tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle, tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle.Builder, tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandleOrBuilder>(
(tensorflow.eager.EagerServiceOuterClass.RemoteTensorHandle) item_,
getParentForChildren(),
isClean());
item_ = null;
}
itemCase_ = 1;
onChanged();;
return handleToDecrefBuilder_;
}
private org.nd4j.shade.protobuf.SingleFieldBuilderV3<
tensorflow.eager.EagerServiceOuterClass.Operation, tensorflow.eager.EagerServiceOuterClass.Operation.Builder, tensorflow.eager.EagerServiceOuterClass.OperationOrBuilder> operationBuilder_;
/**
* .tensorflow.eager.Operation operation = 2;
*/
public boolean hasOperation() {
return itemCase_ == 2;
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
public tensorflow.eager.EagerServiceOuterClass.Operation getOperation() {
if (operationBuilder_ == null) {
if (itemCase_ == 2) {
return (tensorflow.eager.EagerServiceOuterClass.Operation) item_;
}
return tensorflow.eager.EagerServiceOuterClass.Operation.getDefaultInstance();
} else {
if (itemCase_ == 2) {
return operationBuilder_.getMessage();
}
return tensorflow.eager.EagerServiceOuterClass.Operation.getDefaultInstance();
}
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
public Builder setOperation(tensorflow.eager.EagerServiceOuterClass.Operation value) {
if (operationBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
item_ = value;
onChanged();
} else {
operationBuilder_.setMessage(value);
}
itemCase_ = 2;
return this;
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
public Builder setOperation(
tensorflow.eager.EagerServiceOuterClass.Operation.Builder builderForValue) {
if (operationBuilder_ == null) {
item_ = builderForValue.build();
onChanged();
} else {
operationBuilder_.setMessage(builderForValue.build());
}
itemCase_ = 2;
return this;
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
public Builder mergeOperation(tensorflow.eager.EagerServiceOuterClass.Operation value) {
if (operationBuilder_ == null) {
if (itemCase_ == 2 &&
item_ != tensorflow.eager.EagerServiceOuterClass.Operation.getDefaultInstance()) {
item_ = tensorflow.eager.EagerServiceOuterClass.Operation.newBuilder((tensorflow.eager.EagerServiceOuterClass.Operation) item_)
.mergeFrom(value).buildPartial();
} else {
item_ = value;
}
onChanged();
} else {
if (itemCase_ == 2) {
operationBuilder_.mergeFrom(value);
}
operationBuilder_.setMessage(value);
}
itemCase_ = 2;
return this;
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
public Builder clearOperation() {
if (operationBuilder_ == null) {
if (itemCase_ == 2) {
itemCase_ = 0;
item_ = null;
onChanged();
}
} else {
if (itemCase_ == 2) {
itemCase_ = 0;
item_ = null;
}
operationBuilder_.clear();
}
return this;
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
public tensorflow.eager.EagerServiceOuterClass.Operation.Builder getOperationBuilder() {
return getOperationFieldBuilder().getBuilder();
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
public tensorflow.eager.EagerServiceOuterClass.OperationOrBuilder getOperationOrBuilder() {
if ((itemCase_ == 2) && (operationBuilder_ != null)) {
return operationBuilder_.getMessageOrBuilder();
} else {
if (itemCase_ == 2) {
return (tensorflow.eager.EagerServiceOuterClass.Operation) item_;
}
return tensorflow.eager.EagerServiceOuterClass.Operation.getDefaultInstance();
}
}
/**
* .tensorflow.eager.Operation operation = 2;
*/
private org.nd4j.shade.protobuf.SingleFieldBuilderV3<
tensorflow.eager.EagerServiceOuterClass.Operation, tensorflow.eager.EagerServiceOuterClass.Operation.Builder, tensorflow.eager.EagerServiceOuterClass.OperationOrBuilder>
getOperationFieldBuilder() {
if (operationBuilder_ == null) {
if (!(itemCase_ == 2)) {
item_ = tensorflow.eager.EagerServiceOuterClass.Operation.getDefaultInstance();
}
operationBuilder_ = new org.nd4j.shade.protobuf.SingleFieldBuilderV3<
tensorflow.eager.EagerServiceOuterClass.Operation, tensorflow.eager.EagerServiceOuterClass.Operation.Builder, tensorflow.eager.EagerServiceOuterClass.OperationOrBuilder>(
(tensorflow.eager.EagerServiceOuterClass.Operation) item_,
getParentForChildren(),
isClean());
item_ = null;
}
itemCase_ = 2;
onChanged();;
return operationBuilder_;
}
public final Builder setUnknownFields(
final org.nd4j.shade.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFieldsProto3(unknownFields);
}
public final Builder mergeUnknownFields(
final org.nd4j.shade.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:tensorflow.eager.QueueItem)
}
// @@protoc_insertion_point(class_scope:tensorflow.eager.QueueItem)
private static final tensorflow.eager.EagerServiceOuterClass.QueueItem DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tensorflow.eager.EagerServiceOuterClass.QueueItem();
}
public static tensorflow.eager.EagerServiceOuterClass.QueueItem getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final org.nd4j.shade.protobuf.Parser
PARSER = new org.nd4j.shade.protobuf.AbstractParser() {
public QueueItem parsePartialFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return new QueueItem(input, extensionRegistry);
}
};
public static org.nd4j.shade.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public org.nd4j.shade.protobuf.Parser getParserForType() {
return PARSER;
}
public tensorflow.eager.EagerServiceOuterClass.QueueItem getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface CreateContextRequestOrBuilder extends
// @@protoc_insertion_point(interface_extends:tensorflow.eager.CreateContextRequest)
org.nd4j.shade.protobuf.MessageOrBuilder {
/**
*
* Identifies the full cluster, and this particular worker's position within.
*
* Whether the ops on the worker should be executed synchronously or
* asynchronously. By default, ops are executed synchronously.
*
*
* bool async = 2;
*/
boolean getAsync();
/**
*
* Number of seconds to keep the context alive. If more than keep_alive_secs
* has passed since a particular context has been communicated with, it will
* be garbage collected.
*
* Identifies the full cluster, and this particular worker's position within.
*
*
* .tensorflow.ServerDef server_def = 1;
*/
public org.tensorflow.distruntime.ServerDefOrBuilder getServerDefOrBuilder() {
return getServerDef();
}
public static final int ASYNC_FIELD_NUMBER = 2;
private boolean async_;
/**
*
* Whether the ops on the worker should be executed synchronously or
* asynchronously. By default, ops are executed synchronously.
*
*
* bool async = 2;
*/
public boolean getAsync() {
return async_;
}
public static final int KEEP_ALIVE_SECS_FIELD_NUMBER = 3;
private long keepAliveSecs_;
/**
*
* Number of seconds to keep the context alive. If more than keep_alive_secs
* has passed since a particular context has been communicated with, it will
* be garbage collected.
*
*
* int64 keep_alive_secs = 3;
*/
public long getKeepAliveSecs() {
return keepAliveSecs_;
}
public static final int VERSION_DEF_FIELD_NUMBER = 4;
private org.tensorflow.framework.VersionDef versionDef_;
/**
*
* This is the version for all the ops that will be enqueued by the client.
*
* Number of seconds to keep the context alive. If more than keep_alive_secs
* has passed since a particular context has been communicated with, it will
* be garbage collected.
*
*
* int64 keep_alive_secs = 3;
*/
public long getKeepAliveSecs() {
return keepAliveSecs_;
}
/**
*
* Number of seconds to keep the context alive. If more than keep_alive_secs
* has passed since a particular context has been communicated with, it will
* be garbage collected.
*
* Number of seconds to keep the context alive. If more than keep_alive_secs
* has passed since a particular context has been communicated with, it will
* be garbage collected.
*
* This is the version for all the ops that will be enqueued by the client.
*
*
* .tensorflow.VersionDef version_def = 4;
*/
private org.nd4j.shade.protobuf.SingleFieldBuilderV3<
org.tensorflow.framework.VersionDef, org.tensorflow.framework.VersionDef.Builder, org.tensorflow.framework.VersionDefOrBuilder>
getVersionDefFieldBuilder() {
if (versionDefBuilder_ == null) {
versionDefBuilder_ = new org.nd4j.shade.protobuf.SingleFieldBuilderV3<
org.tensorflow.framework.VersionDef, org.tensorflow.framework.VersionDef.Builder, org.tensorflow.framework.VersionDefOrBuilder>(
getVersionDef(),
getParentForChildren(),
isClean());
versionDef_ = null;
}
return versionDefBuilder_;
}
public final Builder setUnknownFields(
final org.nd4j.shade.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFieldsProto3(unknownFields);
}
public final Builder mergeUnknownFields(
final org.nd4j.shade.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:tensorflow.eager.CreateContextRequest)
}
// @@protoc_insertion_point(class_scope:tensorflow.eager.CreateContextRequest)
private static final tensorflow.eager.EagerServiceOuterClass.CreateContextRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new tensorflow.eager.EagerServiceOuterClass.CreateContextRequest();
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final org.nd4j.shade.protobuf.Parser
PARSER = new org.nd4j.shade.protobuf.AbstractParser() {
public CreateContextRequest parsePartialFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return new CreateContextRequest(input, extensionRegistry);
}
};
public static org.nd4j.shade.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public org.nd4j.shade.protobuf.Parser getParserForType() {
return PARSER;
}
public tensorflow.eager.EagerServiceOuterClass.CreateContextRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface CreateContextResponseOrBuilder extends
// @@protoc_insertion_point(interface_extends:tensorflow.eager.CreateContextResponse)
org.nd4j.shade.protobuf.MessageOrBuilder {
/**
*
* The ID of the created context. This is usually a randomly generated number,
* that will be used to identify the context in future requests to the
* service. Contexts are not persisted through server restarts.
*
* List of devices that are locally accessible to the worker.
*
*
* repeated .tensorflow.DeviceAttributes device_attributes = 2;
*/
org.tensorflow.framework.DeviceAttributesOrBuilder getDeviceAttributesOrBuilder(
int index);
}
/**
* Protobuf type {@code tensorflow.eager.CreateContextResponse}
*/
public static final class CreateContextResponse extends
org.nd4j.shade.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:tensorflow.eager.CreateContextResponse)
CreateContextResponseOrBuilder {
private static final long serialVersionUID = 0L;
// Use CreateContextResponse.newBuilder() to construct.
private CreateContextResponse(org.nd4j.shade.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private CreateContextResponse() {
contextId_ = 0L;
deviceAttributes_ = java.util.Collections.emptyList();
}
@java.lang.Override
public final org.nd4j.shade.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private CreateContextResponse(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
org.nd4j.shade.protobuf.UnknownFieldSet.Builder unknownFields =
org.nd4j.shade.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
default: {
if (!parseUnknownFieldProto3(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
case 9: {
contextId_ = input.readFixed64();
break;
}
case 18: {
if (!((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
deviceAttributes_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000002;
}
deviceAttributes_.add(
input.readMessage(org.tensorflow.framework.DeviceAttributes.parser(), extensionRegistry));
break;
}
}
}
} catch (org.nd4j.shade.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new org.nd4j.shade.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000002) == 0x00000002)) {
deviceAttributes_ = java.util.Collections.unmodifiableList(deviceAttributes_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final org.nd4j.shade.protobuf.Descriptors.Descriptor
getDescriptor() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_CreateContextResponse_descriptor;
}
protected org.nd4j.shade.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_CreateContextResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tensorflow.eager.EagerServiceOuterClass.CreateContextResponse.class, tensorflow.eager.EagerServiceOuterClass.CreateContextResponse.Builder.class);
}
private int bitField0_;
public static final int CONTEXT_ID_FIELD_NUMBER = 1;
private long contextId_;
/**
*
* The ID of the created context. This is usually a randomly generated number,
* that will be used to identify the context in future requests to the
* service. Contexts are not persisted through server restarts.
*
*
* fixed64 context_id = 1;
*/
public long getContextId() {
return contextId_;
}
public static final int DEVICE_ATTRIBUTES_FIELD_NUMBER = 2;
private java.util.List deviceAttributes_;
/**
*
* List of devices that are locally accessible to the worker.
*
* List of devices that are locally accessible to the worker.
*
*
* repeated .tensorflow.DeviceAttributes device_attributes = 2;
*/
public org.tensorflow.framework.DeviceAttributesOrBuilder getDeviceAttributesOrBuilder(
int index) {
return deviceAttributes_.get(index);
}
private byte memoizedIsInitialized = -1;
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
public void writeTo(org.nd4j.shade.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (contextId_ != 0L) {
output.writeFixed64(1, contextId_);
}
for (int i = 0; i < deviceAttributes_.size(); i++) {
output.writeMessage(2, deviceAttributes_.get(i));
}
unknownFields.writeTo(output);
}
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (contextId_ != 0L) {
size += org.nd4j.shade.protobuf.CodedOutputStream
.computeFixed64Size(1, contextId_);
}
for (int i = 0; i < deviceAttributes_.size(); i++) {
size += org.nd4j.shade.protobuf.CodedOutputStream
.computeMessageSize(2, deviceAttributes_.get(i));
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof tensorflow.eager.EagerServiceOuterClass.CreateContextResponse)) {
return super.equals(obj);
}
tensorflow.eager.EagerServiceOuterClass.CreateContextResponse other = (tensorflow.eager.EagerServiceOuterClass.CreateContextResponse) obj;
boolean result = true;
result = result && (getContextId()
== other.getContextId());
result = result && getDeviceAttributesList()
.equals(other.getDeviceAttributesList());
result = result && unknownFields.equals(other.unknownFields);
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + CONTEXT_ID_FIELD_NUMBER;
hash = (53 * hash) + org.nd4j.shade.protobuf.Internal.hashLong(
getContextId());
if (getDeviceAttributesCount() > 0) {
hash = (37 * hash) + DEVICE_ATTRIBUTES_FIELD_NUMBER;
hash = (53 * hash) + getDeviceAttributesList().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(
java.nio.ByteBuffer data)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(
java.nio.ByteBuffer data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(
org.nd4j.shade.protobuf.ByteString data)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(
org.nd4j.shade.protobuf.ByteString data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(byte[] data)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(
byte[] data,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws org.nd4j.shade.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(java.io.InputStream input)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(
java.io.InputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseDelimitedFrom(
java.io.InputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(
org.nd4j.shade.protobuf.CodedInputStream input)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parseFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return org.nd4j.shade.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(tensorflow.eager.EagerServiceOuterClass.CreateContextResponse prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
org.nd4j.shade.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code tensorflow.eager.CreateContextResponse}
*/
public static final class Builder extends
org.nd4j.shade.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:tensorflow.eager.CreateContextResponse)
tensorflow.eager.EagerServiceOuterClass.CreateContextResponseOrBuilder {
public static final org.nd4j.shade.protobuf.Descriptors.Descriptor
getDescriptor() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_CreateContextResponse_descriptor;
}
protected org.nd4j.shade.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_CreateContextResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
tensorflow.eager.EagerServiceOuterClass.CreateContextResponse.class, tensorflow.eager.EagerServiceOuterClass.CreateContextResponse.Builder.class);
}
// Construct using tensorflow.eager.EagerServiceOuterClass.CreateContextResponse.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
org.nd4j.shade.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (org.nd4j.shade.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getDeviceAttributesFieldBuilder();
}
}
public Builder clear() {
super.clear();
contextId_ = 0L;
if (deviceAttributesBuilder_ == null) {
deviceAttributes_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
} else {
deviceAttributesBuilder_.clear();
}
return this;
}
public org.nd4j.shade.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return tensorflow.eager.EagerServiceOuterClass.internal_static_tensorflow_eager_CreateContextResponse_descriptor;
}
public tensorflow.eager.EagerServiceOuterClass.CreateContextResponse getDefaultInstanceForType() {
return tensorflow.eager.EagerServiceOuterClass.CreateContextResponse.getDefaultInstance();
}
public tensorflow.eager.EagerServiceOuterClass.CreateContextResponse build() {
tensorflow.eager.EagerServiceOuterClass.CreateContextResponse result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
public tensorflow.eager.EagerServiceOuterClass.CreateContextResponse buildPartial() {
tensorflow.eager.EagerServiceOuterClass.CreateContextResponse result = new tensorflow.eager.EagerServiceOuterClass.CreateContextResponse(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
result.contextId_ = contextId_;
if (deviceAttributesBuilder_ == null) {
if (((bitField0_ & 0x00000002) == 0x00000002)) {
deviceAttributes_ = java.util.Collections.unmodifiableList(deviceAttributes_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.deviceAttributes_ = deviceAttributes_;
} else {
result.deviceAttributes_ = deviceAttributesBuilder_.build();
}
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
public Builder clone() {
return (Builder) super.clone();
}
public Builder setField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.setField(field, value);
}
public Builder clearField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
public Builder clearOneof(
org.nd4j.shade.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
public Builder setRepeatedField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
public Builder addRepeatedField(
org.nd4j.shade.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.addRepeatedField(field, value);
}
public Builder mergeFrom(org.nd4j.shade.protobuf.Message other) {
if (other instanceof tensorflow.eager.EagerServiceOuterClass.CreateContextResponse) {
return mergeFrom((tensorflow.eager.EagerServiceOuterClass.CreateContextResponse)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(tensorflow.eager.EagerServiceOuterClass.CreateContextResponse other) {
if (other == tensorflow.eager.EagerServiceOuterClass.CreateContextResponse.getDefaultInstance()) return this;
if (other.getContextId() != 0L) {
setContextId(other.getContextId());
}
if (deviceAttributesBuilder_ == null) {
if (!other.deviceAttributes_.isEmpty()) {
if (deviceAttributes_.isEmpty()) {
deviceAttributes_ = other.deviceAttributes_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureDeviceAttributesIsMutable();
deviceAttributes_.addAll(other.deviceAttributes_);
}
onChanged();
}
} else {
if (!other.deviceAttributes_.isEmpty()) {
if (deviceAttributesBuilder_.isEmpty()) {
deviceAttributesBuilder_.dispose();
deviceAttributesBuilder_ = null;
deviceAttributes_ = other.deviceAttributes_;
bitField0_ = (bitField0_ & ~0x00000002);
deviceAttributesBuilder_ =
org.nd4j.shade.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getDeviceAttributesFieldBuilder() : null;
} else {
deviceAttributesBuilder_.addAllMessages(other.deviceAttributes_);
}
}
}
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
public final boolean isInitialized() {
return true;
}
public Builder mergeFrom(
org.nd4j.shade.protobuf.CodedInputStream input,
org.nd4j.shade.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
tensorflow.eager.EagerServiceOuterClass.CreateContextResponse parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (org.nd4j.shade.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (tensorflow.eager.EagerServiceOuterClass.CreateContextResponse) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private long contextId_ ;
/**
*
* The ID of the created context. This is usually a randomly generated number,
* that will be used to identify the context in future requests to the
* service. Contexts are not persisted through server restarts.
*
*
* fixed64 context_id = 1;
*/
public long getContextId() {
return contextId_;
}
/**
*
* The ID of the created context. This is usually a randomly generated number,
* that will be used to identify the context in future requests to the
* service. Contexts are not persisted through server restarts.
*
* The ID of the created context. This is usually a randomly generated number,
* that will be used to identify the context in future requests to the
* service. Contexts are not persisted through server restarts.
*