[−][src]Struct onnxruntime::environment::EnvBuilder
Struct used to build an environment Environment
This is the crate's main entry point. An environment must be created
as the first step. An Environment
can only be built
using EnvBuilder
to configure it.
NOTE: If the same configuration method (for example with_name()
)
is called multiple times, the last value will have precedence.
Implementations
impl EnvBuilder
[src]
pub fn with_name<S>(self, name: S) -> EnvBuilder where
S: Into<String>,
[src]
S: Into<String>,
Configure the environment with a given name
NOTE: Since ONNX can only define one environment per process,
creating multiple environments using multiple EnvBuilder
will
end up re-using the same environment internally; a new one will not
be created. New parameters will be ignored.
pub fn with_log_level(self, log_level: LoggingLevel) -> EnvBuilder
[src]
Configure the environment with a given log level
NOTE: Since ONNX can only define one environment per process,
creating multiple environments using multiple EnvBuilder
will
end up re-using the same environment internally; a new one will not
be created. New parameters will be ignored.
pub fn build(self) -> Result<Environment>
[src]
Commit the configuration to a new Environment
Auto Trait Implementations
impl RefUnwindSafe for EnvBuilder
impl Send for EnvBuilder
impl Sync for EnvBuilder
impl Unpin for EnvBuilder
impl UnwindSafe for EnvBuilder
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,