pub struct BurnConfig {
pub fusion: FusionConfig,
pub autodiff: AutodiffConfig,
}Expand description
Represents the global configuration for Burn.
Fields§
§fusion: FusionConfigConfiguration for operation fusion.
autodiff: AutodiffConfigConfiguration for autodiff.
Trait Implementations§
Source§impl Clone for BurnConfig
impl Clone for BurnConfig
Source§fn clone(&self) -> BurnConfig
fn clone(&self) -> BurnConfig
Returns a duplicate 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 BurnConfig
impl Debug for BurnConfig
Source§impl Default for BurnConfig
impl Default for BurnConfig
Source§fn default() -> BurnConfig
fn default() -> BurnConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for BurnConfig
impl<'de> Deserialize<'de> for BurnConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl RuntimeConfig for BurnConfig
impl RuntimeConfig for BurnConfig
Source§fn storage() -> &'static Mutex<Option<Arc<Self>>>
fn storage() -> &'static Mutex<Option<Arc<Self>>>
Global storage for the configuration singleton. Read more
Source§fn file_names() -> &'static [&'static str]
fn file_names() -> &'static [&'static str]
File names searched in each directory during [
Config::from_current_dir]. Read moreSource§fn section_file_names() -> &'static [(&'static str, &'static str)]
fn section_file_names() -> &'static [(&'static str, &'static str)]
File names searched in each directory, where only a specific TOML section is loaded
instead of the whole file. Read more
Source§fn override_from_env(self) -> Self
fn override_from_env(self) -> Self
Available on
std_io only.Hook to override fields from environment variables after loading from disk. Read more
Source§fn get() -> Arc<Self> ⓘ
fn get() -> Arc<Self> ⓘ
Retrieves the current configuration, loading it from the current directory if not set. Read more
Source§fn save_default<P>(path: P) -> Result<(), Error>
fn save_default<P>(path: P) -> Result<(), Error>
Available on
std_io only.Save the default configuration to the provided file path.
Source§fn from_current_dir() -> Self
fn from_current_dir() -> Self
Available on
std_io only.Loads configuration from any of [
Config::file_names] in the current directory or its
parents. Read moreSource§fn from_file_path<P>(path: P) -> Result<Self, Error>
fn from_file_path<P>(path: P) -> Result<Self, Error>
Available on
std_io only.Loads configuration from a specified file path.
Auto Trait Implementations§
impl Freeze for BurnConfig
impl RefUnwindSafe for BurnConfig
impl Send for BurnConfig
impl Sync for BurnConfig
impl Unpin for BurnConfig
impl UnsafeUnpin for BurnConfig
impl UnwindSafe for BurnConfig
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