Struct candle_transformers::models::marian::Config
source · pub struct Config {Show 19 fields
pub vocab_size: usize,
pub decoder_vocab_size: Option<usize>,
pub max_position_embeddings: usize,
pub encoder_layers: usize,
pub encoder_ffn_dim: usize,
pub encoder_attention_heads: usize,
pub decoder_layers: usize,
pub decoder_ffn_dim: usize,
pub decoder_attention_heads: usize,
pub use_cache: bool,
pub is_encoder_decoder: bool,
pub activation_function: Activation,
pub d_model: usize,
pub decoder_start_token_id: u32,
pub scale_embedding: bool,
pub pad_token_id: u32,
pub eos_token_id: u32,
pub forced_eos_token_id: u32,
pub share_encoder_decoder_embeddings: bool,
}
Fields§
§vocab_size: usize
§decoder_vocab_size: Option<usize>
§max_position_embeddings: usize
§encoder_layers: usize
§encoder_ffn_dim: usize
§encoder_attention_heads: usize
§decoder_layers: usize
§decoder_ffn_dim: usize
§decoder_attention_heads: usize
§use_cache: bool
§is_encoder_decoder: bool
§activation_function: Activation
§d_model: usize
§decoder_start_token_id: u32
§scale_embedding: bool
§pad_token_id: u32
§eos_token_id: u32
§forced_eos_token_id: u32
Implementations§
source§impl Config
impl Config
pub fn opus_mt_tc_big_fr_en() -> Self
pub fn opus_mt_fr_en() -> Self
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Config
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnwindSafe for Config
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