Class GraphOptions.Builder

All Implemented Interfaces:
Message.Builder, MessageLite.Builder, MessageLiteOrBuilder, MessageOrBuilder, Cloneable, GraphOptionsOrBuilder
Enclosing class:
GraphOptions

public static final class GraphOptions.Builder extends GeneratedMessage.Builder<GraphOptions.Builder> implements GraphOptionsOrBuilder
Protobuf type tensorflow.GraphOptions
  • Method Details

    • getDescriptor

      public static final Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class GeneratedMessage.Builder<GraphOptions.Builder>
    • clear

      public GraphOptions.Builder clear()
      Specified by:
      clear in interface Message.Builder
      Specified by:
      clear in interface MessageLite.Builder
      Overrides:
      clear in class GeneratedMessage.Builder<GraphOptions.Builder>
    • getDescriptorForType

      public Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface Message.Builder
      Specified by:
      getDescriptorForType in interface MessageOrBuilder
      Overrides:
      getDescriptorForType in class GeneratedMessage.Builder<GraphOptions.Builder>
    • getDefaultInstanceForType

      public GraphOptions getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface MessageOrBuilder
    • build

      public GraphOptions build()
      Specified by:
      build in interface Message.Builder
      Specified by:
      build in interface MessageLite.Builder
    • buildPartial

      public GraphOptions buildPartial()
      Specified by:
      buildPartial in interface Message.Builder
      Specified by:
      buildPartial in interface MessageLite.Builder
    • mergeFrom

      public GraphOptions.Builder mergeFrom(Message other)
      Specified by:
      mergeFrom in interface Message.Builder
      Overrides:
      mergeFrom in class AbstractMessage.Builder<GraphOptions.Builder>
    • mergeFrom

      public GraphOptions.Builder mergeFrom(GraphOptions other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface MessageLiteOrBuilder
      Overrides:
      isInitialized in class GeneratedMessage.Builder<GraphOptions.Builder>
    • mergeFrom

      public GraphOptions.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface Message.Builder
      Specified by:
      mergeFrom in interface MessageLite.Builder
      Overrides:
      mergeFrom in class AbstractMessage.Builder<GraphOptions.Builder>
      Throws:
      IOException
    • getEnableRecvScheduling

      public boolean getEnableRecvScheduling()
      If true, use control flow to schedule the activation of Recv nodes.
      (Currently ignored.)
      
      bool enable_recv_scheduling = 2;
      Specified by:
      getEnableRecvScheduling in interface GraphOptionsOrBuilder
      Returns:
      The enableRecvScheduling.
    • setEnableRecvScheduling

      public GraphOptions.Builder setEnableRecvScheduling(boolean value)
      If true, use control flow to schedule the activation of Recv nodes.
      (Currently ignored.)
      
      bool enable_recv_scheduling = 2;
      Parameters:
      value - The enableRecvScheduling to set.
      Returns:
      This builder for chaining.
    • clearEnableRecvScheduling

      public GraphOptions.Builder clearEnableRecvScheduling()
      If true, use control flow to schedule the activation of Recv nodes.
      (Currently ignored.)
      
      bool enable_recv_scheduling = 2;
      Returns:
      This builder for chaining.
    • hasOptimizerOptions

      public boolean hasOptimizerOptions()
      Options controlling how graph is optimized.
      
      .tensorflow.OptimizerOptions optimizer_options = 3;
      Specified by:
      hasOptimizerOptions in interface GraphOptionsOrBuilder
      Returns:
      Whether the optimizerOptions field is set.
    • getOptimizerOptions

      public OptimizerOptions getOptimizerOptions()
      Options controlling how graph is optimized.
      
      .tensorflow.OptimizerOptions optimizer_options = 3;
      Specified by:
      getOptimizerOptions in interface GraphOptionsOrBuilder
      Returns:
      The optimizerOptions.
    • setOptimizerOptions

      public GraphOptions.Builder setOptimizerOptions(OptimizerOptions value)
      Options controlling how graph is optimized.
      
      .tensorflow.OptimizerOptions optimizer_options = 3;
    • setOptimizerOptions

      public GraphOptions.Builder setOptimizerOptions(OptimizerOptions.Builder builderForValue)
      Options controlling how graph is optimized.
      
      .tensorflow.OptimizerOptions optimizer_options = 3;
    • mergeOptimizerOptions

      public GraphOptions.Builder mergeOptimizerOptions(OptimizerOptions value)
      Options controlling how graph is optimized.
      
      .tensorflow.OptimizerOptions optimizer_options = 3;
    • clearOptimizerOptions

      public GraphOptions.Builder clearOptimizerOptions()
      Options controlling how graph is optimized.
      
      .tensorflow.OptimizerOptions optimizer_options = 3;
    • getOptimizerOptionsBuilder

      public OptimizerOptions.Builder getOptimizerOptionsBuilder()
      Options controlling how graph is optimized.
      
      .tensorflow.OptimizerOptions optimizer_options = 3;
    • getOptimizerOptionsOrBuilder

      public OptimizerOptionsOrBuilder getOptimizerOptionsOrBuilder()
      Options controlling how graph is optimized.
      
      .tensorflow.OptimizerOptions optimizer_options = 3;
      Specified by:
      getOptimizerOptionsOrBuilder in interface GraphOptionsOrBuilder
    • getBuildCostModel

      public long getBuildCostModel()
      The number of steps to run before returning a cost model detailing
      the memory usage and performance of each node of the graph. 0 means
      no cost model.
      
      int64 build_cost_model = 4;
      Specified by:
      getBuildCostModel in interface GraphOptionsOrBuilder
      Returns:
      The buildCostModel.
    • setBuildCostModel

      public GraphOptions.Builder setBuildCostModel(long value)
      The number of steps to run before returning a cost model detailing
      the memory usage and performance of each node of the graph. 0 means
      no cost model.
      
      int64 build_cost_model = 4;
      Parameters:
      value - The buildCostModel to set.
      Returns:
      This builder for chaining.
    • clearBuildCostModel

      public GraphOptions.Builder clearBuildCostModel()
      The number of steps to run before returning a cost model detailing
      the memory usage and performance of each node of the graph. 0 means
      no cost model.
      
      int64 build_cost_model = 4;
      Returns:
      This builder for chaining.
    • getBuildCostModelAfter

      public long getBuildCostModelAfter()
      The number of steps to skip before collecting statistics for the
      cost model.
      
      int64 build_cost_model_after = 9;
      Specified by:
      getBuildCostModelAfter in interface GraphOptionsOrBuilder
      Returns:
      The buildCostModelAfter.
    • setBuildCostModelAfter

      public GraphOptions.Builder setBuildCostModelAfter(long value)
      The number of steps to skip before collecting statistics for the
      cost model.
      
      int64 build_cost_model_after = 9;
      Parameters:
      value - The buildCostModelAfter to set.
      Returns:
      This builder for chaining.
    • clearBuildCostModelAfter

      public GraphOptions.Builder clearBuildCostModelAfter()
      The number of steps to skip before collecting statistics for the
      cost model.
      
      int64 build_cost_model_after = 9;
      Returns:
      This builder for chaining.
    • getInferShapes

      public boolean getInferShapes()
      Annotate each Node with Op output shape data, to the extent it can
      be statically inferred.
      
      bool infer_shapes = 5;
      Specified by:
      getInferShapes in interface GraphOptionsOrBuilder
      Returns:
      The inferShapes.
    • setInferShapes

      public GraphOptions.Builder setInferShapes(boolean value)
      Annotate each Node with Op output shape data, to the extent it can
      be statically inferred.
      
      bool infer_shapes = 5;
      Parameters:
      value - The inferShapes to set.
      Returns:
      This builder for chaining.
    • clearInferShapes

      public GraphOptions.Builder clearInferShapes()
      Annotate each Node with Op output shape data, to the extent it can
      be statically inferred.
      
      bool infer_shapes = 5;
      Returns:
      This builder for chaining.
    • getPlacePrunedGraph

      public boolean getPlacePrunedGraph()
      Only place the subgraphs that are run, rather than the entire graph.
      
      This is useful for interactive graph building, where one might
      produce graphs that cannot be placed during the debugging
      process.  In particular, it allows the client to continue work in
      a session after adding a node to a graph whose placement
      constraints are unsatisfiable.
      
      bool place_pruned_graph = 6;
      Specified by:
      getPlacePrunedGraph in interface GraphOptionsOrBuilder
      Returns:
      The placePrunedGraph.
    • setPlacePrunedGraph

      public GraphOptions.Builder setPlacePrunedGraph(boolean value)
      Only place the subgraphs that are run, rather than the entire graph.
      
      This is useful for interactive graph building, where one might
      produce graphs that cannot be placed during the debugging
      process.  In particular, it allows the client to continue work in
      a session after adding a node to a graph whose placement
      constraints are unsatisfiable.
      
      bool place_pruned_graph = 6;
      Parameters:
      value - The placePrunedGraph to set.
      Returns:
      This builder for chaining.
    • clearPlacePrunedGraph

      public GraphOptions.Builder clearPlacePrunedGraph()
      Only place the subgraphs that are run, rather than the entire graph.
      
      This is useful for interactive graph building, where one might
      produce graphs that cannot be placed during the debugging
      process.  In particular, it allows the client to continue work in
      a session after adding a node to a graph whose placement
      constraints are unsatisfiable.
      
      bool place_pruned_graph = 6;
      Returns:
      This builder for chaining.
    • getEnableBfloat16Sendrecv

      public boolean getEnableBfloat16Sendrecv()
      If true, transfer float values between processes as bfloat16.
      
      bool enable_bfloat16_sendrecv = 7;
      Specified by:
      getEnableBfloat16Sendrecv in interface GraphOptionsOrBuilder
      Returns:
      The enableBfloat16Sendrecv.
    • setEnableBfloat16Sendrecv

      public GraphOptions.Builder setEnableBfloat16Sendrecv(boolean value)
      If true, transfer float values between processes as bfloat16.
      
      bool enable_bfloat16_sendrecv = 7;
      Parameters:
      value - The enableBfloat16Sendrecv to set.
      Returns:
      This builder for chaining.
    • clearEnableBfloat16Sendrecv

      public GraphOptions.Builder clearEnableBfloat16Sendrecv()
      If true, transfer float values between processes as bfloat16.
      
      bool enable_bfloat16_sendrecv = 7;
      Returns:
      This builder for chaining.
    • getTimelineStep

      public int getTimelineStep()
      If > 0, record a timeline every this many steps.
      EXPERIMENTAL: This currently has no effect in MasterSession.
      
      int32 timeline_step = 8;
      Specified by:
      getTimelineStep in interface GraphOptionsOrBuilder
      Returns:
      The timelineStep.
    • setTimelineStep

      public GraphOptions.Builder setTimelineStep(int value)
      If > 0, record a timeline every this many steps.
      EXPERIMENTAL: This currently has no effect in MasterSession.
      
      int32 timeline_step = 8;
      Parameters:
      value - The timelineStep to set.
      Returns:
      This builder for chaining.
    • clearTimelineStep

      public GraphOptions.Builder clearTimelineStep()
      If > 0, record a timeline every this many steps.
      EXPERIMENTAL: This currently has no effect in MasterSession.
      
      int32 timeline_step = 8;
      Returns:
      This builder for chaining.
    • hasRewriteOptions

      public boolean hasRewriteOptions()
      Options that control the type and amount of graph rewriting.
      Not currently configurable via the public Python API (i.e. there is no API
      stability guarantee if you import RewriterConfig explicitly).
      
      .tensorflow.RewriterConfig rewrite_options = 10;
      Specified by:
      hasRewriteOptions in interface GraphOptionsOrBuilder
      Returns:
      Whether the rewriteOptions field is set.
    • getRewriteOptions

      public RewriterConfig getRewriteOptions()
      Options that control the type and amount of graph rewriting.
      Not currently configurable via the public Python API (i.e. there is no API
      stability guarantee if you import RewriterConfig explicitly).
      
      .tensorflow.RewriterConfig rewrite_options = 10;
      Specified by:
      getRewriteOptions in interface GraphOptionsOrBuilder
      Returns:
      The rewriteOptions.
    • setRewriteOptions

      public GraphOptions.Builder setRewriteOptions(RewriterConfig value)
      Options that control the type and amount of graph rewriting.
      Not currently configurable via the public Python API (i.e. there is no API
      stability guarantee if you import RewriterConfig explicitly).
      
      .tensorflow.RewriterConfig rewrite_options = 10;
    • setRewriteOptions

      public GraphOptions.Builder setRewriteOptions(RewriterConfig.Builder builderForValue)
      Options that control the type and amount of graph rewriting.
      Not currently configurable via the public Python API (i.e. there is no API
      stability guarantee if you import RewriterConfig explicitly).
      
      .tensorflow.RewriterConfig rewrite_options = 10;
    • mergeRewriteOptions

      public GraphOptions.Builder mergeRewriteOptions(RewriterConfig value)
      Options that control the type and amount of graph rewriting.
      Not currently configurable via the public Python API (i.e. there is no API
      stability guarantee if you import RewriterConfig explicitly).
      
      .tensorflow.RewriterConfig rewrite_options = 10;
    • clearRewriteOptions

      public GraphOptions.Builder clearRewriteOptions()
      Options that control the type and amount of graph rewriting.
      Not currently configurable via the public Python API (i.e. there is no API
      stability guarantee if you import RewriterConfig explicitly).
      
      .tensorflow.RewriterConfig rewrite_options = 10;
    • getRewriteOptionsBuilder

      public RewriterConfig.Builder getRewriteOptionsBuilder()
      Options that control the type and amount of graph rewriting.
      Not currently configurable via the public Python API (i.e. there is no API
      stability guarantee if you import RewriterConfig explicitly).
      
      .tensorflow.RewriterConfig rewrite_options = 10;
    • getRewriteOptionsOrBuilder

      public RewriterConfigOrBuilder getRewriteOptionsOrBuilder()
      Options that control the type and amount of graph rewriting.
      Not currently configurable via the public Python API (i.e. there is no API
      stability guarantee if you import RewriterConfig explicitly).
      
      .tensorflow.RewriterConfig rewrite_options = 10;
      Specified by:
      getRewriteOptionsOrBuilder in interface GraphOptionsOrBuilder