Struct RewriterConfig

Source
pub struct RewriterConfig {
Show 31 fields pub layout_optimizer: RewriterConfig_Toggle, pub constant_folding: RewriterConfig_Toggle, pub shape_optimization: RewriterConfig_Toggle, pub remapping: RewriterConfig_Toggle, pub common_subgraph_elimination: RewriterConfig_Toggle, pub arithmetic_optimization: RewriterConfig_Toggle, pub dependency_optimization: RewriterConfig_Toggle, pub loop_optimization: RewriterConfig_Toggle, pub function_optimization: RewriterConfig_Toggle, pub debug_stripper: RewriterConfig_Toggle, pub disable_model_pruning: bool, pub scoped_allocator_optimization: RewriterConfig_Toggle, pub pin_to_host_optimization: RewriterConfig_Toggle, pub implementation_selector: RewriterConfig_Toggle, pub auto_mixed_precision: RewriterConfig_Toggle, pub auto_mixed_precision_mkl: RewriterConfig_Toggle, pub disable_meta_optimizer: bool, pub meta_optimizer_iterations: RewriterConfig_NumIterationsType, pub min_graph_nodes: i32, pub memory_optimization: RewriterConfig_MemOptType, pub memory_optimizer_target_node_name_scope: String, pub meta_optimizer_timeout_ms: i64, pub auto_parallel: SingularPtrField<AutoParallelOptions>, pub fail_on_optimizer_errors: bool, pub scoped_allocator_opts: SingularPtrField<ScopedAllocatorOptions>, pub optimizers: RepeatedField<String>, pub custom_optimizers: RepeatedField<RewriterConfig_CustomGraphOptimizer>, pub inter_optimizer_verifier_config: SingularPtrField<VerifierConfig>, pub post_optimization_verifier_config: SingularPtrField<VerifierConfig>, pub unknown_fields: UnknownFields, pub cached_size: CachedSize,
}

Fields§

§layout_optimizer: RewriterConfig_Toggle§constant_folding: RewriterConfig_Toggle§shape_optimization: RewriterConfig_Toggle§remapping: RewriterConfig_Toggle§common_subgraph_elimination: RewriterConfig_Toggle§arithmetic_optimization: RewriterConfig_Toggle§dependency_optimization: RewriterConfig_Toggle§loop_optimization: RewriterConfig_Toggle§function_optimization: RewriterConfig_Toggle§debug_stripper: RewriterConfig_Toggle§disable_model_pruning: bool§scoped_allocator_optimization: RewriterConfig_Toggle§pin_to_host_optimization: RewriterConfig_Toggle§implementation_selector: RewriterConfig_Toggle§auto_mixed_precision: RewriterConfig_Toggle§auto_mixed_precision_mkl: RewriterConfig_Toggle§disable_meta_optimizer: bool§meta_optimizer_iterations: RewriterConfig_NumIterationsType§min_graph_nodes: i32§memory_optimization: RewriterConfig_MemOptType§memory_optimizer_target_node_name_scope: String§meta_optimizer_timeout_ms: i64§auto_parallel: SingularPtrField<AutoParallelOptions>§fail_on_optimizer_errors: bool§scoped_allocator_opts: SingularPtrField<ScopedAllocatorOptions>§optimizers: RepeatedField<String>§custom_optimizers: RepeatedField<RewriterConfig_CustomGraphOptimizer>§inter_optimizer_verifier_config: SingularPtrField<VerifierConfig>§post_optimization_verifier_config: SingularPtrField<VerifierConfig>§unknown_fields: UnknownFields§cached_size: CachedSize

Implementations§

Source§

impl RewriterConfig

Source

pub fn new() -> RewriterConfig

Source

pub fn get_layout_optimizer(&self) -> RewriterConfig_Toggle

Source

pub fn clear_layout_optimizer(&mut self)

Source

