Struct rust_bert::t5::T5Config [−][src]
pub struct T5Config {Show 15 fields
pub dropout_rate: f64,
pub d_model: i64,
pub d_ff: i64,
pub d_kv: i64,
pub decoder_start_token_id: Option<i64>,
pub eos_token_id: Option<i64>,
pub initializer_factor: f64,
pub is_encoder_decoder: Option<bool>,
pub layer_norm_epsilon: f64,
pub num_heads: i64,
pub num_layers: i64,
pub output_past: Option<bool>,
pub pad_token_id: Option<i64>,
pub relative_attention_num_buckets: i64,
pub vocab_size: i64,
// some fields omitted
}
Expand description
T5 model configuration
Defines the T5 model architecture (e.g. number of layers, hidden layer size, label mapping…)
Fields
dropout_rate: f64
d_model: i64
d_ff: i64
d_kv: i64
decoder_start_token_id: Option<i64>
eos_token_id: Option<i64>
initializer_factor: f64
is_encoder_decoder: Option<bool>
layer_norm_epsilon: f64
num_heads: i64
num_layers: i64
output_past: Option<bool>
pad_token_id: Option<i64>
relative_attention_num_buckets: i64
vocab_size: i64
Trait Implementations
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
Auto Trait Implementations
impl RefUnwindSafe for T5Config
impl UnwindSafe for T5Config
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
type Output = T
type Output = T
Should always be Self