pub struct ThresholdedReluConfig {
pub alpha: f64,
}Expand description
Configuration to create a ThresholdedRelu layer using the init function.
Fields§
§alpha: f64The alpha threshold. Default is 1.0
Implementations§
Source§impl ThresholdedReluConfig
impl ThresholdedReluConfig
Sourcepub fn with_alpha(self, alpha: f64) -> Self
pub fn with_alpha(self, alpha: f64) -> Self
Source§impl ThresholdedReluConfig
impl ThresholdedReluConfig
Sourcepub fn init(&self) -> ThresholdedRelu
pub fn init(&self) -> ThresholdedRelu
Initialize a new ThresholdedRelu layer.
Trait Implementations§
Source§impl Clone for ThresholdedReluConfig
impl Clone for ThresholdedReluConfig
Source§impl Config for ThresholdedReluConfig
impl Config for ThresholdedReluConfig
Source§fn save<P>(&self, file: P) -> Result<(), Error>
fn save<P>(&self, file: P) -> Result<(), Error>
Available on crate feature
std only.Saves the configuration to a file. Read more
Source§fn load<P>(file: P) -> Result<Self, ConfigError>
fn load<P>(file: P) -> Result<Self, ConfigError>
Available on crate feature
std only.Loads the configuration from a file. Read more
Source§fn load_binary(data: &[u8]) -> Result<Self, ConfigError>
fn load_binary(data: &[u8]) -> Result<Self, ConfigError>
Loads the configuration from a binary buffer. Read more
Source§impl Debug for ThresholdedReluConfig
impl Debug for ThresholdedReluConfig
Source§impl<'de> Deserialize<'de> for ThresholdedReluConfig
impl<'de> Deserialize<'de> for ThresholdedReluConfig
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 Display for ThresholdedReluConfig
impl Display for ThresholdedReluConfig
Source§impl From<ThresholdedReluConfig> for ActivationConfig
impl From<ThresholdedReluConfig> for ActivationConfig
Source§fn from(config: ThresholdedReluConfig) -> Self
fn from(config: ThresholdedReluConfig) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ThresholdedReluConfig
impl RefUnwindSafe for ThresholdedReluConfig
impl Send for ThresholdedReluConfig
impl Sync for ThresholdedReluConfig
impl Unpin for ThresholdedReluConfig
impl UnsafeUnpin for ThresholdedReluConfig
impl UnwindSafe for ThresholdedReluConfig
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