Struct rust_bert::reformer::ReformerConfig[][src]

pub struct ReformerConfig {
    pub attention_head_size: i64,
    pub attention_probs_dropout_prob: f64,
    pub attn_layers: Vec<AttentionType>,
    pub axial_norm_std: f64,
    pub axial_pos_embds: bool,
    pub axial_pos_embds_dim: Vec<i64>,
    pub axial_pos_shape: Vec<i64>,
    pub chunk_size_lm_head: i64,
    pub chunk_size_feed_forward: Option<i64>,
    pub eos_token_id: i64,
    pub pad_token_id: i64,
    pub feed_forward_size: i64,
    pub hash_seed: Option<i64>,
    pub hidden_act: Activation,
    pub hidden_dropout_prob: f64,
    pub hidden_size: i64,
    pub initializer_range: Option<f64>,
    pub intermediate_size: i64,
    pub is_decoder: bool,
    pub layer_norm_eps: Option<f64>,
    pub max_position_embeddings: i64,
    pub vocab_size: i64,
    pub num_attention_heads: i64,
    pub num_buckets: Value,
    pub local_attn_chunk_length: Option<i64>,
    pub local_num_chunks_after: Option<i64>,
    pub local_num_chunks_before: Option<i64>,
    pub local_attention_probs_dropout_prob: Option<f64>,
    pub lsh_attn_chunk_length: Option<i64>,
    pub lsh_num_chunks_after: Option<i64>,
    pub lsh_num_chunks_before: Option<i64>,
    pub lsh_attention_probs_dropout_prob: Option<f64>,
    pub num_hashes: i64,
    pub num_hidden_layers: i64,
    pub use_cache: Option<bool>,
    pub id2label: Option<HashMap<i64, String>>,
    pub label2id: Option<HashMap<String, i64>>,
    pub output_attentions: Option<bool>,
    pub output_hidden_states: Option<bool>,
}

Reformer model configuration

Defines the Reformer model architecture (e.g. number of layers, hidden layer size, label mapping...)

Fields

attention_head_size: i64attention_probs_dropout_prob: f64attn_layers: Vec<AttentionType>axial_norm_std: f64axial_pos_embds: boolaxial_pos_embds_dim: Vec<i64>axial_pos_shape: Vec<i64>chunk_size_lm_head: i64chunk_size_feed_forward: Option<i64>eos_token_id: i64pad_token_id: i64feed_forward_size: i64hash_seed: Option<i64>hidden_act: Activationhidden_dropout_prob: f64hidden_size: i64initializer_range: Option<f64>intermediate_size: i64is_decoder: boollayer_norm_eps: Option<f64>max_position_embeddings: i64vocab_size: i64num_attention_heads: i64num_buckets: Valuelocal_attn_chunk_length: Option<i64>local_num_chunks_after: Option<i64>local_num_chunks_before: Option<i64>local_attention_probs_dropout_prob: Option<f64>lsh_attn_chunk_length: Option<i64>lsh_num_chunks_after: Option<i64>lsh_num_chunks_before: Option<i64>lsh_attention_probs_dropout_prob: Option<f64>num_hashes: i64num_hidden_layers: i64use_cache: Option<bool>id2label: Option<HashMap<i64, String>>label2id: Option<HashMap<String, i64>>output_attentions: Option<bool>output_hidden_states: Option<bool>

Trait Implementations

impl Clone for ReformerConfig[src]

impl Config<ReformerConfig> for ReformerConfig[src]

impl Debug for ReformerConfig[src]

impl<'de> Deserialize<'de> for ReformerConfig[src]

impl Serialize for ReformerConfig[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Pointable for T

type Init = T

The type for initializers.

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,