Struct border_tch_agent::iqn::IqnModelConfig
source · pub struct IqnModelConfig<F, M>where
M: OutDim,{
pub feature_dim: i64,
pub embed_dim: i64,
pub f_config: Option<F>,
pub m_config: Option<M>,
pub opt_config: OptimizerConfig,
}Expand description
Configuration of IqnModel.
The type parameter F represents a configuration struct of a feature extractor.
The type parameter M represents a configuration struct of a model for merging
cosine-embedded percent points and feature vectors.
Fields§
§feature_dim: i64Dimension of feature vector.
embed_dim: i64Embedding dimension.
f_config: Option<F>Configuration of feature extractor.
m_config: Option<M>Configuration of a model for merging percentils and feature vectors.
opt_config: OptimizerConfigConfiguration of optimizer.
Implementations§
source§impl<F, M> IqnModelConfig<F, M>where
F: DeserializeOwned + Serialize,
M: DeserializeOwned + Serialize + OutDim,
impl<F, M> IqnModelConfig<F, M>where F: DeserializeOwned + Serialize, M: DeserializeOwned + Serialize + OutDim,
sourcepub fn learning_rate(self, v: f64) -> Self
pub fn learning_rate(self, v: f64) -> Self
Sets the learning rate.
source§impl<F, M> IqnModelConfig<F, M>where
F: DeserializeOwned + Serialize,
M: DeserializeOwned + Serialize + OutDim,
impl<F, M> IqnModelConfig<F, M>where F: DeserializeOwned + Serialize, M: DeserializeOwned + Serialize + OutDim,
sourcepub fn feature_dim(self, v: i64) -> Self
pub fn feature_dim(self, v: i64) -> Self
Sets the dimension of feature vectors.
sourcepub fn opt_config(self, v: OptimizerConfig) -> Self
pub fn opt_config(self, v: OptimizerConfig) -> Self
Sets optimizer configuration.
Trait Implementations§
source§impl<F: Clone, M> Clone for IqnModelConfig<F, M>where
M: OutDim + Clone,
impl<F: Clone, M> Clone for IqnModelConfig<F, M>where M: OutDim + Clone,
source§fn clone(&self) -> IqnModelConfig<F, M>
fn clone(&self) -> IqnModelConfig<F, M>
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<F, M> Default for IqnModelConfig<F, M>where
M: OutDim,
impl<F, M> Default for IqnModelConfig<F, M>where M: OutDim,
source§impl<'de, F, M> Deserialize<'de> for IqnModelConfig<F, M>where
M: OutDim + Deserialize<'de>,
F: Deserialize<'de>,
impl<'de, F, M> Deserialize<'de> for IqnModelConfig<F, M>where M: OutDim + Deserialize<'de>, F: Deserialize<'de>,
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<F: PartialEq, M> PartialEq<IqnModelConfig<F, M>> for IqnModelConfig<F, M>where
M: OutDim + PartialEq,
impl<F: PartialEq, M> PartialEq<IqnModelConfig<F, M>> for IqnModelConfig<F, M>where M: OutDim + PartialEq,
source§fn eq(&self, other: &IqnModelConfig<F, M>) -> bool
fn eq(&self, other: &IqnModelConfig<F, M>) -> bool
This method tests for
self and other values to be equal, and is used
by ==.impl<F, M> StructuralPartialEq for IqnModelConfig<F, M>where M: OutDim,
Auto Trait Implementations§
impl<F, M> RefUnwindSafe for IqnModelConfig<F, M>where F: RefUnwindSafe, M: RefUnwindSafe,
impl<F, M> Send for IqnModelConfig<F, M>where F: Send, M: Send,
impl<F, M> Sync for IqnModelConfig<F, M>where F: Sync, M: Sync,
impl<F, M> Unpin for IqnModelConfig<F, M>where F: Unpin, M: Unpin,
impl<F, M> UnwindSafe for IqnModelConfig<F, M>where F: UnwindSafe, M: UnwindSafe,
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