pub fn set_layout_optimizer(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_constant_folding(&self) -> RewriterConfig_Toggle

Source

pub fn clear_constant_folding(&mut self)

Source

pub fn set_constant_folding(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_shape_optimization(&self) -> RewriterConfig_Toggle

Source

pub fn clear_shape_optimization(&mut self)

Source

pub fn set_shape_optimization(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_remapping(&self) -> RewriterConfig_Toggle

Source

pub fn clear_remapping(&mut self)

Source

pub fn set_remapping(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_common_subgraph_elimination(&self) -> RewriterConfig_Toggle

Source

pub fn clear_common_subgraph_elimination(&mut self)

Source

pub fn set_common_subgraph_elimination(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_arithmetic_optimization(&self) -> RewriterConfig_Toggle

Source

pub fn clear_arithmetic_optimization(&mut self)

Source

pub fn set_arithmetic_optimization(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_dependency_optimization(&self) -> RewriterConfig_Toggle

Source

pub fn clear_dependency_optimization(&mut self)

Source

pub fn set_dependency_optimization(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_loop_optimization(&self) -> RewriterConfig_Toggle

Source

pub fn clear_loop_optimization(&mut self)

Source

pub fn set_loop_optimization(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_function_optimization(&self) -> RewriterConfig_Toggle

Source

pub fn clear_function_optimization(&mut self)

Source

pub fn set_function_optimization(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_debug_stripper(&self) -> RewriterConfig_Toggle

Source

pub fn clear_debug_stripper(&mut self)

Source

pub fn set_debug_stripper(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_disable_model_pruning(&self) -> bool

Source

pub fn clear_disable_model_pruning(&mut self)

Source

pub fn set_disable_model_pruning(&mut self, v: bool)

Source

pub fn get_scoped_allocator_optimization(&self) -> RewriterConfig_Toggle

Source

pub fn clear_scoped_allocator_optimization(&mut self)

Source

pub fn set_scoped_allocator_optimization(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_pin_to_host_optimization(&self) -> RewriterConfig_Toggle

Source

pub fn clear_pin_to_host_optimization(&mut self)

Source

pub fn set_pin_to_host_optimization(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_implementation_selector(&self) -> RewriterConfig_Toggle

Source

pub fn clear_implementation_selector(&mut self)

Source

pub fn set_implementation_selector(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_auto_mixed_precision(&self) -> RewriterConfig_Toggle

Source

pub fn clear_auto_mixed_precision(&mut self)

Source

pub fn set_auto_mixed_precision(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_auto_mixed_precision_mkl(&self) -> RewriterConfig_Toggle

Source

pub fn clear_auto_mixed_precision_mkl(&mut self)

Source

pub fn set_auto_mixed_precision_mkl(&mut self, v: RewriterConfig_Toggle)

Source

pub fn get_disable_meta_optimizer(&self) -> bool

Source

pub fn clear_disable_meta_optimizer(&mut self)

Source

pub fn set_disable_meta_optimizer(&mut self, v: bool)

Source

pub fn get_meta_optimizer_iterations(&self) -> RewriterConfig_NumIterationsType

Source

pub fn clear_meta_optimizer_iterations(&mut self)

Source

pub fn set_meta_optimizer_iterations( &mut self, v: RewriterConfig_NumIterationsType, )

Source

pub fn get_min_graph_nodes(&self) -> i32

Source

pub fn clear_min_graph_nodes(&mut self)

Source

pub fn set_min_graph_nodes(&mut self, v: i32)

Source

pub fn get_memory_optimization(&self) -> RewriterConfig_MemOptType

Source

pub fn clear_memory_optimization(&mut self)

Source

pub fn set_memory_optimization(&mut self, v: RewriterConfig_MemOptType)

Source

pub fn get_memory_optimizer_target_node_name_scope(&self) -> &str

Source

pub fn clear_memory_optimizer_target_node_name_scope(&mut self)

Source

pub fn set_memory_optimizer_target_node_name_scope(&mut self, v: String)

Source

pub fn mut_memory_optimizer_target_node_name_scope(&mut self) -> &mut String

Source

pub fn take_memory_optimizer_target_node_name_scope(&mut self) -> String

Source

pub fn get_meta_optimizer_timeout_ms(&self) -> i64

Source

pub fn clear_meta_optimizer_timeout_ms(&mut self)

Source

pub fn set_meta_optimizer_timeout_ms(&mut self, v: i64)

Source

pub fn get_auto_parallel(&self) -> &AutoParallelOptions

Source

pub fn clear_auto_parallel(&mut self)

Source

pub fn has_auto_parallel(&self) -> bool

Source

pub fn set_auto_parallel(&mut self, v: AutoParallelOptions)

Source

pub fn mut_auto_parallel(&mut self) -> &mut AutoParallelOptions

Source

pub fn take_auto_parallel(&mut self) -> AutoParallelOptions

Source

pub fn get_fail_on_optimizer_errors(&self) -> bool

Source

pub fn clear_fail_on_optimizer_errors(&mut self)

Source

pub fn set_fail_on_optimizer_errors(&mut self, v: bool)

Source

pub fn get_scoped_allocator_opts(&self) -> &ScopedAllocatorOptions

Source

pub fn clear_scoped_allocator_opts(&mut self)

Source

pub fn has_scoped_allocator_opts(&self) -> bool

Source

pub fn set_scoped_allocator_opts(&mut self, v: ScopedAllocatorOptions)

Source

pub fn mut_scoped_allocator_opts(&mut self) -> &mut ScopedAllocatorOptions

Source

pub fn take_scoped_allocator_opts(&mut self) -> ScopedAllocatorOptions

Source

pub fn get_optimizers(&self) -> &[String]

Source

pub fn clear_optimizers(&mut self)

Source

pub fn set_optimizers(&mut self, v: RepeatedField<String>)

Source

pub fn mut_optimizers(&mut self) -> &mut RepeatedField<String>

Source

pub fn take_optimizers(&mut self) -> RepeatedField<String>

Source

pub fn get_custom_optimizers(&self) -> &[RewriterConfig_CustomGraphOptimizer]

Source

pub fn clear_custom_optimizers(&mut self)

Source

pub fn set_custom_optimizers( &mut self, v: RepeatedField<RewriterConfig_CustomGraphOptimizer>, )

Source

pub fn mut_custom_optimizers( &mut self, ) -> &mut RepeatedField<RewriterConfig_CustomGraphOptimizer>

Source

pub fn take_custom_optimizers( &mut self, ) -> RepeatedField<RewriterConfig_CustomGraphOptimizer>

Source

pub fn get_inter_optimizer_verifier_config(&self) -> &VerifierConfig

Source

pub fn clear_inter_optimizer_verifier_config(&mut self)

Source

pub fn has_inter_optimizer_verifier_config(&self) -> bool

Source

pub fn set_inter_optimizer_verifier_config(&mut self, v: VerifierConfig)

Source

pub fn mut_inter_optimizer_verifier_config(&mut self) -> &mut VerifierConfig

Source

pub fn take_inter_optimizer_verifier_config(&mut self) -> VerifierConfig

Source

pub fn get_post_optimization_verifier_config(&self) -> &VerifierConfig

Source

pub fn clear_post_optimization_verifier_config(&mut self)

Source

pub fn has_post_optimization_verifier_config(&self) -> bool

Source

pub fn set_post_optimization_verifier_config(&mut self, v: VerifierConfig)

Source

pub fn mut_post_optimization_verifier_config(&mut self) -> &mut VerifierConfig

Source

pub fn take_post_optimization_verifier_config(&mut self) -> VerifierConfig

Trait Implementations§

Source§

impl Clear for RewriterConfig

Source§

fn clear(&mut self)

Clear this make, make it equivalent to newly created object.
Source§

impl Clone for RewriterConfig

Source§

fn clone(&self) -> RewriterConfig

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for RewriterConfig

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a> Default for &'a RewriterConfig

Source§

fn default() -> &'a RewriterConfig

Returns the “default value” for a type. Read more
Source§

impl Default for RewriterConfig

Source§

fn default() -> RewriterConfig

Returns the “default value” for a type. Read more
Source§

impl Message for RewriterConfig

Source§

fn is_initialized(&self) -> bool

True iff all required fields are initialized. Always returns true for protobuf 3.
Source§

fn merge_from(&mut self, is: &mut CodedInputStream<'_>) -> ProtobufResult<()>

Update this message object with fields read from given stream.
Source§

fn compute_size(&self) -> u32

Compute and cache size of this message and all nested messages
Source§

fn write_to_with_cached_sizes( &self, os: &mut CodedOutputStream<'_>, ) -> ProtobufResult<()>

Write message to the stream. Read more
Source§

fn get_cached_size(&self) -> u32

Get size previously computed by compute_size.
Source§

fn get_unknown_fields(&self) -> &UnknownFields

Get a reference to unknown fields.
Source§

fn mut_unknown_fields(&mut self) -> &mut UnknownFields

Get a mutable reference to unknown fields.
Source§

fn as_any(&self) -> &dyn Any

View self as Any.
Source§

fn as_any_mut(&mut self) -> &mut dyn Any

View self as mutable Any.
Source§

fn into_any(self: Box<Self>) -> Box<dyn Any>

Convert boxed self to boxed Any.
Source§

fn descriptor(&self) -> &'static MessageDescriptor

Message descriptor for this message, used for reflection.
Source§

fn new() -> RewriterConfig

Create an empty message object. Read more
Source§

fn descriptor_static() -> &'static MessageDescriptor

Get message descriptor for message type. Read more
Source§

fn default_instance() -> &'static RewriterConfig

Return a pointer to default immutable message with static lifetime. Read more
Source§

fn parse_from(is: &mut CodedInputStream<'_>) -> Result<Self, ProtobufError>
where Self: Sized,

Parse message from stream.
Source§

fn write_to(&self, os: &mut CodedOutputStream<'_>) -> Result<(), ProtobufError>

Write the message to the stream. Read more
Source§

fn write_length_delimited_to( &self, os: &mut CodedOutputStream<'_>, ) -> Result<(), ProtobufError>

Write the message to the stream prepending the message with message length encoded as varint.
Source§

fn write_length_delimited_to_vec( &self, vec: &mut Vec<u8>, ) -> Result<(), ProtobufError>

Write the message to the vec, prepend the message with message length encoded as varint.
Source§

fn merge_from_bytes(&mut self, bytes: &[u8]) -> Result<(), ProtobufError>

Update this message object with fields read from given stream.
Source§

fn parse_from_reader(reader: &mut dyn Read) -> Result<Self, ProtobufError>
where Self: Sized,

Parse message from reader. Parse stops on EOF or when error encountered.
Source§

fn parse_from_bytes(bytes: &[u8]) -> Result<Self, ProtobufError>
where Self: Sized,

Parse message from byte array.
Source§

fn check_initialized(&self) -> Result<(), ProtobufError>

Check if all required fields of this object are initialized.
Source§

fn write_to_writer(&self, w: &mut dyn Write) -> Result<(), ProtobufError>

Write the message to the writer.
Source§

fn write_to_vec(&self, v: &mut Vec<u8>) -> Result<(), ProtobufError>

Write the message to bytes vec.
Source§

fn write_to_bytes(&self) -> Result<Vec<u8>, ProtobufError>

Write the message to bytes vec.
Source§

fn write_length_delimited_to_writer( &self, w: &mut dyn Write, ) -> Result<(), ProtobufError>

Write the message to the writer, prepend the message with message length encoded as varint.
Source§

fn write_length_delimited_to_bytes(&self) -> Result<Vec<u8>, ProtobufError>

Write the message to the bytes vec, prepend the message with message length encoded as varint.
Source§

fn type_id(&self) -> TypeId

Get type id for downcasting.
Source§

impl PartialEq for RewriterConfig

Source§

fn eq(&self, other: &RewriterConfig) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl ProtobufValue for RewriterConfig

Source§

fn as_ref(&self) -> ReflectValueRef<'_>

As ref
Source§

fn as_any(&self) -> &(dyn Any + 'static)

Convert to Any
Source§

fn is_non_zero(&self) -> bool

Is value non-zero?
Source§

fn as_ref_copy(&self) -> ReflectValueRef<'static>

Return ProtobufValueRef if self is Copy. Read more
Source§

impl StructuralPartialEq for RewriterConfig

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dst: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.