pub struct ConfigProto {Show 19 fields
pub device_count: HashMap<String, i32>,
pub intra_op_parallelism_threads: i32,
pub inter_op_parallelism_threads: i32,
pub use_per_session_threads: bool,
pub session_inter_op_thread_pool: RepeatedField<ThreadPoolOptionProto>,
pub placement_period: i32,
pub device_filters: RepeatedField<String>,
pub gpu_options: SingularPtrField<GPUOptions>,
pub allow_soft_placement: bool,
pub log_device_placement: bool,
pub graph_options: SingularPtrField<GraphOptions>,
pub operation_timeout_in_ms: i64,
pub rpc_options: SingularPtrField<RPCOptions>,
pub cluster_def: SingularPtrField<ClusterDef>,
pub isolate_session_state: bool,
pub share_cluster_devices_in_session: bool,
pub experimental: SingularPtrField<ConfigProto_Experimental>,
pub unknown_fields: UnknownFields,
pub cached_size: CachedSize,
}
Fields§
§device_count: HashMap<String, i32>
§intra_op_parallelism_threads: i32
§inter_op_parallelism_threads: i32
§use_per_session_threads: bool
§session_inter_op_thread_pool: RepeatedField<ThreadPoolOptionProto>
§placement_period: i32
§device_filters: RepeatedField<String>
§gpu_options: SingularPtrField<GPUOptions>
§allow_soft_placement: bool
§log_device_placement: bool
§graph_options: SingularPtrField<GraphOptions>
§operation_timeout_in_ms: i64
§rpc_options: SingularPtrField<RPCOptions>
§cluster_def: SingularPtrField<ClusterDef>
§isolate_session_state: bool
§experimental: SingularPtrField<ConfigProto_Experimental>
§unknown_fields: UnknownFields
§cached_size: CachedSize
Implementations§
Source§impl ConfigProto
impl ConfigProto
pub fn new() -> ConfigProto
pub fn get_device_count(&self) -> &HashMap<String, i32>
pub fn clear_device_count(&mut self)
pub fn set_device_count(&mut self, v: HashMap<String, i32>)
pub fn mut_device_count(&mut self) -> &mut HashMap<String, i32>
pub fn take_device_count(&mut self) -> HashMap<String, i32>
pub fn get_intra_op_parallelism_threads(&self) -> i32
pub fn clear_intra_op_parallelism_threads(&mut self)
pub fn set_intra_op_parallelism_threads(&mut self, v: i32)
pub fn get_inter_op_parallelism_threads(&self) -> i32
pub fn clear_inter_op_parallelism_threads(&mut self)
pub fn set_inter_op_parallelism_threads(&mut self, v: i32)
pub fn get_use_per_session_threads(&self) -> bool
pub fn clear_use_per_session_threads(&mut self)
pub fn set_use_per_session_threads(&mut self, v: bool)
pub fn get_session_inter_op_thread_pool(&self) -> &[ThreadPoolOptionProto]
pub fn clear_session_inter_op_thread_pool(&mut self)
pub fn set_session_inter_op_thread_pool( &mut self, v: RepeatedField<ThreadPoolOptionProto>, )
pub fn mut_session_inter_op_thread_pool( &mut self, ) -> &mut RepeatedField<ThreadPoolOptionProto>
pub fn take_session_inter_op_thread_pool( &mut self, ) -> RepeatedField<ThreadPoolOptionProto>
pub fn get_placement_period(&self) -> i32
pub fn clear_placement_period(&mut self)
pub fn set_placement_period(&mut self, v: i32)
pub fn get_device_filters(&self) -> &[String]
pub fn clear_device_filters(&mut self)
pub fn set_device_filters(&mut self, v: RepeatedField<String>)
pub fn mut_device_filters(&mut self) -> &mut RepeatedField<String>
pub fn take_device_filters(&mut self) -> RepeatedField<String>
pub fn get_gpu_options(&self) -> &GPUOptions
pub fn clear_gpu_options(&mut self)
pub fn has_gpu_options(&self) -> bool
pub fn set_gpu_options(&mut self, v: GPUOptions)
pub fn mut_gpu_options(&mut self) -> &mut GPUOptions
pub fn take_gpu_options(&mut self) -> GPUOptions
pub fn get_allow_soft_placement(&self) -> bool
pub fn clear_allow_soft_placement(&mut self)
pub fn set_allow_soft_placement(&mut self, v: bool)
pub fn get_log_device_placement(&self) -> bool
pub fn clear_log_device_placement(&mut self)
pub fn set_log_device_placement(&mut self, v: bool)
pub fn get_graph_options(&self) -> &GraphOptions
pub fn clear_graph_options(&mut self)
pub fn has_graph_options(&self) -> bool
pub fn set_graph_options(&mut self, v: GraphOptions)
pub fn mut_graph_options(&mut self) -> &mut GraphOptions
pub fn take_graph_options(&mut self) -> GraphOptions
pub fn get_operation_timeout_in_ms(&self) -> i64
pub fn clear_operation_timeout_in_ms(&mut self)
pub fn set_operation_timeout_in_ms(&mut self, v: i64)
pub fn get_rpc_options(&self) -> &RPCOptions
pub fn clear_rpc_options(&mut self)
pub fn has_rpc_options(&self) -> bool
pub fn set_rpc_options(&mut self, v: RPCOptions)
pub fn mut_rpc_options(&mut self) -> &mut RPCOptions
pub fn take_rpc_options(&mut self) -> RPCOptions
pub fn get_cluster_def(&self) -> &ClusterDef
pub fn clear_cluster_def(&mut self)
pub fn has_cluster_def(&self) -> bool
pub fn set_cluster_def(&mut self, v: ClusterDef)
pub fn mut_cluster_def(&mut self) -> &mut ClusterDef
pub fn take_cluster_def(&mut self) -> ClusterDef
pub fn get_isolate_session_state(&self) -> bool
pub fn clear_isolate_session_state(&mut self)
pub fn set_isolate_session_state(&mut self, v: bool)
pub fn get_experimental(&self) -> &ConfigProto_Experimental
pub fn clear_experimental(&mut self)
pub fn has_experimental(&self) -> bool
pub fn set_experimental(&mut self, v: ConfigProto_Experimental)
pub fn mut_experimental(&mut self) -> &mut ConfigProto_Experimental
pub fn take_experimental(&mut self) -> ConfigProto_Experimental
Trait Implementations§
Source§impl Clear for ConfigProto
impl Clear for ConfigProto
Source§impl Clone for ConfigProto
impl Clone for ConfigProto
Source§fn clone(&self) -> ConfigProto
fn clone(&self) -> ConfigProto
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ConfigProto
impl Debug for ConfigProto
Source§impl<'a> Default for &'a ConfigProto
impl<'a> Default for &'a ConfigProto
Source§fn default() -> &'a ConfigProto
fn default() -> &'a ConfigProto
Returns the “default value” for a type. Read more
Source§impl Default for ConfigProto
impl Default for ConfigProto
Source§fn default() -> ConfigProto
fn default() -> ConfigProto
Returns the “default value” for a type. Read more
Source§impl Message for ConfigProto
impl Message for ConfigProto
Source§fn is_initialized(&self) -> bool
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<()>
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
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<()>
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
fn get_cached_size(&self) -> u32
Get size previously computed by
compute_size
.Source§fn get_unknown_fields(&self) -> &UnknownFields
fn get_unknown_fields(&self) -> &UnknownFields
Get a reference to unknown fields.
Source§fn mut_unknown_fields(&mut self) -> &mut UnknownFields
fn mut_unknown_fields(&mut self) -> &mut UnknownFields
Get a mutable reference to unknown fields.
Source§fn as_any_mut(&mut self) -> &mut dyn Any
fn as_any_mut(&mut self) -> &mut dyn Any
View self as mutable
Any
.Source§fn descriptor(&self) -> &'static MessageDescriptor
fn descriptor(&self) -> &'static MessageDescriptor
Message descriptor for this message, used for reflection.
Source§fn new() -> ConfigProto
fn new() -> ConfigProto
Create an empty message object. Read more
Source§fn descriptor_static() -> &'static MessageDescriptor
fn descriptor_static() -> &'static MessageDescriptor
Get message descriptor for message type. Read more
Source§fn default_instance() -> &'static ConfigProto
fn default_instance() -> &'static ConfigProto
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,
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>
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>
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>
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>
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,
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,
fn parse_from_bytes(bytes: &[u8]) -> Result<Self, ProtobufError>where
Self: Sized,
Parse message from byte array.
Source§fn check_initialized(&self) -> Result<(), ProtobufError>
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>
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>
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>
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>
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>
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§impl PartialEq for ConfigProto
impl PartialEq for ConfigProto
Source§impl ProtobufValue for ConfigProto
impl ProtobufValue for ConfigProto
Source§fn as_ref(&self) -> ReflectValueRef<'_>
fn as_ref(&self) -> ReflectValueRef<'_>
As ref
Source§fn is_non_zero(&self) -> bool
fn is_non_zero(&self) -> bool
Is value non-zero?
Source§fn as_ref_copy(&self) -> ReflectValueRef<'static>
fn as_ref_copy(&self) -> ReflectValueRef<'static>
impl StructuralPartialEq for ConfigProto
Auto Trait Implementations§
impl !Freeze for ConfigProto
impl RefUnwindSafe for ConfigProto
impl Send for ConfigProto
impl Sync for ConfigProto
impl Unpin for ConfigProto
impl UnwindSafe for ConfigProto
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more